mirror of
https://github.com/telekom-security/tpotce.git
synced 2025-07-02 01:27:27 -04:00
tweak deploy, add autoheal, start update Dockerfiles
- tweak deploy a little further - start with rebuilding Dockerfiles - rework healthcheck for adbhoney CPU issues - bump adbhoney, ciscoasa, citrixhoneypot, conpot, cowriepot, ddospot to alpine 3.19 - fix conpot issue with py 3.11 - bump conpot to latest master - bump cowrie to latest master - add autoheal to tpotinit to restart unhealthy container (if healthcheck enabled)
This commit is contained in:
@ -1,14 +1,15 @@
|
||||
FROM alpine:3.17
|
||||
FROM alpine:3.19
|
||||
#
|
||||
# Include dist
|
||||
COPY dist/ /root/dist/
|
||||
#
|
||||
# Install packages
|
||||
RUN apk --no-cache -U add \
|
||||
git \
|
||||
procps \
|
||||
py3-requests \
|
||||
python3 && \
|
||||
git \
|
||||
procps \
|
||||
py3-psutil \
|
||||
py3-requests \
|
||||
python3 && \
|
||||
#
|
||||
# Install adbhoney from git
|
||||
git clone https://github.com/huuck/ADBHoney /opt/adbhoney && \
|
||||
@ -16,6 +17,7 @@ RUN apk --no-cache -U add \
|
||||
# git checkout 2417a7a982f4fd527b3a048048df9a23178767ad && \
|
||||
git checkout 42afd98611724ca3d694a48b694c957e8d953db4 && \
|
||||
cp /root/dist/adbhoney.cfg /opt/adbhoney && \
|
||||
cp /root/dist/cpu_check.py /opt/adbhoney && \
|
||||
sed -i 's/dst_ip/dest_ip/' /opt/adbhoney/adbhoney/core.py && \
|
||||
sed -i 's/dst_port/dest_port/' /opt/adbhoney/adbhoney/core.py && \
|
||||
#
|
||||
@ -31,7 +33,7 @@ RUN apk --no-cache -U add \
|
||||
# Set workdir and start adbhoney
|
||||
STOPSIGNAL SIGINT
|
||||
# Adbhoney sometimes hangs at 100% CPU usage, if detected process will be killed and container restarts per docker-compose settings
|
||||
HEALTHCHECK CMD if [ $(ps -C mpv -p 1 -o %cpu | tail -n 1 | cut -f 1 -d ".") -gt 75 ]; then kill -2 1; else exit 0; fi
|
||||
HEALTHCHECK --interval=5m --timeout=30s --retries=3 CMD python3 /opt/adbhoney/cpu_check.py
|
||||
USER adbhoney:adbhoney
|
||||
WORKDIR /opt/adbhoney/
|
||||
CMD /usr/bin/python3 run.py
|
||||
|
Reference in New Issue
Block a user