Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Observatoire
observatoire-scripts
Commits
a57bb249
Commit
a57bb249
authored
Dec 01, 2021
by
Pierre Dittgen
Browse files
Update Docker build/CI
parent
09d15b12
Pipeline
#3291
failed with stages
in 183 minutes and 41 seconds
Changes
3
Pipelines
4
Hide whitespace changes
Inline
Side-by-side
.dockerignore
0 → 100644
View file @
a57bb249
*
!/requirements.txt
\ No newline at end of file
.gitlab-ci.yml
View file @
a57bb249
stages
:
-
docker
-
build
-
process
-
deploy
Build Docker image
:
stage
:
docker
only
:
changes
:
-
Dockerfile.ci
-
requirements.txt
refs
:
-
master
variables
:
# Do not build Docker image from scheduled jobs.
# Cf https://gitlab.com/gitlab-org/gitlab/issues/27318#note_215688359
-
$CI_PIPELINE_SOURCE == "push"
stage
:
build
rules
:
-
if
:
$CI_PIPELINE_SOURCE == "push"
changes
:
-
Dockerfile
-
requirements.txt
when
:
always
image
:
name
:
gcr.io/kaniko-project/executor:debug
entrypoint
:
[
"
"
]
script
:
-
echo "{\"auths\":{\"$CI_REGISTRY\":{\"username\":\"$CI_REGISTRY_USER\",\"password\":\"$CI_REGISTRY_PASSWORD\"}}}" > /kaniko/.docker/config.json
-
/kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/Dockerfile
.ci
--destination $CI_REGISTRY_IMAGE:
$CI_COMMIT_TAG
-
/kaniko/executor
--cache
--context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/Dockerfile --destination $CI_REGISTRY_IMAGE:
latest
Download and generate data
:
stage
:
build
stage
:
process
except
:
-
pushes
image
:
$CI_REGISTRY_IMAGE:latest
...
...
Dockerfile
.ci
→
Dockerfile
View file @
a57bb249
FROM python:3.
7
-buster
FROM
python:3.
9-slim
-buster
LABEL
maintainer="contact@jailbreak.paris"
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment