Skip to content

Fix ref.

Fix ref. #1111

Workflow file for this run

# This is a basic workflow to help you get started with Actions
name: CI
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: iterate-ch/[email protected]
with:
docs-folder: "."
build-command: "make dirhtml"
- name: Cache artifacts
uses: actions/cache@v4
if: github.ref == 'refs/heads/main'
with:
key: html-${{ github.sha }}
path: ./_build/dirhtml
deploy:
name: Deploy
runs-on: ubuntu-latest
needs: build
if: github.ref == 'refs/heads/main'
steps:
- uses: actions/checkout@v2
- name: Cache artifacts
uses: actions/cache@v4
with:
key: html-${{ github.sha }}
path: ./_build/dirhtml
- name: Install Cyberduck CLI
run: |
echo -e "deb https://s3.amazonaws.com/repo.deb.cyberduck.io stable main" | sudo tee /etc/apt/sources.list.d/cyberduck.list > /dev/null
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys FE7097963FEFBE72
sudo apt-get update
sudo apt-get -y install duck
- name: Deploy
run: |
echo "Upload ./_build/dirhtml"
duck -y --username ${{ secrets.AWS_ACCESS_KEY_ID }} --password ${{ secrets.AWS_SECRET_ACCESS_KEY }} --existing compare --upload s3:/github-cyberduck-docs/ ./_build/dirhtml/* --region ${{ secrets.AWS_DEFAULT_REGION }}
echo "Purging CDN configuration"
duck -y --username ${{ secrets.AWS_ACCESS_KEY_ID }} --password ${{ secrets.AWS_SECRET_ACCESS_KEY }} --purge s3:/github-cyberduck-docs/