fix: gcp service account name max 30char (#24) #11
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
name: docs | |
on: | |
push: | |
branches: | |
- main | |
tags: | |
- v[0-9]+.[0-9]+.[0-9]+ | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
submodules: recursive | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.8" | |
architecture: x64 | |
cache: 'pip' | |
- name: Install mkdocs | |
run: pip install mkdocs-material mike | |
- name: Configure Git user | |
run: | | |
git config --local user.email "github-actions[bot]@users.noreply.github.com" | |
git config --local user.name "github-actions[bot]" | |
- name: Determine Build Information | |
id: buildinfo | |
run: | | |
case $GITHUB_REF in | |
refs/tags/*) VERSION=${GITHUB_REF#refs/tags/};; | |
refs/heads/*) VERSION=$(echo ${GITHUB_REF#refs/heads/} | sed -r 's#/+#-#g');; | |
esac | |
echo "version=${VERSION}" >> $GITHUB_OUTPUT | |
- name: Deploy (main) | |
if: github.ref == 'refs/heads/main' | |
run: | | |
mike deploy -up ${{ steps.buildinfo.outputs.version }} | |
mike list | |
- name: Deploy (release) | |
if: startsWith(github.ref, 'refs/tags/') | |
run: | | |
mike deploy -up ${{ steps.buildinfo.outputs.version }} | |
mike set-default ${{ steps.buildinfo.outputs.version }} | |
mike list |