forked from BC-SECURITY/Empire
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile
43 lines (30 loc) · 1.07 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
# NOTE: Only use this when you want to build image locally
# else use `docker pull bcsecurity/empire:{VERSION}`
# all image versions can be found at: https://hub.docker.com/r/bcsecurity/empire/
# -----BUILD COMMANDS----
# 1) build command: `docker build -t bcsecurity/empire .`
# 2) create volume storage: `docker create -v /empire --name data bcsecurity/empire`
# 3) run out container: `docker run -ti --volumes-from data bcsecurity/empire /bin/bash`
# -----RELEASE COMMANDS----
# Handled by GitHub Actions
# -----BUILD ENTRY-----
# image base
FROM python:3.7.5-buster
# extra metadata
LABEL maintainer="bc-security"
LABEL description="Dockerfile base for Empire server."
# env setup
ENV STAGING_KEY=RANDOM
ENV DEBIAN_FRONTEND=noninteractive
# set the def shell for ENV
SHELL ["/bin/bash", "-c"]
RUN apt-get update && \
apt-get -y install sudo && \
apt-get -y install lsb-release
COPY . /empire
RUN cd /empire/setup/ && \
./install.sh && \
rm -rf /empire/data/empire*
RUN python /empire/setup/setup_database.py
WORKDIR /empire
CMD ["python", "empire"]