Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
workspaces
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
Package Registry
Model registry
Operate
Environments
Terraform modules
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
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ssa
workspaces
Commits
fcd322bc
Commit
fcd322bc
authored
1 year ago
by
Nathan Bockisch
Browse files
Options
Downloads
Patches
Plain Diff
Resolve workflow Dockerfile conflicts after docker revisions
parent
99a6f974
No related branches found
Branches containing commit
No related tags found
Tags containing commit
2 merge requests
!1452
Merge 2.8.2 to main
,
!1387
WS-1849: Added RADIAL setup to the workflow container
Pipeline
#10390
failed
1 year ago
Stage: pull-db
Stage: build
Stage: unit-test
Stage: .post
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
services/workflow/Dockerfile
+31
-12
31 additions, 12 deletions
services/workflow/Dockerfile
with
31 additions
and
12 deletions
services/workflow/Dockerfile
+
31
−
12
View file @
fcd322bc
...
...
@@ -2,6 +2,10 @@
ARG
LOCAL_OR_SERVER_PEX=local-pex
FROM
python:3.10-slim-buster
as
base
ARG
WS_VERSION=unknown-version
ARG
DEPLOY_ENV
ENV
DEPLOY_ENV=${DEPLOY_ENV}
ARG
ENV_HOST
ENV
ENV_HOST=${ENV_HOST}
# Environment variables
ENV
PIP_NO_CACHE_DIR false
...
...
@@ -29,33 +33,43 @@ RUN addgroup --gid 9233 almapipe && \
# Allow the workflow container to reach the RADIAL cluster for jobs that require it
RUN
echo
"10.64.1.77 radialhead.nrao.radial.local"
>>
/etc/hosts
#
Switch to appuser and set ownership of docker.properties to vlapipe and the vlapipe group
#
needed for unit tests
USER
vlapipe
WORKDIR
/home/ssa/capo
COPY
--chown=vlapipe:vlapipe docker.properties docker.properties
USER
root
WORKDIR
/code/
RUN
chown
vlapipe
.
&&
chgrp
vlapipe .
# Switch to appuser and set ownership of docker.properties to vlapipe and the vlapipe group
USER
vlapipe
WORKDIR
/packages/
RUN
curl
-sSL
https://install.python-poetry.org | python3 -
ENV
PATH "${PATH}:/home/vlapipe/.local/bin"
COPY
--chown=vlapipe:vlapipe ./shared ./shared
COPY
--chown=vlapipe:vlapipe ./apps/cli ./apps/cli
ENV
PATH "${PATH}:/home/vlapipe/.local/bin"
RUN
pip
install
--upgrade
pip
FROM
base
as
local-pex
COPY
--chown=vlapipe:vlapipe ./services/workflow/requirements.txt ./requirements.txt
COPY
--chown=vlapipe:vlapipe ./test-requirements.txt ./test-requirements.txt
RUN
SETUPTOOLS_SCM_PRETEND_VERSION
=
${
WS_VERSION
}
pip
install
--user
-r
requirements.txt
RUN
SETUPTOOLS_SCM_PRETEND_VERSION
=
${
WS_VERSION
}
pip
install
--user
-r
test-requirements.txt
FROM
base
as
server-pex
USER
root
COPY
--chown=vlapipe:vlapipe ./services/workflow/bin/install-pexes.sh ./install-pexes.sh
RUN
.
./install-pexes.sh
COPY
--chown=vlapipe:vlapipe ./services/workflow/requirements.txt ./requirements.txt
COPY
--chown=vlapipe:vlapipe ./test-requirements.txt ./test-requirements.txt
RUN
SETUPTOOLS_SCM_PRETEND_VERSION
=
${
WS_VERSION
}
pip
install
--user
-r
requirements.txt
RUN
SETUPTOOLS_SCM_PRETEND_VERSION
=
${
WS_VERSION
}
pip
install
--user
-r
test-requirements.txt
#COPY --chown=vlapipe:vlapipe ./services/workflow/bin/install-pexes.sh ./install-pexes.sh
#RUN . ./install-pexes.sh
FROM
${LOCAL_OR_SERVER_PEX}
as
pex-base
ARG
DEPLOY_ENV=dev
# HTCondor install
USER
root
RUN
apt update
&&
apt
install
-y
curl gnupg apt-transport-https
...
...
@@ -66,7 +80,7 @@ RUN apt update && apt install -y procps htcondor nano
# HTCondor setup
# Copy over HTCondor submit node config
COPY
/config/htcondor/
00-htcondor-9.0.config
/etc/condor/config.d/00-htcondor-9.0.config
#
00-htcondor-9.0.config
is environment specific, copy handled later
COPY
/config/htcondor/submit/99-workspaces-submit.${DEPLOY_ENV}.conf /etc/condor/config.d/99-workspaces-submit.${DEPLOY_ENV}.conf
COPY
/config/htcondor/submit/nrao-nofile.conf /etc/security/limits.d/nrao-nofile.conf
...
...
@@ -77,23 +91,28 @@ RUN chown vlapipe . && chgrp vlapipe .
# Copy service directory to /code in the image
# set ownership of content to vlapipe and the vlapipe group
USER
vlapipe
COPY
--chown=vlapipe:vlapipe ./services/workflow ./
COPY
--chown=vlapipe:vlapipe ./services/workflow ./services/workflow
WORKDIR
/code/services/workflow
RUN
poetry
install
FROM
pex-base
as
prod
ARG
WS_VERSION=unknown-version
ENV
PYTHONPATH "${PYTHONPATH}:/home/vlapipe/.local"
ENV
PATH "${PATH}:/home/vlapipe/.local/bin"
RUN
SETUPTOOLS_SCM_PRETEND_VERSION
=
${
WS_VERSION
}
pip
install
-e
.
USER
root
C
MD
/co
de/bin/boot-condor-and-workflow.sh
C
OPY
/co
nfig/htcondor/00-htcondor-9.0.config /etc/condor/config.d/00-htcondor-9.0.config
CMD
/code/services/workflow/bin/boot-condor-and-workflow.sh
FROM
pex-base
as
dev
ARG
WS_VERSION=unknown-version
RUN
SETUPTOOLS_SCM_PRETEND_VERSION
=
${
WS_VERSION
}
pip
install
-e
.
ENV
PYTHONPATH "${PYTHONPATH}:/home/vlapipe/.local"
ENV
PATH "${PATH}:/home/vlapipe/.local/bin"
ENV
PATH $PATH:/lustre/aoc/pipeline/$CAPO_PROFILE/workflow
USER
root
COPY
/config/htcondor/00-htcondor-9.0.local.config /etc/condor/config.d/00-htcondor-9.0.config
RUN
condor_master
CMD
/code/bin/boot-condor-and-workflow.sh
CMD
/code/
services/workflow/
bin/boot-condor-and-workflow.sh
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