Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(graphql): move schema to Github artifact #95

Merged
merged 3 commits into from
Sep 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 35 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ concurrency:
permissions:
packages: write
id-token: write
contents: read
contents: write

jobs:
test:
Expand Down Expand Up @@ -68,6 +68,16 @@ jobs:
- name: Run tests
run: cargo test

- name: Generate GraphQL schema
run: ./target/debug/generate-schema

- name: Upload GraphQL schema
uses: actions/upload-artifact@v3
with:
name: graphql-schema
path: offchain/schema.graphql
if-no-files-found: error

build_docker:
runs-on: ubuntu-22.04
needs:
Expand Down Expand Up @@ -116,3 +126,27 @@ jobs:
push: true
project: ${{ vars.DEPOT_PROJECT }}
workdir: build

release:
needs: [test, build_docker]
runs-on: ubuntu-22.04
if: startsWith(github.ref, 'refs/tags/v')
steps:
- uses: actions/checkout@v3
with:
submodules: recursive

- name: Trim CHANGELOG.md
run: sed -e '0,/^##[^#]/d' -e '/^##[^#]/,$d' -i CHANGELOG.md

- name: Download GraphQL schema
uses: actions/download-artifact@v3
with:
name: graphql-schema

- name: Publish Github release
uses: softprops/action-gh-release@v1
with:
prerelease: true
body_path: CHANGELOG.md
files: schema.graphql
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Changed

- Standardized log libraries and configuration
- Moved GraphQL schema generation to the CI. Now it is distributed as a Github artifact

### Removed

- Removed configurable inspect-server path prefix
- Remove on-chain code from the node repository
- Removed on-chain code from the node repository
- Removed `advance-runner`, `dispatcher`, `graphql-server`, `host-runner`, `inspect-server`, `indexer`, and `state-server` docker images

## [1.0.2] 2023-09-12
Expand Down
File renamed without changes.
Loading