-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DEVOPS-1037 Update Condor Base Image and DeDockerize #31
base: develop
Are you sure you want to change the base?
Changes from 69 commits
17ab79d
e44811f
e059475
ab7d1f3
1aaf967
f0dd74b
53a1113
10cc323
fe4148a
f7502f5
d69a959
b837f80
3cc6169
dc3795f
5f7ad37
8ce4126
52c65f7
5419552
40edb63
be0da48
3c6b33a
fe74413
8bec267
f8859c5
8893fa0
ba089da
91aa571
68008b1
72ea862
40a477d
95fff1c
3bb1f3b
232214f
9c4589c
d4c6c86
55efe0d
d28ebd0
c1ad040
d4bccbc
d2513c5
4f73903
94187ab
8ea3efb
fb84e31
9125a5b
ed89315
e5cc148
9ab0313
6bfc66b
25dc835
6ab4f72
f4c066f
a9f2e0c
dcd5867
24eba9c
9a2a2bd
d22e0e1
6de7fc0
805d741
c59e5d5
d3eebe1
f1288ab
d329062
dd8c25e
fc86bb3
7bec145
6f9ffc1
fd7065a
28a61df
b994bd7
0a38361
d32b4ab
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
--- | ||
name: Manual Build & Push | ||
on: | ||
workflow_dispatch: | ||
jobs: | ||
build-push: | ||
uses: kbase/.github/.github/workflows/reusable_build-push.yml@main | ||
with: | ||
name: '${{ github.event.repository.name }}-develop' | ||
tags: br-${{ github.ref_name }} | ||
secrets: inherit |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,41 +1,7 @@ | ||
FROM htcondor/cm:9.11-el7 | ||
FROM htcondor/cm:9.12.0-el7 | ||
RUN useradd -m condor_pool && usermod -a -G condor condor_pool | ||
|
||
# These ARGs values are passed in via the docker build command | ||
ARG BUILD_DATE | ||
ARG VCS_REF | ||
ARG BRANCH=develop | ||
|
||
|
||
# Get commonly used utilities | ||
RUN yum -y install deltarpm | ||
RUN yum -y update && yum upgrade -y | ||
RUN yum -y install epel-release wget which git deltarpm gcc libcgroup libcgroup-tools stress-ng | ||
|
||
# Install DOCKERIZE | ||
RUN curl -o /tmp/dockerize.tgz https://raw.githubusercontent.com/kbase/dockerize/dist/dockerize-linux-amd64-v0.5.0.tar.gz && \ | ||
cd /usr/bin && \ | ||
tar xvzf /tmp/dockerize.tgz && \ | ||
rm /tmp/dockerize.tgz | ||
|
||
#ADD DIRS | ||
RUN mkdir -p /var/run/condor && mkdir -p /var/log/condor && mkdir -p /var/lock/condor && mkdir -p /var/lib/condor/execute | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Old line for creating dirs |
||
|
||
COPY deployment/conf /etc/condor/ | ||
COPY deployment/bin/start-condor.sh /usr/sbin/start-condor.sh | ||
RUN adduser condor_pool | ||
RUN mkdir -p /usr/local/condor/run/condor /usr/local/condor/log/condor /usr/local/condor/lock/condor /usr/local/condor/lib/condor/spool /usr/local/condor/lib/condor/execute | ||
|
||
|
||
# The BUILD_DATE value seem to bust the docker cache when the timestamp changes, move to | ||
# the end | ||
LABEL org.label-schema.build-date=$BUILD_DATE \ | ||
org.label-schema.vcs-url="https://github.com/kbase/condor.git" \ | ||
org.label-schema.vcs-ref=$VCS_REF \ | ||
org.label-schema.schema-version="1.0.0-rc1" \ | ||
us.kbase.vcs-branch=$BRANCH \ | ||
maintainer="Steve Chan sychan@lbl.gov" | ||
|
||
ENTRYPOINT [ "/usr/bin/dockerize" ] | ||
CMD [ "-template", "/etc/condor/.templates/condor_config.local.templ:/etc/condor/condor_config.local", \ | ||
"-stdout", "/var/log/condor/SchedLog", \ | ||
"/usr/sbin/start-condor.sh" ] | ||
COPY pre-exec.sh /root/config/pre-exec.sh | ||
COPY health_check.sh /health_check.sh | ||
# See https://www-auth.cs.wisc.edu/lists/htcondor-users/2014-August/msg00044.shtml | ||
COPY kbase_central_manager.conf /etc/condor/condor_config.local |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,27 @@ | ||
# condor | ||
# Condor Central Manager and Schedd | ||
|
||
KBase specific Condor scheduler image. | ||
KBase specific condor scheduler image. | ||
Based on the htcondor/cm:9.X images | ||
|
||
## Supported ENV Variables | ||
## New behavior | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ugh, looks like I forgot to update this with the variables from pre-exec.sh. Will have to do that next |
||
* Copy credentials from environment into correct place as per the [docs](https://github.com/htcondor/htcondor/tree/main/build/docker/services#providing-additional-configuration) | ||
* Enabled the `SCHEDD` to run in the same container as the `COLLECTOR` | ||
|
||
# Supported ENV Variables used by [pre-exec.sh](deployment/bin/pre-exec.sh) | ||
|
||
|
||
- `CONDOR_CONFIG_FILEPATH` - A path to a configfile to be copied into /etc/condor/condor_config.local | ||
- `POOL_PASSWORD` - The password for the condor pool (to be deprecated by token) | ||
- `JWT_TOKEN` - CM Token created by `condor_token_create -identity condor-central-manager` | ||
- `SCHEDD_HOST` - If Present, then `SCHEDD` added to `DAEMON_LIST` | ||
|
||
|
||
# ENV Vars used by [start.sh](https://github.com/htcondor/htcondor/blob/fa22cbcdc2c66c63d1f5a78a45606125aa44e165/build/docker/services-rhel/base/start.sh) | ||
|
||
* `CONDOR_SERVICE_HOST` "${CONDOR_SERVICE_HOST:-${CONDOR_HOST:-\$(FULL_HOSTNAME)}}" | ||
* `CONDOR_HOST` "${CONDOR_SERVICE_HOST:-${CONDOR_HOST:-\$(FULL_HOSTNAME)}}" | ||
* `NUM_CPU` "${NUM_CPUS:-1}" \ | ||
* `MEMORY` "${MEMORY:-1024}" \ | ||
* `RESERVED_DISK` "${RESERVED_DISK:-1024}" \ | ||
* `USE_POOL_PASSWORD` "${USE_POOL_PASSWORD:-no}" | ||
|
||
- CONDOR_CONFIG_FILEPATH - A path to a configfile to be copied into /etc/condor/condor_config.local | ||
- POOL_PASSWORD - The password for the condor pool (to be deprecated by token) |
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#!/usr/bin/env bash | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe this should be documented somewhere? This will need to be run on each environment we deploy |
||
# Example of how to generate ids using the autogenerated signing key | ||
UID_DOMAIN=condor.staging.kbase.us | ||
condor_token_create -identity kbase_workers@${UID_DOMAIN} -token kbase_workers | ||
condor_token_create -identity nersc_workers@${UID_DOMAIN} -token nersc_workers | ||
condor_token_create -identity rest_api@${UID_DOMAIN} -token rest_api | ||
condor_token_create -identity condor_stats@${UID_DOMAIN} -token condor_stats | ||
|
||
#Used in EE2 Submit | ||
condor_token_create -identity condor_pool@${UID_DOMAIN} -token condor_pool | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#!/usr/bin/env bash | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Could delete this since its currently unused |
||
# This can be run by postStart to see if required variables have been set | ||
|
||
: "${UID_DOMAIN:?Variable not set or empty}" | ||
: "${CONDOR_JWT_TOKEN:?Variable not set or empty}" |
This file was deleted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
New base image, removing extra stuff from dockerfile