Skip to content

Merge branch 'main' of https://github.com/mc-cloud-town/cloudtown-web… #18

Merge branch 'main' of https://github.com/mc-cloud-town/cloudtown-web…

Merge branch 'main' of https://github.com/mc-cloud-town/cloudtown-web… #18

Workflow file for this run

name: deploy
on:
push:
branches: [main]
workflow_dispatch:
jobs:
deploy:
runs-on: ubuntu-latest
permissions:
pages: write
id-token: write
steps:
- uses: actions/checkout@v4
- name: Setup Node.js v20.x
uses: actions/setup-node@v4
with:
node-version: 20
cache: yarn
- name: Install
run: yarn install
- name: Build
run: yarn build
env:
BASE_URL: /cloudtown-website
HOSTNAME: https://mc-cloud-town.github.io/
- name: deploy
run: |
cd dist
[ -f 404.html ] || ln -s index.html 404.html
if [ "none" != "$cname" ]; then echo "$cname" > CNAME; fi
- name: Fix permissions
run: |
chmod -c -R +rX "_site/" | while read line; do
echo "::warning title=Invalid file permissions automatically fixed::$line"
done
- name: Setup Pages
uses: actions/configure-pages@v4
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
# Upload entire repository
path: './dist'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4