Skip to content

Commit 10ec5e6

Browse files
authored
Merge pull request #535 from t3h2mas/external-db-build-args
External db build args
2 parents c0f2907 + f77298a commit 10ec5e6

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

Dockerfile

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,23 @@ MAINTAINER Matt Tesauro <[email protected]>
33

44
# # # Create a single Docker image running DefectDojo and all dependencies
55

6+
# Setup database environment variables. Used to setup an external
7+
# database, and is optional.
8+
# Set a variable using build args.
9+
# i.e. `docker build --build-arg DBNAME="db.foopy.com" ...`
10+
11+
ARG SQLHOST=""
12+
ARG SQLPORT=""
13+
ARG SQLUSER=""
14+
ARG SQLPWD=""
15+
ARG DBNAME=""
16+
17+
ENV SQLHOST=$SQLHOST
18+
ENV SQLPORT=$SQLPORT
19+
ENV SQLUSER=$SQLUSER
20+
ENV SQLPWD=$SQLPWD
21+
ENV DBNAME=$DBNAME
22+
623
# Update and install basic requirements;
724
# Install mysql-server already at this place, since we want to avoid
825
# interactivity when creating a Docker image;

0 commit comments

Comments
 (0)