Skip to content

Commit

Permalink
change release to vcell.cam.uchc.edu and K8s instead of Swarm
Browse files Browse the repository at this point in the history
  • Loading branch information
jcschaff committed Jul 12, 2024
1 parent 8366d9e commit 2454464
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 283 deletions.
43 changes: 3 additions & 40 deletions .github/workflows/site_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ on:
vcell_version:
description: 'version.major.minor'
required: true
default: '7.5.0'
default: '7.6.0'
vcell_build:
description: 'build number'
required: true
default: '148'
default: '18'
vcell_site:
description: 'rel or alpha or test (note rel is Swarm, alpha and test are Kubernetes)'
description: 'rel or alpha or test'
required: true
default: 'alpha'
server_only:
Expand Down Expand Up @@ -208,7 +208,6 @@ jobs:
set -ux
mvn clean install -DskipTests
- name: deploy installers and singularity to kubernetes site and web help to vcell.org
if: ${{ github.event.inputs.vcell_site != 'rel' }}
run: |
set -ux
cd docker/swarm
Expand Down Expand Up @@ -251,49 +250,13 @@ jobs:
echo "KUSTOMIZE_OVERLAY=${KUSTOMIZE_OVERLAY}" >> $GITHUB_ENV
echo "CONTAINER_IMAGE_TAG=${CONTAINER_IMAGE_TAG}" >> $GITHUB_ENV
- name: Call webhook to deploy to kubernetes cluster (overlay 'prod', 'dev' or 'stage')
if: ${{ github.event.inputs.vcell_site != 'rel' }}
run: |
git_sha=$(git rev-parse --short "$GITHUB_SHA")
echo '{"ref": "main","inputs":{"overlay": "'${KUSTOMIZE_OVERLAY}'","tag":"'${CONTAINER_IMAGE_TAG}'","swversion": "'${VCELL_SWVERSION}'"}}' >body
curl -X POST 'https://api.github.com/repos/virtualcell/vcell-fluxcd/actions/workflows/deploy.yaml/dispatches' \
-H 'Authorization: Bearer ${{ secrets.ACTION_TOKEN }}' \
-H 'Content-Type: application/json' \
--data "@body"
- name: deploy to swarm site
if: ${{ github.event.inputs.vcell_site == 'rel' }}
run: |
set -ux
cd docker/swarm
ssh -t ${{ secrets.CD_FULL_USER }}@${VCELL_MANAGER_NODE} sudo docker login -u ${{ secrets.ACTION_USER }} -p ${{ secrets.ACTION_TOKEN }} ghcr.io
if ${{ github.event.inputs.server_only != 'true' }}; then
# build and install the client installers, singularity images, and docker swarm configuration
./deploy-action-swarm.sh \
--ssh-user ${{ secrets.CD_FULL_USER }} \
--install-singularity \
--build-installers \
--installer-deploy-dir $VCELL_INSTALLER_REMOTE_DIR \
${VCELL_MANAGER_NODE} \
./${VCELL_CONFIG_FILE_NAME} \
${VCELL_DEPLOY_REMOTE_DIR}/config/${VCELL_CONFIG_FILE_NAME} \
./docker-compose.yml \
${VCELL_DEPLOY_REMOTE_DIR}/config/docker-compose_${VCELL_TAG}.yml \
vcell${VCELL_SITE}
export VCELL_SITE_CAMEL=`cat $VCELL_CONFIG_FILE_NAME | grep VCELL_SITE_CAMEL | cut -d"=" -f2`
ssh ${{ secrets.CD_FULL_USER }}@${VCELL_MANAGER_NODE} \
installer_deploy_dir=$VCELL_INSTALLER_REMOTE_DIR vcell_siteCamel=$VCELL_SITE_CAMEL vcell_version=$VCELL_VERSION vcell_build=$VCELL_BUILD \
'bash -s' < link-installers.sh
else
# build and install only the singularity images and docker swarm configuration
./deploy-action-swarm.sh \
--ssh-user ${{ secrets.CD_FULL_USER }} \
--install-singularity \
${VCELL_MANAGER_NODE} \
./${VCELL_CONFIG_FILE_NAME} \
${VCELL_DEPLOY_REMOTE_DIR}/config/${VCELL_CONFIG_FILE_NAME} \
./docker-compose.yml \
${VCELL_DEPLOY_REMOTE_DIR}/config/docker-compose_${VCELL_TAG}.yml \
vcell${VCELL_SITE}
fi
- name: Setup tmate session 3
uses: mxschmitt/action-tmate@v3
if: ${{ failure() }}
Expand Down
237 changes: 0 additions & 237 deletions docker/swarm/deploy-action-swarm.sh

This file was deleted.

12 changes: 6 additions & 6 deletions docker/swarm/serverconfig-uch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,11 @@ vcell_slurm_qos_pu=vcellpu
case $VCELL_SITE in
REL)
_site_port_offset=0
VCELL_API_HOST_EXTERNAL=vcellapi.cam.uchc.edu
VCELL_S3_EXPORT_BASEURL=https://vcellapi.cam.uchc.edu
VCELL_API_HOST_EXTERNAL=vcell.cam.uchc.edu
VCELL_S3_EXPORT_BASEURL=https://vcell.cam.uchc.edu
VCELL_API_PORT_EXTERNAL=443
VCELL_API_PREFIX_V0=""
VCELL_API_PREFIX_V1=""
VCELL_API_PREFIX_V0="/api/v0"
VCELL_API_PREFIX_V1="/api/v1"
_applicationId="1471-8022-1038-5553"
;;
ALPHA)
Expand Down Expand Up @@ -115,8 +115,8 @@ VCELL_SSH_CMD_RESTORE_TIMEOUT=5

#
# write out the environment file to be for:
# 1. deployment actions (e.g. deploy-action-swarm.sh or deploy-action-kubernetes.sh)
# 2. runtime environment for the docker stack run command (Docker swarm mode only, kubernetes uses ConfigMaps in vcell-fluxcd repo)
# 1. deployment actions (e.g. deploy-action-kubernetes.sh)
# 2. runtime environment for the docker stack run command (kubernetes uses ConfigMaps in vcell-fluxcd repo), what about VCell Installers?
#
cat <<EOF >"$_outputfile"
VCELL_API_HOST_EXTERNAL=$VCELL_API_HOST_EXTERNAL
Expand Down

0 comments on commit 2454464

Please sign in to comment.