Skip to content

Commit

Permalink
Add backstage file
Browse files Browse the repository at this point in the history
  • Loading branch information
montabot committed Mar 1, 2024
1 parent 46c8eec commit 43f0645
Showing 1 changed file with 44 additions and 0 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/backstage_techdocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Publish TechDocs Site

on:
push:
branches: [main]
paths:
- "docs/**"
- "mkdocs.yml"
workflow_dispatch:


jobs:
publish-techdocs-site:
runs-on: ubuntu-latest

env:
TECHDOCS_S3_BUCKET_NAME: 'monta-tech-docs'
AWS_ACCESS_KEY_ID: ${{ secrets.TECHDOCS_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.TECHDOCS_AWS_SECRET_ACCESS_KEY }}
AWS_REGION: 'eu-west-1'
ENTITY_NAMESPACE: 'default'
ENTITY_KIND: 'Component'
ENTITY_NAME: 'backstage'

steps:
- name: Checkout code
uses: actions/checkout@v3

- uses: actions/setup-node@v3
- uses: actions/setup-python@v4
with:
python-version: '3.9'

- name: Install techdocs-cli
run: sudo npm install -g @techdocs/cli

- name: Install mkdocs and mkdocs plugins
run: python -m pip install mkdocs-techdocs-core==1.*

- name: Generate docs site
run: techdocs-cli generate --no-docker --verbose

- name: Publish docs site
run: techdocs-cli publish --publisher-type awsS3 --storage-name $TECHDOCS_S3_BUCKET_NAME --entity $ENTITY_NAMESPACE/$ENTITY_KIND/$ENTITY_NAME

0 comments on commit 43f0645

Please sign in to comment.