Skip to content

Add github action to update dependencies #15

Add github action to update dependencies

Add github action to update dependencies #15

---
name: Check for dependency updates
on:
workflow_dispatch:
schedule:
# Run once a day
- cron: '0 0 * * *'
# Just for now, to make things happen while in PR mode
pull_request:
permissions:
contents: "write"
pull-requests: "write"
env:
UPDATECLI_CONFIG: "${{ github.workspace }}/.github/configs/updatecli.d/node-exporter.yaml"
jobs:
updateNodeExporter:
name: Update Node Exporter
runs-on: "ubuntu-latest"
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install Helm
uses: azure/setup-helm@v3
- name: Install Updatecli
uses: updatecli/updatecli-action@v2
- name: Run Updatecli
run: "updatecli apply --config ${UPDATECLI_CONFIG}"
env:
UPDATECLI_GITHUB_TOKEN: "${{ secrets.GH_BOT_ACCESS_TOKEN }}"
- name: Regenerate docs
run: docker run --rm -v "$(pwd)/charts/k8s-monitoring:/helm-docs" -u "$(id -u)" jnorwood/helm-docs
- name: Regenerate examples
run: make regenerate-example-outputs
- name: Create pull request
uses: peter-evans/create-pull-request@v5
with:
title: "[dependency] Update Node Exporter"
base: main
author: "${{ github.actor }} <${{ github.actor }}@users.noreply.github.com>"
committer: "GitHub <noreply@github.com>"
commit-message: Update Node Exporter
labels: dependencies
branch: fix/update-node-exporter
delete-branch: true
token: "${{ secrets.GH_BOT_ACCESS_TOKEN }}"