update techdoc publish workflow #12
Workflow file for this run
This file contains hidden or 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: Publish TechDocs | |
| on: | |
| push: | |
| branches: ["*"] | |
| paths: | |
| - ".github/workflows/techdocs.yaml" | |
| - "docs/**" | |
| - "mkdocs.yml" | |
| jobs: | |
| publish-techdocs: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| - uses: actions/setup-python@v5 | |
| 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 | |
| run: techdocs-cli generate --no-docker --verbose | |
| - name: Publish docs | |
| # The following secrets are required in your CI environment for publishing files to AWS S3. | |
| # e.g. You can use GitHub Organization secrets to set them for all existing and new repositories. | |
| env: | |
| TECHDOCS_S3_BUCKET_NAME: bridge-techdocs-2ef0b00 | |
| AWS_ACCESS_KEY_ID: ${{ secrets.TRUSS_AWS_ACCESS_KEY_ID }} | |
| AWS_SECRET_ACCESS_KEY: ${{ secrets.TRUSS_AWS_SECRET_ACCESS_KEY }} | |
| AWS_REGION: 'us-east-2' | |
| ENTITY_NAMESPACE: 'default' | |
| ENTITY_KIND: 'Component' | |
| ENTITY_NAME: 'DockerBaseImages' | |
| run: | |
| techdocs-cli publish --publisher-type awsS3 --storage-name | |
| $TECHDOCS_S3_BUCKET_NAME --entity | |
| $ENTITY_NAMESPACE/$ENTITY_KIND/$ENTITY_NAME |