Add format for mdx files (#1707) #12
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
# Copyright (c) 2022 Sharezone UG (haftungsbeschränkt) | |
# Licensed under the EUPL-1.2-or-later. | |
# | |
# You may obtain a copy of the Licence at: | |
# https://joinup.ec.europa.eu/software/page/eupl | |
# | |
# SPDX-License-Identifier: EUPL-1.2 | |
name: docs-cd | |
concurrency: | |
# Avoids running multiple deployments at the same time which would cause | |
# conflicts. | |
group: docs-release | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
# We only build and deploy a new version, when a user relevant files | |
# changed. | |
- "docs/**" | |
# We trigger also this workflow, if this workflow is changed, so that new | |
# changes will be applied. | |
- ".github/workflows/docs_cd.yml" | |
# The following paths are excluded from the above paths. It's important to | |
# list the paths at the end of the file, so that the exclude paths are | |
# applied. | |
# | |
# See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#example-including-and-excluding-paths. | |
- "!website/README.md" | |
- "!**/*.gitignore" | |
# Set permissions to none. | |
# | |
# Using the broad default permissions is considered a bad security practice | |
# and would cause alerts from our scanning tools. | |
permissions: {} | |
jobs: | |
deploy: | |
runs-on: ubuntu-22.04 | |
name: docs-deploy-${{ matrix.environment.flavor }} | |
permissions: | |
checks: write # for FirebaseExtended/action-hosting-deploy | |
strategy: | |
matrix: | |
environment: | |
- flavor: dev | |
projectId: sharezone-debug | |
serviceAccountSecret: FIREBASE_SERVICE_ACCOUNT_SHAREZONE_DEBUG | |
- flavor: prod | |
projectId: sharezone-c2bd8 | |
serviceAccountSecret: FIREBASE_HOSTING_PROD_KEY | |
steps: | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 | |
- name: Install dependencies | |
run: npm install -C docs | |
# Our production docs should be indexed by search engines. | |
- name: Remove robots.txt | |
if: ${{ matrix.environment.flavor == 'prod' }} | |
run: rm -f docs/public/robots.txt | |
- uses: FirebaseExtended/action-hosting-deploy@v0 | |
with: | |
repoToken: "${{ secrets.GITHUB_TOKEN }}" | |
firebaseServiceAccount: "${{ secrets[matrix.environment.serviceAccountSecret] }}" | |
channelId: live | |
entryPoint: "./docs" | |
target: docs | |
projectId: ${{ matrix.environment.projectId }} | |
env: | |
# Required to deploy Next.js applications to Firebase Hosting | |
FIREBASE_CLI_EXPERIMENTS: webframeworks |