Skip to content

Charts / Update mixins #39

Charts / Update mixins

Charts / Update mixins #39

Workflow file for this run

# Copyright (C) Nicolas Lamirault <nicolas.lamirault@gmail.com>
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
# SPDX-License-Identifier: Apache-2.0
name: Charts / Update mixins
on:
workflow_dispatch:
inputs:
# version:
# description: "Monitoring Mixins version"
# required: true
mixins:
description: "Monitoring-Mixins release"
required: true
loglevel:
description: "Log level"
required: true
default: info
python-version:
description: "Python runtime"
required: true
default: "3.8"
poetry-version:
description: "Poetry"
required: true
default: "1.4.1"
permissions:
contents: read
jobs:
mixin:
name: Update mixin
permissions:
contents: write # for peter-evans/create-pull-request to create branch
pull-requests: write # for peter-evans/create-pull-request to create a PR
runs-on: ubuntu-latest
strategy:
matrix:
mixin:
- alertmanager-mixin
- alloy-mixin
- cilium-mixin
- coredns-mixin
- fluxcd-mixin
- grafana-mixin
- kube-state-metrics-mixin
- loki-mixin
- mimir-mixin
- prometheus-mixin
- prometheus-operator-mixin
- pyroscope-mixin
- tempo-mixin
- thanos-mixin
steps:
- name: Checkout
uses: actions/checkout@v4.1.6
- uses: actions/setup-python@v5.0.0
with:
python-version: ${{ github.event.inputs.python-version }}
- name: Run image
uses: abatilo/actions-poetry@v3.0.0
with:
poetry-version: ${{ github.event.inputs.poetry-version }}
- name: Install dependencies
run: |
poetry install
- name: Update mixin
id: update-mixin
run: |
poetry run ./hack/mixins.py ${{ matrix.mixin }} --release ${{ github.event.inputs.mixins }} --log ${{ github.event.inputs.loglevel }}
- name: Create pull request for charts updates
id: cpr
uses: peter-evans/create-pull-request@v6.0.5
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: "mixins/update-${{ matrix.mixin }}-${{ github.event.inputs.mixins }}"
delete-branch: true
title: "Update ${{ matrix.mixin }} to monitoring-mixins-${{ github.event.inputs.mixins }}"
signoff: true
draft: true
committer: "Nicolas Lamirault <nlamirault@users.noreply.github.com>"
author: "Nicolas Lamirault <nlamirault@users.noreply.github.com>"
assignees: "nlamirault"
commit-message: "Update: monitoring mixins set to ${{ github.event.inputs.mixins }} for ${{ matrix.mixin }}"
body: |
- Monitoring mixins set to ${{ github.event.inputs.mixins }}
- Auto-generated by [create-pull-request][1]
[1]: https://github.com/peter-evans/create-pull-request
Signed-off-by: Nicolas Lamirault <nlamirault@users.noreply.github.com>
labels: |
kind/feature
lifecycle/active
status/in_progress
area/helm
priority/medium
- name: Check outputs
run: |
echo "Pull Request Number - ${{ steps.cpr.outputs.pull-request-number }}"
echo "Pull Request URL - ${{ steps.cpr.outputs.pull-request-url }}"