-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Microcluster schema change warning (#922)
- Loading branch information
1 parent
c968e6d
commit 717ee0a
Showing
1 changed file
with
32 additions
and
0 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,32 @@ | ||
name: Detect Microcluster Schema Change | ||
|
||
on: | ||
pull_request: | ||
paths: | ||
- "src/k8s/pkg/k8sd/database/sql/migrations/**" | ||
- "src/k8s/pkg/k8sd/database/schema.go" | ||
|
||
jobs: | ||
create-comment: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Create Microcluster Warning Message | ||
if: github.event_name == 'pull_request' | ||
continue-on-error: true | ||
uses: marocchino/sticky-pull-request-comment@v2 | ||
with: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
header: Microcluster Schema Changes Detected | ||
message: | | ||
### Microcluster Schema Changes Detected | ||
:warning: **Warning:** This pull request contains changes to the microcluster version. | ||
Please ensure that the changes are intentional and have been reviewed by the appropriate team members. | ||
### Adding a migration: | ||
You should not change the Microcluster migration files in interim Kubernetes releases to ensure a smooth | ||
upgrade path from one LTS to the next. In case of upgrade failures, we need to be able to rollback to the last Kubernetes LTS which is only possible if the microcluster migrations have not been changed. | ||
Do not under any circumstances remove any migrations and never change the order of migrations in the microcluster schema files. |