Skip to content

Hugo [staging all]

Hugo [staging all] #18

Workflow file for this run

name: Hugo
run-name: Hugo [${{ github.event.inputs.environment }} ${{ github.event.inputs.family }}]
on:
workflow_dispatch:
inputs:
environment:
description: 'Build environment'
type: environment
default: staging
required: true
family:
description: 'Product family'
type: choice
options: [all, home, pdf, cells, slides, tasks, html, gis]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@main
with:
repository: Aspose/products.aspose.dev
token: ${{ secrets.REPO_TOKEN }}
fetch-depth: 0
- uses: actions/setup-node@v4
- uses: peaceiris/actions-hugo@v3
with:
hugo-version: 'latest'
extended: true
- name: Prepare
run: |
wget -O- https://products.aspose.dev/generated.tar.xz | tar xJ
npm install
npm run configure
- name: Build
run: hugo -b "${{ secrets.BASE_URL }}" --minify --templateMetrics --templateMetricsHints --enableGitInfo
- name: Deploy to S3
run: hugo deploy --maxDeletes 0 --target "${{ github.event.inputs.environment }}" --invalidateCDN --force
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}