Skip to content

Fix GitHub Actions permissions #4

Fix GitHub Actions permissions

Fix GitHub Actions permissions #4

Workflow file for this run

name: Deploy Docusaurus to GitHub Pages
on:
push:
branches:
- main
permissions:
contents: write # Grants write access to the repo
pages: write # Allows updating GitHub Pages
id-token: write # Required for secure deployments
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
persist-credentials: false # Avoid using SSH keys
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 18
cache: 'yarn'
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Build Docusaurus site
run: yarn build
- name: Deploy to GitHub Pages
env:
GIT_USER: github-actions[bot]
USE_SSH: false
GIT_URL: https://github.com/blacksky-algorithms/blacksky-algorithms.github.io.git
run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
yarn deploy