Skip to content

Commit

Permalink
Update docs-elastic-staging-publish.yml
Browse files Browse the repository at this point in the history
Done as part of our serverless move (https://github.com/elastic/docs-projects/issues/178)

- Copies the public docs builder for a public repo (https://github.com/elastic/workflows/tree/main?tab=readme-ov-file#public-repos)
- Updates paths to point at /docs/serverless
  • Loading branch information
glitteringkatie authored May 23, 2024
1 parent effa48a commit d9dec22
Showing 1 changed file with 19 additions and 15 deletions.
34 changes: 19 additions & 15 deletions .github/workflows/docs-elastic-staging-publish.yml
Original file line number Diff line number Diff line change
@@ -1,25 +1,29 @@
name: Staging Docs
name: Elastic docs

on:
pull_request_target:
# The paths property can be omitted entirely if the repo is mainly used for docs. Leaving it in can result in builds that
# have branch protection checks in place lose the ability to merge because the workflow is not starting. If this property
# is included, please ensure that branch protection checks are disabled for the repo.
paths:
- '**.mdx'
- '**.docnav.json'
- '**.docapi.json'
- '**.devdocs.json'
- '**.jpg'
- '**.jpeg'
- '**.png'
- '**.svg'
- '**.gif'
types: [opened, closed, synchronize]
# Preface with your docs dir if you need further specificity (optional)
- 'docs/serverless/**.mdx'
- 'docs/serverless/**.docnav.json'
- 'docs/serverless/**.docapi.json'
- 'docs/serverless/**.devdocs.json'
- 'docs/serverless/**.jpg'
- 'docs/serverless/**.jpeg'
- 'docs/serverless/**.svg'
- 'docs/serverless/**.png'
- 'docs/serverless/**.gif'
types: [closed, opened, synchronize, labeled]

jobs:
publish:
name: Vercel Build Check
if: contains(github.event.pull_request.labels.*.name, 'ci:doc-build')
uses: elastic/workflows/.github/workflows/docs-elastic-co-publish.yml@main
secrets:
VERCEL_GITHUB_TOKEN: ${{ secrets.VERCEL_GITHUB_TOKEN }}
VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }}
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_GITHUB_TOKEN: ${{ secrets.VERCEL_GITHUB_TOKEN_PUBLIC }}
VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN_PUBLIC }}
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID_PUBLIC }}
VERCEL_PROJECT_ID_DOCS_CO: ${{ secrets.VERCEL_PROJECT_ID_DOCS_CO }}

0 comments on commit d9dec22

Please sign in to comment.