Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
ippidb-web
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
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
iPPIDB
ippidb-web
Commits
25cf184b
Commit
25cf184b
authored
3 years ago
by
Bryan BRANCOTTE
Browse files
Options
Downloads
Patches
Plain Diff
build the doc using docker image
parent
73703f8f
No related branches found
No related tags found
2 merge requests
!43
K8S deployments of release branche, and other updates
,
!42
build the doc
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.gitlab-ci.yml
+19
-3
19 additions, 3 deletions
.gitlab-ci.yml
ippisite/.dockerignore
+1
-1
1 addition, 1 deletion
ippisite/.dockerignore
ippisite/Dockerfile
+28
-4
28 additions, 4 deletions
ippisite/Dockerfile
with
48 additions
and
8 deletions
.gitlab-ci.yml
+
19
−
3
View file @
25cf184b
...
@@ -78,9 +78,25 @@ pages:
...
@@ -78,9 +78,25 @@ pages:
stage
:
deploy
stage
:
deploy
dependencies
:
dependencies
:
-
test-pg
-
test-pg
services
:
-
registry-gitlab.pasteur.fr/dsi-tools/docker-images/docker:dind
script
:
script
:
-
mv ippisite/htmlcov public/
-
docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" $CI_REGISTRY
-
mv ippisite/docs/build/html/ public/
# pull the latest build on this branch
-
docker pull "$CI_REGISTRY_IMAGE/$CI_COMMIT_REF_SLUG/web-container:latest" ||
true
# build the image while passing commit SHA and tagging the image with it
-
cd ippisite
-
docker build
--target docs-container
--build-arg CI_COMMIT_REF_SLUG
--build-arg CI_COMMIT_SHA
--cache-from "$CI_REGISTRY_IMAGE/$CI_COMMIT_REF_SLUG/web-container:latest"
--tag ippidb_docs
.
-
mkdir build/
-
docker run -v $(pwd)/build/:/code/docs/build/ ippidb_docs
-
mv build/html/ ../public/
-
mv ../htmlcov ../public/
artifacts
:
artifacts
:
paths
:
paths
:
-
public
-
public
...
@@ -237,4 +253,4 @@ delete-dev-deployment:
...
@@ -237,4 +253,4 @@ delete-dev-deployment:
script
:
script
:
-
echo "Removing $CI_COMMIT_REF_SLUG"
-
echo "Removing $CI_COMMIT_REF_SLUG"
-
helm delete -n ${NAMESPACE} ${CI_COMMIT_REF_SLUG}
-
helm delete -n ${NAMESPACE} ${CI_COMMIT_REF_SLUG}
-
kubectl delete pvc -n ${NAMESPACE} -lapp.kubernetes.io/instance=${CI_COMMIT_REF_SLUG}
-
kubectl delete pvc -n ${NAMESPACE} -lapp.kubernetes.io/instance=${CI_COMMIT_REF_SLUG}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
ippisite/.dockerignore
+
1
−
1
View file @
25cf184b
...
@@ -9,6 +9,6 @@ ippidb.json
...
@@ -9,6 +9,6 @@ ippidb.json
ippidb.json.gz
ippidb.json.gz
db.json
db.json
db.sql.gz
db.sql.gz
db
-django-4.0
.sql.gz
db
*
.sql.gz
persistent/media/*
persistent/media/*
# END OF FILE
# END OF FILE
\ No newline at end of file
This diff is collapsed.
Click to expand it.
ippisite/Dockerfile
+
28
−
4
View file @
25cf184b
###############################################################################
###############################################################################
# B
A
se image containing libs, dependencies
and code
# B
a
se image containing libs, dependencies
###############################################################################
###############################################################################
FROM
python:3.9
AS
base-container
FROM
python:3.9
AS
base-container
-without-sources
EXPOSE
8000
EXPOSE
8000
ENV
PYTHONPATH "${PYTHONPATH}:/usr/lib/python3/dist-packages"
ENV
PYTHONPATH "${PYTHONPATH}:/usr/lib/python3/dist-packages"
...
@@ -16,6 +16,7 @@ RUN addgroup --gid 1000 kiwi \
...
@@ -16,6 +16,7 @@ RUN addgroup --gid 1000 kiwi \
gettext
\
gettext
\
python3-dev
\
python3-dev
\
python3-openbabel
\
python3-openbabel
\
graphviz-dev
\
&&
rm
-rf
/var/lib/apt/lists/
*
\
&&
rm
-rf
/var/lib/apt/lists/
*
\
&&
python
-m
pip
install
--upgrade
pip setuptools
\
&&
python
-m
pip
install
--upgrade
pip setuptools
\
&&
mkdir
/code
&&
mkdir
/code
...
@@ -28,8 +29,13 @@ RUN pip install -r requirements.txt
...
@@ -28,8 +29,13 @@ RUN pip install -r requirements.txt
COPY
./*-entrypoint.sh /
COPY
./*-entrypoint.sh /
RUN
chmod
a+x /
*
-entrypoint
.sh
RUN
chmod
a+x /
*
-entrypoint
.sh
COPY
. /code/
###############################################################################
# Base image plus the sources
###############################################################################
FROM
base-container-without-sources
AS
base-container
COPY
. /code/
###############################################################################
###############################################################################
# django web app
# django web app
...
@@ -57,4 +63,22 @@ ENTRYPOINT ["/docker-celery-entrypoint.sh"]
...
@@ -57,4 +63,22 @@ ENTRYPOINT ["/docker-celery-entrypoint.sh"]
CMD
["celery", "-A", "ippisite", "worker", "-l", "info", "--concurrency", "2"]
CMD
["celery", "-A", "ippisite", "worker", "-l", "info", "--concurrency", "2"]
USER
kiwi
USER
kiwi
\ No newline at end of file
###############################################################################
# build the docs
###############################################################################
FROM
base-container-without-sources
AS
docs-container
ENV
USE_SQLITE_AS_DB True
COPY
requirements*.txt /code/
RUN
pip
install
-r
requirements-dev.txt
\
&&
mkdir
-p
/root/.config/bioservices
CMD
["make", "html" ]
COPY
. /code/
WORKDIR
/code/docs
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