feat: add homelab-deploy workflow
Some checks failed
semantic-release / release (push) Failing after 30s
Some checks failed
semantic-release / release (push) Failing after 30s
This commit is contained in:
@@ -46,7 +46,7 @@ on:
|
|||||||
type: string
|
type: string
|
||||||
default: ""
|
default: ""
|
||||||
secrets:
|
secrets:
|
||||||
token:
|
TOKEN:
|
||||||
required: true
|
required: true
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
@@ -55,14 +55,14 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- name: Install yq
|
- name: Install yq
|
||||||
run: |
|
run: |
|
||||||
wget -qO /usr/local/bin/yq https://github.com/mikefarah/yq/releases/latest/download/yq_linux_amd64
|
wget -qO /usr/local/bin/yq https://github.com/mikefarah/yq/releases/latest/download/yq_linux_arm64
|
||||||
chmod +x /usr/local/bin/yq
|
chmod +x /usr/local/bin/yq
|
||||||
|
|
||||||
- name: Checkout ArgoCD repo
|
- name: Checkout ArgoCD repo
|
||||||
uses: actions/checkout@v6
|
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||||
with:
|
with:
|
||||||
repository: ${{ inputs.argocd-repo }}
|
repository: ${{ inputs.argocd-repo }}
|
||||||
token: ${{ secrets.token }}
|
token: ${{ secrets.TOKEN }}
|
||||||
github-server-url: ${{ inputs.server-url }}
|
github-server-url: ${{ inputs.server-url }}
|
||||||
|
|
||||||
- name: Update Helm chart version
|
- name: Update Helm chart version
|
||||||
|
|||||||
58
.gitea/workflows/homelab-deploy.yaml
Normal file
58
.gitea/workflows/homelab-deploy.yaml
Normal file
@@ -0,0 +1,58 @@
|
|||||||
|
name: Deploy on argocd repo
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_call:
|
||||||
|
inputs:
|
||||||
|
file-path:
|
||||||
|
description: Path to the values/manifest file to update
|
||||||
|
required: true
|
||||||
|
type: string
|
||||||
|
update-helm:
|
||||||
|
description: Whether to update the Helm chart version
|
||||||
|
required: false
|
||||||
|
type: boolean
|
||||||
|
default: false
|
||||||
|
update-image:
|
||||||
|
description: Whether to update the image tag
|
||||||
|
required: false
|
||||||
|
type: boolean
|
||||||
|
default: false
|
||||||
|
helm-path:
|
||||||
|
description: yq path to the Helm version field
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
default: .spec.source.targetRevision
|
||||||
|
helm-version:
|
||||||
|
description: Helm chart version to set
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
default: ""
|
||||||
|
image-path:
|
||||||
|
description: yq path to the image tag field
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
default: ""
|
||||||
|
image-version:
|
||||||
|
description: Image tag to set
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
|
default: ""
|
||||||
|
secrets:
|
||||||
|
TOKEN:
|
||||||
|
required: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
deploy:
|
||||||
|
uses: https://gitea.ldpt.fr/actions/argocd-deploy/.gitea/workflows/deploy.yaml@main
|
||||||
|
with:
|
||||||
|
server-url: https://github.com
|
||||||
|
argocd-repo: lucasdpt/k8s-homelab-gitops
|
||||||
|
file-path: ${{ inputs.file-path }}
|
||||||
|
update-helm: ${{ inputs.update-helm }}
|
||||||
|
update-image: ${{ inputs.update-image }}
|
||||||
|
helm-path: ${{ inputs.helm-path }}
|
||||||
|
helm-version: ${{ inputs.helm-version }}
|
||||||
|
image-path: ${{ inputs.image-path }}
|
||||||
|
image-version: ${{ inputs.image-version }}
|
||||||
|
secrets:
|
||||||
|
TOKEN: ${{ secrets.TOKEN }}
|
||||||
16
.gitea/workflows/release.yaml
Normal file
16
.gitea/workflows/release.yaml
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
name: semantic-release
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
- main
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
|
issues: write
|
||||||
|
pull-requests: write
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
release:
|
||||||
|
uses: https://gitea.ldpt.fr/actions/semantic-release/.github/workflows/semantic-release.yml@v2.3.0
|
||||||
Reference in New Issue
Block a user