Deployment - QCArchive Prod Docker Environments #43
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
# deployment of qcarchive prod environments for docker deployments | |
name: Deployment - QCArchive Prod Docker Environments | |
on: | |
# run once prod env deployments are in place | |
#workflow_run: | |
# workflows: ["Deployment - QCArchive Prod Environments"] | |
# branches: [master] | |
# types: | |
# - completed | |
workflow_dispatch: | |
jobs: | |
build-deploy-docker: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
env-name: | |
#- qcarchive-worker-openff-ani | |
#- qcarchive-worker-openff-openmm | |
- qcarchive-worker-openff-psi4 | |
- qcarchive-worker-openff-psi4-ddx | |
#- qcarchive-worker-openff-xtb | |
steps: | |
- name: Checkout code | |
uses: nschloe/action-cached-lfs-checkout@v1 | |
- name: ensure we only have one instance running | |
uses: softprops/turnstyle@master | |
env: | |
GITHUB_TOKEN: ${{ secrets.GH_DANGERBOT_TOKEN_LIMITED }} | |
with: | |
abort-after-seconds: 60 | |
- name: Log in to the Container registry | |
uses: docker/login-action@65b78e6e13532edd9afa3aa52ac7964289d1a9c1 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Inject environment name into Dockerfile | |
shell: bash | |
env: | |
ENV_NAME: ${{ matrix.env-name }} | |
BUILD_DIR: ./devtools/docker/qcarchive-worker-openff | |
run: | | |
mkdir ${BUILD_DIR}/tmp/ | |
envsubst < ${BUILD_DIR}/Dockerfile > ${BUILD_DIR}/tmp/Dockerfile | |
cat ${BUILD_DIR}/tmp/Dockerfile | |
- name: Build and push Docker images | |
uses: docker/build-push-action@v6 | |
with: | |
context: . | |
push: true | |
tags: ghcr.io/${{ github.repository }}:${{ matrix.env-name }}-latest | |
file: ./devtools/docker/qcarchive-worker-openff/tmp/Dockerfile | |
#path: ./devtools/docker/qcarchive-worker-openff/tmp/ | |
#username: ${{ secrets.DOCKERHUB_USERNAME }} | |
#password: ${{ secrets.DOCKERHUB_PASSWORD }} | |
#repository: openforcefield/${{ matrix.env-name }} | |
#add_git_labels: true | |
#tag_with_ref: true | |
#tag_with_sha: true |