-
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.
Merge pull request #71 from ASFHyP3/develop
Release v0.8.0
- Loading branch information
Showing
11 changed files
with
152 additions
and
26 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 |
---|---|---|
|
@@ -11,6 +11,6 @@ on: | |
- develop | ||
jobs: | ||
call-changelog-check-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/[email protected].0 | ||
uses: ASFHyP3/actions/.github/workflows/[email protected].1 | ||
secrets: | ||
USER_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
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,15 @@ | ||
name: Create Jira issue | ||
|
||
on: | ||
issues: | ||
types: [labeled] | ||
|
||
jobs: | ||
call-create-jira-issue-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/[email protected] | ||
secrets: | ||
JIRA_BASE_URL: ${{ secrets.JIRA_BASE_URL }} | ||
JIRA_USER_EMAIL: ${{ secrets.JIRA_USER_EMAIL }} | ||
JIRA_API_TOKEN: ${{ secrets.JIRA_API_TOKEN }} | ||
JIRA_PROJECT: ${{ secrets.JIRA_PROJECT }} | ||
JIRA_FIELDS: ${{ secrets.JIRA_FIELDS }} |
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 |
---|---|---|
|
@@ -12,4 +12,4 @@ on: | |
|
||
jobs: | ||
call-labeled-pr-check-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/[email protected].0 | ||
uses: ASFHyP3/actions/.github/workflows/[email protected].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 |
---|---|---|
|
@@ -7,7 +7,7 @@ on: | |
|
||
jobs: | ||
call-release-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/[email protected].0 | ||
uses: ASFHyP3/actions/.github/workflows/[email protected].1 | ||
with: | ||
release_prefix: Actions | ||
secrets: | ||
|
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,49 @@ | ||
on: | ||
workflow_call: | ||
secrets: | ||
JIRA_BASE_URL: | ||
required: true | ||
JIRA_USER_EMAIL: | ||
required: true | ||
JIRA_API_TOKEN: | ||
required: true | ||
JIRA_PROJECT: | ||
required: true | ||
JIRA_FIELDS: | ||
required: true | ||
|
||
jobs: | ||
create-jira-issue: | ||
if: ${{ startsWith(github.event.label.name, 'Jira') }} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Get Jira issue type | ||
id: get_jira_issue_type | ||
run: | | ||
type=$(echo '${{ github.event.label.name }}' | cut -d' ' -f2) | ||
echo "type=$type" >> "$GITHUB_OUTPUT" | ||
- name: Login to Jira | ||
uses: atlassian/gajira-login@v3 | ||
env: | ||
JIRA_BASE_URL: ${{ secrets.JIRA_BASE_URL }} | ||
JIRA_USER_EMAIL: ${{ secrets.JIRA_USER_EMAIL }} | ||
JIRA_API_TOKEN: ${{ secrets.JIRA_API_TOKEN }} | ||
|
||
- name: Create Jira issue | ||
id: create_jira_issue | ||
uses: atlassian/gajira-create@v3 | ||
with: | ||
project: ${{ secrets.JIRA_PROJECT }} | ||
issuetype: ${{ steps.get_jira_issue_type.outputs.type }} | ||
summary: ${{ github.event.issue.title }} | ||
description: ${{ github.event.issue.html_url }} | ||
fields: '${{ secrets.JIRA_FIELDS }}' | ||
|
||
- name: Add Jira issue key to GitHub issue body | ||
uses: actions-cool/issues-helper@v3 | ||
with: | ||
actions: update-issue | ||
body: "**Jira:** ${{ secrets.JIRA_BASE_URL }}/browse/${{ steps.create_jira_issue.outputs.issue }}\n\ | ||
<!-- The previous line was added by GitHub Actions. It should remain as the first line in this description. -->\n\n\ | ||
${{ github.event.issue.body }}" |
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 |
---|---|---|
|
@@ -4,4 +4,4 @@ on: push | |
|
||
jobs: | ||
call-secrets-analysis-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/[email protected].0 | ||
uses: ASFHyP3/actions/.github/workflows/[email protected].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 |
---|---|---|
|
@@ -7,6 +7,6 @@ on: | |
|
||
jobs: | ||
call-bump-version-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/[email protected].0 | ||
uses: ASFHyP3/actions/.github/workflows/[email protected].1 | ||
secrets: | ||
USER_TOKEN: ${{ secrets.TOOLS_BOT_PAK }} |
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 |
---|---|---|
|
@@ -25,7 +25,7 @@ on: | |
|
||
jobs: | ||
call-bump-version-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/reusable-bump-version.yml@v0.7.0 | ||
uses: ASFHyP3/actions/.github/workflows/reusable-bump-version.yml@v0.8.0 | ||
with: | ||
user: tools-bot # Optional; default shown | ||
email: [email protected] # Optional; default shown | ||
|
@@ -57,13 +57,56 @@ on: | |
jobs: | ||
call-changelog-check-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/reusable-changelog-check.yml@v0.7.0 | ||
uses: ASFHyP3/actions/.github/workflows/reusable-changelog-check.yml@v0.8.0 | ||
secrets: | ||
USER_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
``` | ||
|
||
to ensure the changelog has been updated for any PR to `develop` or `main`. | ||
|
||
### [`reusable-create-jira-issue.yml`](./.github/workflows/reusable-create-jira-issue.yml) | ||
|
||
Creates a Jira issue that corresponds to the labeled GitHub issue. Use like: | ||
|
||
```yaml | ||
name: Create Jira issue | ||
on: | ||
issues: | ||
types: [labeled] | ||
jobs: | ||
call-create-jira-issue-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/[email protected] | ||
secrets: | ||
JIRA_BASE_URL: ${{ secrets.JIRA_BASE_URL }} | ||
JIRA_USER_EMAIL: ${{ secrets.JIRA_USER_EMAIL }} | ||
JIRA_API_TOKEN: ${{ secrets.JIRA_API_TOKEN }} | ||
JIRA_PROJECT: ${{ secrets.JIRA_PROJECT }} | ||
JIRA_FIELDS: ${{ secrets.JIRA_FIELDS }} | ||
``` | ||
|
||
The `JIRA_FIELDS` secret stores additional fields in JSON format. For example, to assign the issue to a particular | ||
sprint, supply the following value: | ||
|
||
```json | ||
{"customfield_XXXXX": 42} | ||
``` | ||
|
||
where `customfield_XXXXX` is the custom field name of the sprint field and `42` is the ID of the particular sprint. | ||
|
||
It would seem that the custom field name of the sprint field is not the same across all Jira deployments and projects. | ||
Therefore, to determine both the custom field name and the sprint ID, do the following: | ||
|
||
1. Choose any issue that belongs to the particular sprint and run the `curl` command for the Jira API's | ||
[Get issue](https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issues/#api-rest-api-3-issue-issueidorkey-get) | ||
endpoint, supplying the issue key. | ||
2. Search the JSON response for the name of the sprint. You should find something like the following | ||
(there will be other fields such as `boardId` present in the object, but they are not shown below): | ||
```json | ||
"customfield_XXXXX":[{"id":42,"name":"MySprint"}] | ||
``` | ||
|
||
### [`reusable-docker-ecr.yml`](./.github/workflows/reusable-docker-ecr.yml) | ||
|
||
Builds a Docker image from the `Dockerfile` in the repository root and pushes it to the | ||
|
@@ -87,13 +130,13 @@ on: | |
jobs: | ||
call-version-info-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/reusable-version-info.yml@v0.7.0 | ||
uses: ASFHyP3/actions/.github/workflows/reusable-version-info.yml@v0.8.0 | ||
with: | ||
conda_env_name: hyp3-plugin | ||
call-docker-ecr-workflow: | ||
needs: call-version-info-workflow | ||
uses: ASFHyP3/actions/.github/workflows/reusable-docker-ecr.yml@v0.7.0 | ||
uses: ASFHyP3/actions/.github/workflows/reusable-docker-ecr.yml@v0.8.0 | ||
with: | ||
version_tag: ${{ needs.call-version-info-workflow.outputs.version_tag }} | ||
ecr_registry: 845172464411.dkr.ecr.us-west-2.amazonaws.com | ||
|
@@ -128,20 +171,20 @@ on: | |
jobs: | ||
call-version-info-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/reusable-version-info.yml@v0.7.0 | ||
uses: ASFHyP3/actions/.github/workflows/reusable-version-info.yml@v0.8.0 | ||
with: | ||
conda_env_name: hyp3-plugin | ||
call-docker-ghcr-workflow: | ||
needs: call-version-info-workflow | ||
uses: ASFHyP3/actions/.github/workflows/reusable-docker-ghcr.yml@v0.7.0 | ||
uses: ASFHyP3/actions/.github/workflows/reusable-docker-ghcr.yml@v0.8.0 | ||
with: | ||
version_tag: ${{ needs.call-version-info-workflow.outputs.version_tag }} | ||
user: ${{ github.actor }} | ||
release_branch: main # Optional; default shown | ||
develop_branch: develop # Optional; default shown | ||
user: tools-bot # Optional; default shown | ||
secrets: | ||
USER_TOKEN: ${{ secrets.TOOLS_BOT_PAK }} | ||
USER_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
``` | ||
|
||
### [`reusable-flake8.yml`](./.github/workflows/reusable-flake8.yml) | ||
|
@@ -155,7 +198,7 @@ on: push | |
jobs: | ||
call-flake8-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/reusable-flake8.yml@v0.7.0 | ||
uses: ASFHyP3/actions/.github/workflows/reusable-flake8.yml@v0.8.0 | ||
with: | ||
local_package_names: hyp3_plugin # Required; comma-seperated list of names that should be considered local to your application | ||
excludes: hyp3_plugin/ugly.py # Optional; comma-separated list of glob patterns to exclude from checks | ||
|
@@ -183,7 +226,7 @@ on: | |
jobs: | ||
call-git-object-name-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/reusable-git-object-name.yml@v0.7.0 | ||
uses: ASFHyP3/actions/.github/workflows/reusable-git-object-name.yml@v0.8.0 | ||
echo-git-object-name-outputs: | ||
needs: call-git-object-name-workflow | ||
|
@@ -213,7 +256,7 @@ on: | |
jobs: | ||
call-labeled-pr-check-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/reusable-labeled-pr-check.yml@v0.7.0 | ||
uses: ASFHyP3/actions/.github/workflows/reusable-labeled-pr-check.yml@v0.8.0 | ||
``` | ||
to ensure a release label is included on any PR to `main`. | ||
|
||
|
@@ -237,11 +280,11 @@ on: | |
jobs: | ||
call-pytest-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/reusable-pytest.yml@v0.7.0 | ||
uses: ASFHyP3/actions/.github/workflows/reusable-pytest.yml@v0.8.0 | ||
with: | ||
local_package_name: hyp3_plugin # Required; package to produce a coverage report for | ||
# Optional; default shown | ||
python_versions: >- | ||
fail_fast: false # Optional; default shown | ||
python_versions: >- # Optional; default shown | ||
["3.8", "3.9", "3.10"] | ||
``` | ||
|
||
|
@@ -266,7 +309,7 @@ on: | |
jobs: | ||
call-release-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/reusable-release.yml@v0.7.0 | ||
uses: ASFHyP3/actions/.github/workflows/reusable-release.yml@v0.8.0 | ||
with: | ||
release_prefix: HyP3-CI | ||
release_branch: main # Optional; default shown | ||
|
@@ -277,13 +320,15 @@ jobs: | |
``` | ||
to create a release for every newly pushed version tag. | ||
|
||
### [`reusable-relese-checklist-comment.yml`](.github/workflows/reusable-release-checklist-comment.yml) | ||
### [`reusable-release-checklist-comment.yml`](.github/workflows/reusable-release-checklist-comment.yml) | ||
|
||
Add a comment to PRs when they are opened with a release checklist for developers and reviewers. | ||
|
||
Use like: | ||
|
||
```yaml | ||
name: Create Release Comment | ||
on: | ||
pull_request: | ||
types: | ||
|
@@ -292,8 +337,10 @@ on: | |
- main | ||
jobs: | ||
call-release-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/[email protected] | ||
call-release-checklist-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/[email protected] | ||
permissions: | ||
pull-requests: write | ||
with: | ||
# optional; example shown | ||
additional_developer_items: '- [ ] If the step function code has changed, have you drained the job queue before merging?' | ||
|
@@ -320,7 +367,7 @@ on: push | |
jobs: | ||
call-secrets-analysis-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/reusable-secrets-analysis.yml@v0.7.0 | ||
uses: ASFHyP3/actions/.github/workflows/reusable-secrets-analysis.yml@v0.8.0 | ||
``` | ||
to scan every push for secrets. | ||
|
||
|
@@ -346,7 +393,7 @@ on: | |
jobs: | ||
call-version-info-workflow: | ||
uses: ASFHyP3/actions/.github/workflows/reusable-version-info.yml@v0.7.0 | ||
uses: ASFHyP3/actions/.github/workflows/reusable-version-info.yml@v0.8.0 | ||
with: | ||
python_version: '3.9' # Optional; default shown | ||
|