mirror of
https://github.com/juanfont/headscale.git
synced 2025-01-19 02:10:04 +09:00
697d80d5a8
Some checks are pending
Build / build-nix (push) Waiting to run
Build / build-cross (GOARCH=386 GOOS=linux) (push) Waiting to run
Build / build-cross (GOARCH=amd64 GOOS=darwin) (push) Waiting to run
Build / build-cross (GOARCH=amd64 GOOS=linux) (push) Waiting to run
Build / build-cross (GOARCH=arm GOOS=linux GOARM=5) (push) Waiting to run
Build / build-cross (GOARCH=arm GOOS=linux GOARM=6) (push) Waiting to run
Build / build-cross (GOARCH=arm GOOS=linux GOARM=7) (push) Waiting to run
Build / build-cross (GOARCH=arm64 GOOS=darwin) (push) Waiting to run
Build / build-cross (GOARCH=arm64 GOOS=linux) (push) Waiting to run
Tests / test (push) Waiting to run
* chore: configure some actions to be skipped for forks * chore: build docs only when it changes
51 lines
1.4 KiB
YAML
51 lines
1.4 KiB
YAML
name: Deploy docs
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
# Main branch for development docs
|
|
- main
|
|
|
|
# Doc maintenance branches
|
|
- doc/[0-9]+.[0-9]+.[0-9]+
|
|
tags:
|
|
# Stable release tags
|
|
- v[0-9]+.[0-9]+.[0-9]+
|
|
paths:
|
|
- 'docs/**'
|
|
- 'mkdocs.yml'
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
deploy:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
- name: Install python
|
|
uses: actions/setup-python@v5
|
|
with:
|
|
python-version: 3.x
|
|
- name: Setup cache
|
|
uses: actions/cache@v4
|
|
with:
|
|
key: ${{ github.ref }}
|
|
path: .cache
|
|
- name: Setup dependencies
|
|
run: pip install -r docs/requirements.txt
|
|
- name: Configure git
|
|
run: |
|
|
git config user.name github-actions
|
|
git config user.email github-actions@github.com
|
|
- name: Deploy development docs
|
|
if: github.ref == 'refs/heads/main'
|
|
run: mike deploy --push development unstable
|
|
- name: Deploy stable docs from doc branches
|
|
if: startsWith(github.ref, 'refs/heads/doc/')
|
|
run: mike deploy --push ${GITHUB_REF_NAME##*/}
|
|
- name: Deploy stable docs from tag
|
|
if: startsWith(github.ref, 'refs/tags/v')
|
|
# This assumes that only newer tags are pushed
|
|
run: mike deploy --push --update-aliases ${GITHUB_REF_NAME#v} stable latest
|