Skip to content

Montly update and upgrade #3

Montly update and upgrade

Montly update and upgrade #3

Workflow file for this run

name: Montly update and upgrade
on:
schedule:
- cron: 0 0 1 * *
jobs:
create_issue:
name: Create monthly update and upgrade issue
runs-on: ubuntu-latest
permissions:
issues: write
steps:
- name: Create monthly update and upgrade 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: Monthly update and upgrade
ASSIGNEES: theautomation
LABELS: update
BODY: |
### Monthly update and upgrade
- [ ] Proxmox nodes
- [ ] K3s nodes
- [ ] Odroid devices
- [ ] Shelly devices
- [ ] Container images version
- [ ] Truenas
PINNED: false
CLOSE_PREVIOUS: true