Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
gdd-sigma-poc
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Guillaume WANG
gdd-sigma-poc
Commits
9f9f8aa1
Commit
9f9f8aa1
authored
6 years ago
by
Wilson JALLET
Browse files
Options
Downloads
Patches
Plain Diff
inject password inside Dockerfile, inject in Docker thru GitLab CI
parent
13987ced
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.gitlab-ci.yml
+1
-1
1 addition, 1 deletion
.gitlab-ci.yml
Dockerfile
+1
-1
1 addition, 1 deletion
Dockerfile
knexfile.js
+2
-2
2 additions, 2 deletions
knexfile.js
with
4 additions
and
4 deletions
.gitlab-ci.yml
+
1
−
1
View file @
9f9f8aa1
...
@@ -51,7 +51,7 @@ docker:build:
...
@@ -51,7 +51,7 @@ docker:build:
-
echo $LDAP_CONN_CONFIG > ldap_connexion_config.json
-
echo $LDAP_CONN_CONFIG > ldap_connexion_config.json
-
docker login -u gitlab-ci-token -p $CI_BUILD_TOKEN $CI_REGISTRY
-
docker login -u gitlab-ci-token -p $CI_BUILD_TOKEN $CI_REGISTRY
-
echo "Building Dockerfile..."
-
echo "Building Dockerfile..."
-
docker build --pull -t ${CI_APPLICATION_REPOSITORY}:${CI_APPLICATION_TAG} -t ${CI_APPLICATION_REPOSITORY}:latest --build-arg TARGET_ENV=staging .
-
docker build --pull -t ${CI_APPLICATION_REPOSITORY}:${CI_APPLICATION_TAG} -t ${CI_APPLICATION_REPOSITORY}:latest --build-arg TARGET_ENV=staging
--build-arg DB_PASSWD=${DB_PASSWD}
.
-
echo "Pushing to GitLab Container registry $CI_APPLICATION_REPOSITORY with tags '${CI_APPLICATION_TAG}' and 'latest'"
-
echo "Pushing to GitLab Container registry $CI_APPLICATION_REPOSITORY with tags '${CI_APPLICATION_TAG}' and 'latest'"
-
docker push ${CI_APPLICATION_REPOSITORY}:${CI_APPLICATION_TAG}
-
docker push ${CI_APPLICATION_REPOSITORY}:${CI_APPLICATION_TAG}
-
docker push ${CI_APPLICATION_REPOSITORY}:latest
-
docker push ${CI_APPLICATION_REPOSITORY}:latest
...
...
This diff is collapsed.
Click to expand it.
Dockerfile
+
1
−
1
View file @
9f9f8aa1
...
@@ -11,9 +11,9 @@ COPY package*.json ./
...
@@ -11,9 +11,9 @@ COPY package*.json ./
RUN
npm
install
--only
=
production
&&
npm i
-g
knex
RUN
npm
install
--only
=
production
&&
npm i
-g
knex
ARG
TARGET_ENV
ARG
TARGET_ENV
ARG
LDAP_URI=ldap://frankiz.eleves.polytechnique.fr:389
ENV
HOST=0.0.0.0
ENV
HOST=0.0.0.0
ENV
NODE_ENV=production
ENV
NODE_ENV=production
ENV
LDAP_URI=ldap://frankiz.eleves.polytechnique.fr:389
COPY
. .
COPY
. .
...
...
This diff is collapsed.
Click to expand it.
knexfile.js
+
2
−
2
View file @
9f9f8aa1
...
@@ -34,9 +34,9 @@ module.exports = {
...
@@ -34,9 +34,9 @@ module.exports = {
client
:
'
pg
'
,
client
:
'
pg
'
,
connection
:
{
connection
:
{
host
:
process
.
env
.
DB_HOST
||
'
129.201.104.10
'
,
host
:
process
.
env
.
DB_HOST
||
'
129.201.104.10
'
,
user
:
'
will
'
,
user
:
process
.
env
.
DB_USER
||
'
sigma
'
,
password
:
process
.
env
.
DB_PASSWD
||
'
password
'
,
password
:
process
.
env
.
DB_PASSWD
||
'
password
'
,
database
:
'
sigma_
dev
'
,
database
:
'
sigma_
staging
'
,
charset
:
'
utf8
'
charset
:
'
utf8
'
},
},
...
knexConfig
...
knexConfig
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment