Skip to content

Commit

Permalink
fix: docs builds in CI
Browse files Browse the repository at this point in the history
Since the move to Turbo (done as part of adding scenes-react) docs builds
have been failing in CI ([example 1] and [example 2]). The config args
aren't being passed through to the website package since we're using turbo
now.

This commit adds the required extra '--' to the CI commands. That wasn't
enough though; because the turbo.json declares a dependency from any
'build' command to any others, running yarn docs:build resulted in
all the other packages' build commands running too, which would fail
because the --config flag would be passed to them and they don't understand
it. I've therefore also removed the dependency in turbo.json - I'm not sure
it was fully needed, but this might be a mistake? If so, we need another
solution.

I'm still not certain this will pass but will iterate until it does...
  • Loading branch information
sd2k committed Jul 11, 2024
1 parent af902ec commit ce50a9d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/deploy-to-dev-portal-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
- name: Build documentation website
env:
GTAG_CONTAINER_ID: ${{ secrets.GTAG_CONTAINER_ID }}
run: yarn docs:build --config docusaurus.config.devportal.js
run: yarn docs:build -- --config docusaurus.config.devportal.js

- id: 'auth'
uses: 'google-github-actions/auth@v1'
Expand All @@ -47,4 +47,4 @@ jobs:
with:
path: './docusaurus/website/build/'
destination: 'staging-developer-portal/scenes'
parent: false
parent: false
4 changes: 2 additions & 2 deletions .github/workflows/deploy-to-dev-portal-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
- name: Build documentation website
env:
GTAG_CONTAINER_ID: ${{ secrets.GTAG_CONTAINER_ID }}
run: yarn docs:build --config docusaurus.config.devportal.prod.js
run: yarn docs:build -- --config docusaurus.config.devportal.prod.js

- id: 'auth'
uses: 'google-github-actions/auth@v1'
Expand All @@ -47,4 +47,4 @@ jobs:
with:
path: './docusaurus/website/build/'
destination: 'grafana-developer-portal/scenes'
parent: false
parent: false
2 changes: 1 addition & 1 deletion turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"$schema": "https://turborepo.org/schema.json",
"pipeline": {
"build": {
"dependsOn": ["^build"]
"dependsOn": []
},
"lint": {
"outputs": []
Expand Down

0 comments on commit ce50a9d

Please sign in to comment.