📥 Maintenance - Create Ingestion Issue #6
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
--- | |
name: 📥 Maintenance - Create Ingestion Issue | |
on: | |
schedule: | |
- cron: "0 8 1 * *" # UTC time: “At 08:00 on first day-of-month” | |
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). | |
- [ ] In the ingestion-scan repository, confirm that the [dnf packages](https://github.com/ministryofjustice/analytical-platform-ingestion-scan?tab=readme-ov-file#dnf-packages) and [tests](https://github.com/ministryofjustice/analytical-platform-ingestion-scan/blob/main/test/container-structure-test.yml) are up-to-date. | |
- [ ] 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). | |
- [ ] 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 |