-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🔧 Create Scheduled Issue workflows (#5191)
* 🔧 Create Ingestion Issue workflow * Update .github/workflows/ingestion-issue-schedule.yml Co-authored-by: Jacob Woffenden <[email protected]> * Update .github/workflows/ingestion-issue-schedule.yml Co-authored-by: Jacob Woffenden <[email protected]> * Update .github/workflows/ingestion-issue-schedule.yml Co-authored-by: Jacob Woffenden <[email protected]> * Update .github/workflows/ingestion-issue-schedule.yml Co-authored-by: Jacob Woffenden <[email protected]> * Update .github/workflows/ingestion-issue-schedule.yml Co-authored-by: Jacob Woffenden <[email protected]> * 🚧 WIP * 🔧 Update maintenance workflows * 📝 typo * 📝 Typo * 🔧 Add JupyterLab Schedule --------- Co-authored-by: Jacob Woffenden <[email protected]>
- Loading branch information
Showing
5 changed files
with
258 additions
and
1 deletion.
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,63 @@ | ||
--- | ||
name: 📥 Maintenance - Create Actions Runner Issue | ||
|
||
on: | ||
schedule: | ||
- cron: "0 8 1,15 * *" # UTC time: “At 08:00 on day-of-month 1 and 15.” | ||
|
||
permissions: {} | ||
|
||
jobs: | ||
create-maintenance-issue: | ||
name: Create Maintenance Issue | ||
runs-on: ubuntu-latest | ||
permissions: | ||
issues: write | ||
steps: | ||
- name: Create Maintenance Issue | ||
id: create_maintenance_issue | ||
run: | | ||
if [[ "${CLOSE_PREVIOUS}" == true ]]; then | ||
previous_issue_number=$(gh issue list \ | ||
--label "$LABELS" \ | ||
--json number \ | ||
--jq '.[0].number') | ||
if [[ -n $previous_issue_number ]]; then | ||
gh issue close "$previous_issue_number" | ||
gh issue unpin "$previous_issue_number" | ||
fi | ||
fi | ||
new_issue_url=$(gh issue create \ | ||
--title "$TITLE" \ | ||
--assignee "$ASSIGNEES" \ | ||
--label "$LABELS" \ | ||
--body "$BODY") | ||
if [[ $PINNED == true ]]; then | ||
gh issue pin "$new_issue_url" | ||
fi | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GH_REPO: ${{ github.repository }} | ||
TITLE: 📥 Maintenance - Actions Runner | ||
ASSIGNEES: | ||
LABELS: maintenance | ||
BODY: | | ||
> [!NOTE] | ||
> This issue is created by a scheduled workflow. | ||
### User Story | ||
As an… engineer on the Analytical Platform | ||
I need/want/expect to… keep Actions Runner image up to date | ||
So that… security / best practice etc | ||
### Definition of Done | ||
- [ ] Merge any open dependabot Pull Requests in the Actions Runnner [repository](https://github.com/ministryofjustice/analytical-platform-actions-runner/pulls). | ||
- [ ] Create new [release](https://github.com/ministryofjustice/analytical-platform-actions-runner). | ||
- [ ] Create a new release in [development](https://controlpanel.services.dev.analytical-platform.service.justice.gov.uk/releases/). | ||
- [ ] Deployment development. | ||
- [ ] Create a new release in [production](https://controlpanel.services.analytical-platform.service.justice.gov.uk/releases/). | ||
- [ ] Deploy production. | ||
PINNED: false | ||
CLOSE_PREVIOUS: false |
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,66 @@ | ||
--- | ||
name: 📥 Maintenance - Create Ingestion Issue | ||
|
||
on: | ||
schedule: | ||
- cron: "0 8 1,15 * *" # UTC time: “At 08:00 on day-of-month 1 and 15.” | ||
|
||
permissions: {} | ||
|
||
jobs: | ||
create-maintenance-issue: | ||
name: Create Maintenance Issue | ||
runs-on: ubuntu-latest | ||
permissions: | ||
issues: write | ||
steps: | ||
- name: Create Maintenance Issue | ||
id: create_maintenance_issue | ||
run: | | ||
if [[ "${CLOSE_PREVIOUS}" == true ]]; then | ||
previous_issue_number=$(gh issue list \ | ||
--label "$LABELS" \ | ||
--json number \ | ||
--jq '.[0].number') | ||
if [[ -n $previous_issue_number ]]; then | ||
gh issue close "$previous_issue_number" | ||
gh issue unpin "$previous_issue_number" | ||
fi | ||
fi | ||
new_issue_url=$(gh issue create \ | ||
--title "$TITLE" \ | ||
--assignee "$ASSIGNEES" \ | ||
--label "$LABELS" \ | ||
--body "$BODY") | ||
if [[ $PINNED == true ]]; then | ||
gh issue pin "$new_issue_url" | ||
fi | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GH_REPO: ${{ github.repository }} | ||
TITLE: 📥 Maintenance - Ingestion | ||
ASSIGNEES: | ||
LABELS: maintenance | ||
BODY: | | ||
> [!NOTE] | ||
> This issue is created by a scheduled workflow. | ||
### User Story | ||
As an… engineer on the Analytical Platform | ||
I need/want/expect to… keep the ingestion service up to date | ||
So that… security / best practice etc | ||
### Definition of Done | ||
- [ ] Merge any open dependabot Pull Requests in the Ingestion repositories (noted below). | ||
- [ ] Create new release of [ingestion-transfer](https://github.com/ministryofjustice/analytical-platform-ingestion-transfer/releases). | ||
- [ ] Create new release of [ingestion-scan ](https://github.com/ministryofjustice/analytical-platform-ingestion-scan/releases). | ||
- [ ] Create new release of [ingestion-notify](https://github.com/ministryofjustice/analytical-platform-ingestion-notify/releases/tag/0.0.14). | ||
- [ ] Update the images used in the Modernisation Platform environments repository (in the manner done [here](https://github.com/ministryofjustice/modernisation-platform-environments/commit/af4d5003385721502127e5a8c22d0a21eee492fa)). | ||
- [ ] Deploy development. | ||
- [ ] Deploy production. | ||
📝 Documentation [here](https://docs.analytical-platform.service.justice.gov.uk/documentation/runbooks/001-ingestion-maintenance.html#ingestion-maintenance) | ||
PINNED: false | ||
CLOSE_PREVIOUS: false |
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,64 @@ | ||
--- | ||
name: 📥 Maintenance - Create JupyterLab Issue | ||
|
||
on: | ||
schedule: | ||
- cron: "0 8 1,15 * *" # UTC time: “At 08:00 on day-of-month 1 and 15.” | ||
|
||
permissions: {} | ||
|
||
jobs: | ||
create-maintenance-issue: | ||
name: Create Maintenance Issue | ||
runs-on: ubuntu-latest | ||
permissions: | ||
issues: write | ||
steps: | ||
- name: Create Maintenance Issue | ||
id: create_maintenance_issue | ||
run: | | ||
if [[ "${CLOSE_PREVIOUS}" == true ]]; then | ||
previous_issue_number=$(gh issue list \ | ||
--label "$LABELS" \ | ||
--json number \ | ||
--jq '.[0].number') | ||
if [[ -n $previous_issue_number ]]; then | ||
gh issue close "$previous_issue_number" | ||
gh issue unpin "$previous_issue_number" | ||
fi | ||
fi | ||
new_issue_url=$(gh issue create \ | ||
--title "$TITLE" \ | ||
--assignee "$ASSIGNEES" \ | ||
--label "$LABELS" \ | ||
--body "$BODY") | ||
if [[ $PINNED == true ]]; then | ||
gh issue pin "$new_issue_url" | ||
fi | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GH_REPO: ${{ github.repository }} | ||
TITLE: 📥 Maintenance - Visual Studio Code | ||
ASSIGNEES: | ||
LABELS: maintenance | ||
BODY: | | ||
> [!CAUTION] | ||
> JupyterLab is still in development. Confirm these updates should be made before proceeding. Delete this caution once JupiterLab is in production. | ||
### User Story | ||
As a… engineer on the Analytical Platform | ||
I need/want/expect to… keep JupyterLab up to date | ||
So that… security / best practice etc | ||
### Definition of Done | ||
- [ ] Merge any open dependabot Pull Requests in the JupyterLab [repository](https://github.com/ministryofjustice/analytical-platform-jupyterlab). | ||
- [ ] Create new [release](https://github.com/ministryofjustice/analytical-platform-jupyterlab/releases). | ||
- [ ] Update [guidance](https://user-guidance.analytical-platform.service.justice.gov.uk/tools/visual-studio-code/#visual-studio-code), if required. | ||
- [ ] Create a new release in [development](https://controlpanel.services.dev.analytical-platform.service.justice.gov.uk/releases/). | ||
- [ ] Test deployment in development. | ||
- [ ] Create a new release in [production](https://controlpanel.services.analytical-platform.service.justice.gov.uk/releases/). | ||
- [ ] Test deployment in production. | ||
PINNED: false | ||
CLOSE_PREVIOUS: false |
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,64 @@ | ||
--- | ||
name: 📥 Maintenance - Create Visual Studio Code Issue | ||
|
||
on: | ||
schedule: | ||
- cron: "0 8 1,15 * *" # UTC time: “At 08:00 on day-of-month 1 and 15.” | ||
|
||
permissions: {} | ||
|
||
jobs: | ||
create-maintenance-issue: | ||
name: Create Maintenance Issue | ||
runs-on: ubuntu-latest | ||
permissions: | ||
issues: write | ||
steps: | ||
- name: Create Maintenance Issue | ||
id: create_maintenance_issue | ||
run: | | ||
if [[ "${CLOSE_PREVIOUS}" == true ]]; then | ||
previous_issue_number=$(gh issue list \ | ||
--label "$LABELS" \ | ||
--json number \ | ||
--jq '.[0].number') | ||
if [[ -n $previous_issue_number ]]; then | ||
gh issue close "$previous_issue_number" | ||
gh issue unpin "$previous_issue_number" | ||
fi | ||
fi | ||
new_issue_url=$(gh issue create \ | ||
--title "$TITLE" \ | ||
--assignee "$ASSIGNEES" \ | ||
--label "$LABELS" \ | ||
--body "$BODY") | ||
if [[ $PINNED == true ]]; then | ||
gh issue pin "$new_issue_url" | ||
fi | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GH_REPO: ${{ github.repository }} | ||
TITLE: 📥 Maintenance - Visual Studio Code | ||
ASSIGNEES: | ||
LABELS: maintenance | ||
BODY: | | ||
> [!NOTE] | ||
> This issue is created by a scheduled workflow. | ||
### User Story | ||
As a… engineer on the Analytical Platform | ||
I need/want/expect to… keep Visual Studio Code up to date | ||
So that… security / best practice etc | ||
### Definition of Done | ||
- [ ] Merge any open dependabot Pull Requests in the Visual Studio Code [repository](https://github.com/ministryofjustice/analytical-platform-visual-studio-code). | ||
- [ ] Create new [release](https://github.com/ministryofjustice/analytical-platform-visual-studio-code/releases). | ||
- [ ] Update [guidance](https://user-guidance.analytical-platform.service.justice.gov.uk/tools/visual-studio-code/#visual-studio-code), if required. | ||
- [ ] Create a new release in [development](https://controlpanel.services.dev.analytical-platform.service.justice.gov.uk/releases/). | ||
- [ ] Test deployment in development. | ||
- [ ] Create a new release in [production](https://controlpanel.services.analytical-platform.service.justice.gov.uk/releases/). | ||
- [ ] Test deployment in production. | ||
PINNED: false | ||
CLOSE_PREVIOUS: false |
2 changes: 1 addition & 1 deletion
2
source/documentation/runbooks/001-ingestion-maintenance.html.md.erb
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