-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: deploy to netlify using github actions (#1818)
- deploy previews via github actions in 4 minutes instead of 8 - production build as well
- Loading branch information
Showing
3 changed files
with
93 additions
and
1 deletion.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# .github/workflows/netlify.yml | ||
name: Netlify Deploy Preview | ||
on: | ||
push: | ||
paths-ignore: | ||
- '**.md' | ||
- 'examples' | ||
- '!examples/monaco-graphql-webpack' | ||
|
||
jobs: | ||
build: | ||
name: "Build & Deploy" | ||
runs-on: ubuntu-18.04 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
|
||
- name: Yarn Install | ||
uses: bahmutov/npm-install@v1 | ||
# ( Build to ./dist or other directory... ) | ||
- name: Build | ||
run: yarn build | ||
|
||
- name: Build Bundles | ||
run: yarn build-bundles | ||
|
||
- name: Build Typedoc | ||
run: yarn build-docs | ||
|
||
- name: Deploy Dev to Netlify | ||
uses: nwtgck/actions-netlify@v1.1 | ||
with: | ||
publish-dir: './packages/graphiql/' | ||
production-branch: main | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
deploy-message: "Deploy Preview: ${{ github.event.pull_request.title }}. Use `/dev` for react debugging" | ||
enable-pull-request-comment: true | ||
enable-commit-comment: true | ||
overwrites-pull-request-comment: true | ||
functions-dir: functions | ||
github-deployment-environment: "Deploy Preview" | ||
env: | ||
NETLIFY_AUTH_TOKEN: ${{ secrets.AUTH_TOKEN }} | ||
NETLIFY_SITE_ID: ${{ secrets.SITE_ID }} | ||
timeout-minutes: 1 |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
# .github/workflows/netlify.yml | ||
name: Netlify Production Deploy | ||
on: | ||
push: | ||
branches: | ||
- main | ||
paths-ignore: | ||
- '**.md' | ||
- 'examples' | ||
- '!examples/monaco-graphql-webpack' | ||
|
||
jobs: | ||
deploy: | ||
name: "Build & Deploy Production Demo & API Docs" | ||
runs-on: ubuntu-18.04 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
|
||
- name: Yarn Install | ||
uses: bahmutov/npm-install@v1 | ||
# ( Build to ./dist or other directory... ) | ||
|
||
- name: Build | ||
run: yarn build | ||
|
||
- name: Build Bundles | ||
run: yarn build-bundles | ||
|
||
- name: Build Typedoc | ||
run: yarn build-docs | ||
|
||
- name: Deploy Production Demo & Typedoc to Netlify | ||
uses: nwtgck/actions-netlify@v1.1 | ||
with: | ||
publish-dir: './packages/graphiql/' | ||
production-branch: main | ||
production-deploy: true | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
deploy-message: "GraphiQL 1 Demo" | ||
functions-dir: functions | ||
github-deployment-environment: "GraphiQL 1 Demo" | ||
env: | ||
NETLIFY_AUTH_TOKEN: ${{ secrets.AUTH_TOKEN }} | ||
NETLIFY_SITE_ID: ${{ secrets.SITE_ID }} | ||
timeout-minutes: 1 |
This file contains 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
3e2c9c8
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉 Published on https://graphiql-test.netlify.app as production
🚀 Deployed on https://60614b9505956a862abed788--graphiql-test.netlify.app
3e2c9c8
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉 Published on https://graphiql-test.netlify.app as production
🚀 Deployed on https://60614ba5a5b467b56a08714b--graphiql-test.netlify.app