-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Sayali Gaikawad <[email protected]>
- Loading branch information
Showing
5 changed files
with
64 additions
and
3 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,33 @@ | ||
name: Draft a release | ||
|
||
on: | ||
push: | ||
tags: | ||
- "*" | ||
|
||
jobs: | ||
draft-a-release: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
issues: write | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
- id: get_data | ||
run: | | ||
echo "approvers=$(cat .github/CODEOWNERS | grep @ | tr -d '* ' | sed 's/@/,/g' | sed 's/,//1')" >> $GITHUB_OUTPUT | ||
echo "version=$(cat package.json | jq .version | tr -d "\"")" >> $GITHUB_OUTPUT | ||
- uses: trstringer/manual-approval@v1 | ||
with: | ||
secret: ${{ github.TOKEN }} | ||
approvers: ${{ steps.get_data.outputs.approvers }} | ||
minimum-approvals: 2 | ||
issue-title: 'Release opensearch-cluster-cdk : ${{ steps.get_data.outputs.version }}' | ||
issue-body: "Please approve or deny the release of opensearch-cluster-cdk. **VERSION**: ${{ steps.get_data.outputs.version }} **TAG**: ${{ github.ref_name }} **COMMIT**: ${{ github.sha }}" | ||
exclude-workflow-initiator-as-approver: true | ||
- name: Release | ||
uses: softprops/action-gh-release@v1 | ||
with: | ||
draft: true | ||
generate_release_notes: true |
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,17 @@ | ||
- [Overview](#overview) | ||
- [Releasing](#releasing) | ||
|
||
## Overview | ||
|
||
This document explains the release strategy for artifacts in this organization. | ||
|
||
## Releasing | ||
|
||
The release process is standard across repositories in this org and is run by a release manager volunteering from amongst [maintainers](MAINTAINERS.md). | ||
|
||
1. Create a tag, e.g. v2.1.0, and push it to the GitHub repo. | ||
2. The [release-drafter.yml](.github/workflows/release-drafter.yml) will be automatically kicked off. | ||
3. The above release drafter workflow creates an issue asking for confirmation about the release from the mainatiners. Once approved, it creates a draft release in the repository. | ||
4. This draft release triggers the [jenkins release workflow](https://build.ci.opensearch.org/job/opensearch-cluster-cdk-release/) as a result of which opensearch-cluster-cdk is released on [npmjs](https://www.npmjs.com/package/@opensearch-project/opensearch-cluster-cdk). | ||
5. Once the above release workflow is successful, the drafted release on GitHub is published automatically. | ||
6. Increment "version" in package.json to the next patch release, e.g. v2.1.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,11 @@ | ||
lib = library(identifier: '[email protected]', retriever: modernSCM([ | ||
$class: 'GitSCMSource', | ||
remote: 'https://github.com/opensearch-project/opensearch-build-libraries.git', | ||
])) | ||
|
||
standardReleasePipelineWithGenericTrigger( | ||
tokenIdCredential: 'jenkins-opensearch-cluster-cdk-generic-webhook-token', | ||
causeString: 'A tag was cut on opensearch-project/opensearch-cluster-cdk repository causing this workflow to run', | ||
publishRelease: true) { | ||
publishToNpm(publicationType: 'github') | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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 |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"name": "opensearch-cluster-cdk", | ||
"version": "0.1.0", | ||
"version": "1.0.0", | ||
"bin": { | ||
"cdk_v2": "bin/app.js" | ||
}, | ||
|