Skip to content

Bump the github-actions-updates group with 4 updates #442

Bump the github-actions-updates group with 4 updates

Bump the github-actions-updates group with 4 updates #442

Workflow file for this run

name: site
on:
push:
branches:
tags:
paths:
- ".github/workflows/ci-site.yml"
- "site/**"
- "README.md"
- "Dockerfile.site"
pull_request:
paths:
- ".github/workflows/ci-site.yml"
- "site/**"
- "README.md"
- "Dockerfile.site"
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v4
- name: build and deploy master image site to ghcr.io and dockerhub
if: ${{ github.ref == 'refs/heads/master' }}
env:
GITHUB_PACKAGE_TOKEN: ${{ secrets.PKG_TOKEN }}
USERNAME: ${{ github.actor }}
GITHUB_SHA: ${{ github.sha}}
GITHUB_REF: ${{ github.ref}}
run: |
ref="$(echo ${GITHUB_REF} | cut -d'/' -f3)"
echo GITHUB_REF - $ref
echo ${GITHUB_PACKAGE_TOKEN} | docker login ghcr.io -u ${USERNAME} --password-stdin
docker build -f Dockerfile.site --no-cache -t ghcr.io/${USERNAME}/simplotask-site:${ref} .
docker push ghcr.io/${USERNAME}/simplotask-site:${ref}
- name: deploy tagged (latest) site to ghcr.io and dockerhub
if: ${{ startsWith(github.ref, 'refs/tags/') }}
env:
GITHUB_PACKAGE_TOKEN: ${{ secrets.PKG_TOKEN }}
USERNAME: ${{ github.actor }}
GITHUB_SHA: ${{ github.sha}}
GITHUB_REF: ${{ github.ref}}
run: |
ref="$(echo ${GITHUB_REF} | cut -d'/' -f3)"
echo GITHUB_REF - $ref
echo ${GITHUB_PACKAGE_TOKEN} | docker login ghcr.io -u ${USERNAME} --password-stdin
docker build -f Dockerfile.site --no-cache -t ghcr.io/${USERNAME}/simplotask-site:${ref} \
-t ghcr.io/${USERNAME}/simplotask-site:latest .
- name: remote site deployment from master
if: ${{ github.ref == 'refs/heads/master' }}
env:
UPDATER_KEY: ${{ secrets.UPDATER_KEY }}
run: curl https://jess.umputun.com/update/simplotask-site/${UPDATER_KEY}