Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docker refactor #1581

Closed
wants to merge 7 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docker/.env
55 changes: 0 additions & 55 deletions docker/Dockerfile

This file was deleted.

1 change: 1 addition & 0 deletions docker/Dockerfile
39 changes: 39 additions & 0 deletions docker/Dockerfile-aws
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
FROM nccgroup/scoutsuite-base:5.13.0-01

LABEL maintainer="Jason Ross <algorythm@gmail.com>"

ARG BUILD_DATE
ARG NAME
ARG DESCRIPTION
ARG VCS_REF
ARG VCS_URL
ARG VENDOR
ARG VERSION
ARG IMAGE_NAME

ENV DEBIAN_FRONTEND=${DEBIAN_FRONTEND}
ENV TERM=${TERM}

# Build-time metadata as defined at http://label-schema.org
LABEL \
org.label-schema.schema-version="1.0" \
org.label-schema.build-date="${BUILD_DATE}" \
org.label-schema.name="${NAME}" \
org.label-schema.description="${DESCRIPTION}" \
org.label-schema.vcs-ref="${VCS_REF}" \
org.label-schema.vcs-url="${VCS_URL}" \
org.label-schema.vendor="${VENDOR}" \
org.label-schema.version="${VERSION}" \
org.label.image-name="${IMAGE_NAME}"

# Copy helper scripts to container
ADD bin /root/bin

# Install AWS CLI
RUN ["/bin/bash", "-c", "/root/bin/container-install-aws2.sh"]

# Remove scripts
RUN ["rm", "-rf", "/root/bin"]

# Command
CMD ["/bin/bash"]
39 changes: 39 additions & 0 deletions docker/Dockerfile-azure
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
FROM nccgroup/scoutsuite-base:5.13.0-01

LABEL maintainer="Jason Ross <algorythm@gmail.com>"

ARG BUILD_DATE
ARG NAME
ARG DESCRIPTION
ARG VCS_REF
ARG VCS_URL
ARG VENDOR
ARG VERSION
ARG IMAGE_NAME

ENV DEBIAN_FRONTEND=${DEBIAN_FRONTEND}
ENV TERM=${TERM}

# Build-time metadata as defined at http://label-schema.org
LABEL \
org.label-schema.schema-version="1.0" \
org.label-schema.build-date="${BUILD_DATE}" \
org.label-schema.name="${NAME}" \
org.label-schema.description="${DESCRIPTION}" \
org.label-schema.vcs-ref="${VCS_REF}" \
org.label-schema.vcs-url="${VCS_URL}" \
org.label-schema.vendor="${VENDOR}" \
org.label-schema.version="${VERSION}" \
org.label.image-name="${IMAGE_NAME}"

# Copy helper scripts to container
ADD bin /root/bin

# Install Azure CLI
RUN ["/bin/bash", "-c", "/root/bin/container-install-azure.sh"]

# Remove scripts
RUN ["rm", "-rf", "/root/bin"]

# Command
CMD ["/bin/bash"]
45 changes: 45 additions & 0 deletions docker/Dockerfile-base
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
FROM python:3.12

LABEL maintainer="Jason Ross <algorythm@gmail.com>"

ARG BUILD_DATE
ARG NAME
ARG DESCRIPTION
ARG VCS_REF
ARG VCS_URL
ARG VENDOR
ARG VERSION
ARG IMAGE_NAME

ENV DEBIAN_FRONTEND=${DEBIAN_FRONTEND}
ENV TERM=${TERM}

# Build-time metadata as defined at http://label-schema.org
LABEL \
org.label-schema.schema-version="1.0" \
org.label-schema.build-date="${BUILD_DATE}" \
org.label-schema.name="${NAME}" \
org.label-schema.description="${DESCRIPTION}" \
org.label-schema.vcs-ref="${VCS_REF}" \
org.label-schema.vcs-url="${VCS_URL}" \
org.label-schema.vendor="${VENDOR}" \
org.label-schema.version="${VERSION}" \
org.label.image-name="${IMAGE_NAME}"

# Copy helper scripts to container
ADD bin /root/bin

# Install required software
RUN ["/bin/bash", "-c", "/root/bin/container-install-prereqs.sh"]

# Install ScoutSuite
RUN ["/bin/bash", "-c", "/root/bin/container-install-scoutsuite.sh"]

# Set a nice message
RUN ["/bin/bash", "-c", "/root/bin/container-set-init.sh"]

# Remove scripts
RUN ["rm", "-rf", "/root/bin"]

# Command
CMD ["/bin/bash"]
39 changes: 39 additions & 0 deletions docker/Dockerfile-gcp
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
FROM nccgroup/scoutsuite-base:5.13.0-01

LABEL maintainer="Jason Ross <algorythm@gmail.com>"

ARG BUILD_DATE
ARG NAME
ARG DESCRIPTION
ARG VCS_REF
ARG VCS_URL
ARG VENDOR
ARG VERSION
ARG IMAGE_NAME

ENV DEBIAN_FRONTEND=${DEBIAN_FRONTEND}
ENV TERM=${TERM}

# Build-time metadata as defined at http://label-schema.org
LABEL \
org.label-schema.schema-version="1.0" \
org.label-schema.build-date="${BUILD_DATE}" \
org.label-schema.name="${NAME}" \
org.label-schema.description="${DESCRIPTION}" \
org.label-schema.vcs-ref="${VCS_REF}" \
org.label-schema.vcs-url="${VCS_URL}" \
org.label-schema.vendor="${VENDOR}" \
org.label-schema.version="${VERSION}" \
org.label.image-name="${IMAGE_NAME}"

# Copy helper scripts to container
ADD bin /root/bin

# Install gCloud SDK
RUN ["/bin/bash", "-c", "/root/bin/container-install-gcp.sh"]

# Remove scripts
RUN ["rm", "-rf", "/root/bin"]

# Command
CMD ["/bin/bash"]
8 changes: 4 additions & 4 deletions docker/bin/container-install-prereqs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,13 @@ apt-get install -qy \
less \
lsb-release \
nano \
python3 \
python3-pip \
# python3 \
# python3-pip \
tzdata \
unzip \
vim \
virtualenv \
virtualenvwrapper \
# virtualenv \
# virtualenvwrapper \
wget

echo -e "\n\nSoftware Pre-reqs Installation Complete!\n\n"
Loading