-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(ci): Refactored deployment; added versioning; passes app version…
… to Sentry initialization
- Loading branch information
Showing
15 changed files
with
6,375 additions
and
64 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
name: Release Build | ||
|
||
on: | ||
push: | ||
branches: [ master, development ] | ||
pull_request: | ||
branches: [ master, development ] | ||
workflow_dispatch: | ||
inputs: | ||
force: | ||
type: boolean | ||
default: false | ||
|
||
jobs: | ||
test-image: | ||
uses: hms-dbmi/actions/.github/workflows/test-image-build.yml@main | ||
secrets: | ||
DOCKER_HUB_USERNAME: ${{ secrets.BLHMSDBMI_DOCKERHUB_USERNAME }} | ||
DOCKER_HUB_PASSWORD: ${{ secrets.BLHMSDBMI_DOCKERHUB_PASSWORD }} | ||
with: | ||
repository: ${{ github.repository }} | ||
commit: ${{ github.sha }} | ||
|
||
scan-image: | ||
uses: hms-dbmi/actions/.github/workflows/scan.yml@main | ||
secrets: | ||
DOCKER_HUB_USERNAME: ${{ secrets.BLHMSDBMI_DOCKERHUB_USERNAME }} | ||
DOCKER_HUB_PASSWORD: ${{ secrets.BLHMSDBMI_DOCKERHUB_PASSWORD }} | ||
with: | ||
repository: ${{ github.repository }} | ||
commit: ${{ github.sha }} | ||
|
||
metadata: | ||
runs-on: "ubuntu-latest" | ||
outputs: | ||
branch: ${{ steps.set_branch.outputs.branch }} | ||
force: ${{ steps.force.outputs.force }} | ||
steps: | ||
- name: Set the current branch name | ||
shell: bash | ||
run: echo "branch=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}" >> $GITHUB_OUTPUT | ||
id: set_branch | ||
- name: Manage force input | ||
id: force | ||
env: | ||
FORCE_INPUT: ${{ inputs.force }} | ||
run: echo "force=${FORCE_INPUT:=false}" >> $GITHUB_OUTPUT | ||
|
||
deploy: | ||
uses: hms-dbmi/actions/.github/workflows/dbmisvc-app-deploy.yml@main | ||
needs: | ||
- "test-image" | ||
- "metadata" | ||
secrets: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
filename: "${{ github.event.repository.name }}-${{ needs.metadata.outputs.branch }}.zip" | ||
app: ${{ github.event.repository.name }} | ||
role: ${{ vars[ format('BLHMSDBMI_PPM_DEPLOYMENT_{0}_ROLE_ARN', needs.metadata.outputs.branch) ] }} | ||
bucket: ${{ vars[ format('BLHMSDBMI_PPM_DEPLOYMENT_{0}_BUCKET', needs.metadata.outputs.branch) ] }} | ||
force: ${{ fromJson(needs.metadata.outputs.force) }} |
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
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
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,25 @@ | ||
{ | ||
"branches": [ | ||
"master", | ||
"main", | ||
"+([0-9])?(.{+([0-9]),x}).x", | ||
{"name": "development", "channel": "pre/rc", "prerelease": "rc"}, | ||
{"name": "beta", "prerelease": true}, | ||
{"name": "alpha", "prerelease": true} | ||
], | ||
"plugins": [ | ||
"@semantic-release/commit-analyzer", | ||
"@semantic-release/release-notes-generator", | ||
["@semantic-release/changelog", { | ||
"changelogFile": "CHANGELOG.md" | ||
}], | ||
["@semantic-release/exec", { | ||
"prepareCmd": "sed -ie \"s/^version.*/version = \\x22${nextRelease.version}\\x22/g\" pyproject.toml" | ||
}], | ||
["@semantic-release/git", { | ||
"assets": ["pyproject.toml", "CHANGELOG.md"] | ||
}], | ||
"@semantic-release/github" | ||
], | ||
"preset": "angular" | ||
} |
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
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
Oops, something went wrong.