aboutsummaryrefslogtreecommitdiffstats
path: root/.github/workflows/docs_release.yaml
blob: 0c7ae9da9f8256179826a3deb5eb72f49e8ded4c (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: Release documentation

on:
  push:
    branches:
      - 'main'
      - 'stable-**'
    paths: 
      - 'ydb/docs/**'
  workflow_dispatch:

jobs:
  release:
    concurrency:
      group: release-documentation-${{ github.ref }}
      cancel-in-progress: true
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v3
      - name: Extract version
        shell: bash
        run: echo "version=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}" | sed -e 's|stable-|v|g' -e 's|-|.|g' >> $GITHUB_OUTPUT
        id: extract_version
      - name: Release
        uses: diplodoc-platform/docs-release-action@v1
        with:
          revision: "${{ github.sha }}"
          version: "${{ steps.extract_version.outputs.version }}"
          project-name: ${{ secrets.DOCS_PROJECT_NAME }}
          src-root: ${{ vars.SRC_ROOT }}
          storage-bucket: ${{ secrets.DOCS_AWS_BUCKET }}
          storage-endpoint: ${{ vars.DOCS_AWS_ENDPOINT }}
          storage-access-key-id: ${{ secrets.DOCS_AWS_KEY_ID }}
          storage-secret-access-key: ${{ secrets.DOCS_AWS_SECRET_ACCESS_KEY }}
          storage-region: ${{ vars.DOCS_AWS_REGION }}
          shared-storage-bucket: true