-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Sohail Ismail
committed
Dec 27, 2023
1 parent
cdb794c
commit 19517f6
Showing
1 changed file
with
44 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
name: github-pages | ||
|
||
on: | ||
push: | ||
branches: | ||
- main # Set a branch to deploy | ||
# Allows you to run this workflow manually from the Actions tab | ||
workflow_dispatch: | ||
|
||
jobs: | ||
deploy: | ||
runs-on: macos-latest | ||
steps: | ||
- name: Checkout blog repo | ||
uses: actions/checkout@main | ||
with: | ||
repository: Aspose/aspose.ai | ||
token: ${{ secrets.REPO_TOKEN }} | ||
#submodules: true # Fetch Hugo themes (true OR recursive) | ||
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod | ||
|
||
- name: Setup Hugo | ||
uses: peaceiris/actions-hugo@v2.4.13 | ||
with: | ||
hugo-version: '0.101.0' | ||
extended: true | ||
|
||
- name: Build | ||
run: hugo --config "config-master-www.toml" --cleanDestinationDir --minify | ||
|
||
- name: Deploy Home to S3 | ||
run: hugo deploy --maxDeletes -1 --target "production" | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.ACCESS_KEY }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.SECRET_ACCESS }} | ||
|
||
#- name: Invalidate CloudFront | ||
# uses: chetan/invalidate-cloudfront-action@v2 | ||
# env: | ||
# DISTRIBUTION: ${{ secrets.CLOUDFRONT_DISTRIBUTION_ID }} | ||
# PATHS: '/*' | ||
# AWS_REGION: 'us-west-2' | ||
# AWS_ACCESS_KEY_ID: ${{ secrets.ACCESS_KEY }} | ||
# AWS_SECRET_ACCESS_KEY: ${{ secrets.SECRET_ACCESS }} |