-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Feature/publish scylla and migration images (#4)
* chore: workflows for release to ghcr * chore: refactor npm build and rust build * fix: revert version * fix: update the file names --------- Co-authored-by: Amninder Kaur <amninder.kaur@kindredgroup.com>
- Loading branch information
Showing
13 changed files
with
2,202 additions
and
993 deletions.
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
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,37 @@ | ||
name: GHCR Publish | ||
|
||
# when a new release is created or new tag is pushed to master | ||
# tag should be in the format v1.0.0 | ||
# regex to check the tag format | ||
on: | ||
release: | ||
types: [created] | ||
push: | ||
tags: | ||
- 'v[0-9]+.[0-9]+.[0-9]+' | ||
|
||
jobs: | ||
build: | ||
uses: ./.github/workflows/rust_build.yml | ||
publish: | ||
runs-on: ubuntu-latest | ||
needs: build | ||
if: needs.build.result == 'success' | ||
steps: | ||
- name: Checkout the repo | ||
uses: actions/checkout@v3 | ||
- name: Login to GitHub Container Registry | ||
uses: docker/login-action@v1 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
- run: bin/ubuntu-setup.sh | ||
|
||
- name: Build and publish scylla image with ver and latest tag | ||
run: sh bin/ghcr-publish.sh scylla_pg_monitor | ||
|
||
- name: Build and publish the pg-migration Docker image | ||
run: sh bin/ghcr-publish.sh scylla_pg_migration | ||
|
||
|
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
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,26 @@ | ||
# workflow_call to build the rust app | ||
name: npm_build_and_test | ||
|
||
on: workflow_call | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Setup node | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 18 | ||
check-latest: true | ||
- name: Set up Database | ||
run: | | ||
echo $(pwd) | ||
ls -la | ||
docker-compose up -d | ||
- name: Run Migrations | ||
run: PATH=$PATH:$(pwd) bin/component-test-setup.sh | ||
- run: cd scylla_pg_js && npm install | ||
- name: component test lib | ||
run: make withenv RECIPE=test.component.lib |
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,28 @@ | ||
# workflow_call to build the rust app | ||
name: rust_build_and_test | ||
|
||
on: workflow_call | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: dtolnay/rust-toolchain@1.75.0 | ||
with: | ||
toolchain: stable | ||
- run: bin/ubuntu-setup.sh | ||
- run: rustup component add rustfmt clippy | ||
- name: cargo build | ||
run: | | ||
cargo clean | ||
cargo build --release | ||
- run: bin/pre-commit-checks.sh | ||
- name: Set up Database | ||
run: docker-compose up -d | ||
|
||
- name: Run Migrations | ||
run: PATH=$PATH:$(pwd) bin/component-test-setup.sh | ||
|
||
- name: Component Tests | ||
run: make withenv RECIPE=test.component |
Oops, something went wrong.