You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
33 lines
1006 B
YAML
33 lines
1006 B
YAML
name: Deploy Production
|
|
#on:
|
|
# push:
|
|
# tags:
|
|
# - 'v*'
|
|
on:
|
|
release:
|
|
types: [published]
|
|
|
|
jobs:
|
|
deploy:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
with:
|
|
fetch-depth: 0 # needs to be complete for later push
|
|
ref: master
|
|
- name: Set env
|
|
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
|
|
- name: echo tag
|
|
run: echo "---- about to deploy tag ${RELEASE_VERSION}"
|
|
- name: Push to Production Repo
|
|
run: |
|
|
git push https://${{ secrets.P_USER }}:${{ secrets.P_PASSWD }}@${{ secrets.P_URL_HUGO_TEST }} master ${RELEASE_VERSION}
|
|
- name: Push to new Production Repo
|
|
run: |
|
|
git push https://${{ secrets.P_USER }}:${{ secrets.P_PASSWD }}@${{ secrets.P_URL }} master ${RELEASE_VERSION}
|
|
# needs the following secrets in repo:
|
|
# gh secret set P_USER -b <value> -R seuh2022/seuh2022
|
|
# gh secret set P_PASSWD
|
|
# gh secret set P_URL
|
|
# gh secret set P_URL_HUGO_TEST
|