feat: add argocd CLI (#173)
ci/woodpecker/push/deploy-fedora44 Pipeline was successful
ci/woodpecker/push/deploy-fedora43 Pipeline was successful
ci/woodpecker/push/deploy-fedora42 Pipeline was successful
ci/woodpecker/push/deploy-almalinux9 Pipeline was successful
ci/woodpecker/push/deploy-almalinux8 Pipeline was successful

The ArgoCD CLI is not packaged, so nodes have no supported way to install it alongside the other vendored kubernetes tools. Pin it to the 3.3 series to track the deployed server (v3.3.2).

- Add `argocd` 3.3.14 for almalinux/el9 and fedora 42/43/44
- Fetch the linux-amd64 binary through the artifactapi github remote and verify it against upstream `cli_checksums.txt`
- Generate and package bash, zsh and fish completions
- Hold `update-gh` on the 3.3 series via `github_release_pattern`

Depends on terraform-artifactapi#46; builds 403 until that is merged and applied.

Reviewed-on: #173
Co-authored-by: unkin-agent <unkin-agent@unkin.net>
Co-committed-by: unkin-agent <unkin-agent@unkin.net>
This commit was merged in pull request #173.
This commit is contained in:
2026-09-19 17:09:12 +10:00
committed by BenVincent
parent 0c5684bd9e
commit 327a7c367a
3 changed files with 94 additions and 0 deletions
+24
View File
@@ -0,0 +1,24 @@
name: argocd
github: argoproj/argo-cd
github_release_pattern: ^v3\.3\.
description: Declarative GitOps continuous delivery for Kubernetes - command line
client.
arch: amd64
platform: linux
maintainer: Argo Project
homepage: https://github.com/argoproj/argo-cd
license: Apache-2.0
dist_tag: true
builds:
- repository:
- almalinux/el9
image: git.unkin.net/unkin/almalinux9-rpmbuilder:latest
release: 1
version: 3.3.14
- repository:
- fedora/42
- fedora/43
- fedora/44
image: git.unkin.net/unkin/almalinux9-rpmbuilder:latest
release: 1
version: 3.3.14
+22
View File
@@ -0,0 +1,22 @@
#!/usr/bin/bash
set -e
BASE_URL="https://artifactapi.k8s.syd1.au.unkin.net/api/v1/remote/github/argoproj/argo-cd/releases/download/v${PACKAGE_VERSION}"
wget -O /app/argocd "${BASE_URL}/argocd-linux-amd64"
wget -O /app/cli_checksums.txt "${BASE_URL}/cli_checksums.txt"
# Upstream lists the asset name; check it against the local filename.
cd /app
grep ' argocd-linux-amd64$' cli_checksums.txt | sed 's/argocd-linux-amd64$/argocd/' | sha256sum --check --strict -
chmod +x /app/argocd
mkdir -p /app/completions
/app/argocd completion bash > /app/completions/argocd
/app/argocd completion zsh > /app/completions/_argocd
/app/argocd completion fish > /app/completions/argocd.fish
envsubst < /app/resources/nfpm.yaml > /app/nfpm.yaml
nfpm pkg --config /app/nfpm.yaml --target /app/dist --packager rpm
+48
View File
@@ -0,0 +1,48 @@
# nfpm.yaml
name: ${PACKAGE_NAME}
version: ${PACKAGE_VERSION}
release: ${PACKAGE_RELEASE}
arch: ${PACKAGE_ARCH}
platform: ${PACKAGE_PLATFORM}
section: default
priority: extra
description: "${PACKAGE_DESCRIPTION}"
maintainer: ${PACKAGE_MAINTAINER}
homepage: ${PACKAGE_HOMEPAGE}
license: ${PACKAGE_LICENSE}
disable_globbing: false
replaces:
- argocd
provides:
- argocd
contents:
- src: /app/argocd
dst: /usr/bin/argocd
file_info:
mode: 0755
owner: root
group: root
- src: /app/completions/argocd
dst: /usr/share/bash-completion/completions/argocd
file_info:
mode: 0644
owner: root
group: root
- src: /app/completions/_argocd
dst: /usr/share/zsh/site-functions/_argocd
file_info:
mode: 0644
owner: root
group: root
- src: /app/completions/argocd.fish
dst: /usr/share/fish/vendor_completions.d/argocd.fish
file_info:
mode: 0644
owner: root
group: root