Merge pull request 'feat: add helmfile package configuration' (#63) from feat/add-helmfile-package into master
Reviewed-on: #63
This commit is contained in:
commit
873abe18c8
1
rpms/helmfile/1.1.7/release
Normal file
1
rpms/helmfile/1.1.7/release
Normal file
@ -0,0 +1 @@
|
||||
1
|
||||
18
rpms/helmfile/Dockerfile
Normal file
18
rpms/helmfile/Dockerfile
Normal file
@ -0,0 +1,18 @@
|
||||
FROM git.unkin.net/unkin/almalinux9-rpmbuilder:latest
|
||||
|
||||
# Create output directory for RPMs
|
||||
RUN mkdir -p /app/dist
|
||||
|
||||
# Set working directory
|
||||
WORKDIR /app
|
||||
|
||||
ARG PACKAGE_RELEASE
|
||||
ENV PACKAGE_RELEASE=${PACKAGE_RELEASE}
|
||||
ARG PACKAGE_VERSION
|
||||
ENV PACKAGE_VERSION=${PACKAGE_VERSION}
|
||||
|
||||
# Copy resources from the context into the container
|
||||
COPY resources /app/resources
|
||||
|
||||
# Default command to build RPMs
|
||||
CMD /app/resources/build.sh
|
||||
9
rpms/helmfile/metadata.yaml
Normal file
9
rpms/helmfile/metadata.yaml
Normal file
@ -0,0 +1,9 @@
|
||||
name: helmfile
|
||||
release: 1
|
||||
version: 1.1.7
|
||||
build:
|
||||
- distro: el/8
|
||||
image: git.unkin.net/unkin/almalinux8-rpmbuilder:latest
|
||||
- distro: el/9
|
||||
image: git.unkin.net/unkin/almalinux9-rpmbuilder:latest
|
||||
github: helmfile/helmfile
|
||||
14
rpms/helmfile/resources/build.sh
Executable file
14
rpms/helmfile/resources/build.sh
Executable file
@ -0,0 +1,14 @@
|
||||
#!/usr/bin/bash
|
||||
|
||||
# Download the required files
|
||||
curl -L -o /app/helmfile.tar.gz https://github.com/helmfile/helmfile/releases/download/v${PACKAGE_VERSION}/helmfile_${PACKAGE_VERSION}_linux_amd64.tar.gz
|
||||
|
||||
# Extract the binary
|
||||
cd /app
|
||||
tar -xzf helmfile.tar.gz
|
||||
|
||||
# Make the binary executable
|
||||
chmod +x /app/helmfile
|
||||
|
||||
# Build the RPM
|
||||
nfpm pkg --config /app/resources/nfpm.yaml --target /app/dist --packager rpm
|
||||
38
rpms/helmfile/resources/nfpm.yaml
Normal file
38
rpms/helmfile/resources/nfpm.yaml
Normal file
@ -0,0 +1,38 @@
|
||||
# nfpm.yaml
|
||||
|
||||
name: helmfile
|
||||
version: ${PACKAGE_VERSION}
|
||||
release: ${PACKAGE_RELEASE}
|
||||
arch: amd64
|
||||
platform: linux
|
||||
section: default
|
||||
priority: extra
|
||||
description: "A declarative spec for deploying Helm charts. It lets you keep a directory of chart value files and maintain changes in version control; apply CI/CD to configuration changes; and periodically sync to avoid skew in environments."
|
||||
|
||||
maintainer: Helmfile Contributors
|
||||
homepage: https://github.com/helmfile/helmfile
|
||||
license: MIT
|
||||
|
||||
disable_globbing: false
|
||||
|
||||
replaces:
|
||||
- helmfile
|
||||
|
||||
provides:
|
||||
- helmfile
|
||||
|
||||
# Files to include in the package
|
||||
contents:
|
||||
- src: /app/helmfile
|
||||
dst: /usr/bin/helmfile
|
||||
file_info:
|
||||
mode: 0755
|
||||
owner: root
|
||||
group: root
|
||||
|
||||
# Scripts to run during installation/removal (optional)
|
||||
# scripts:
|
||||
# preinstall: ./scripts/preinstall.sh
|
||||
# postinstall: ./scripts/postinstall.sh
|
||||
# preremove: ./scripts/preremove.sh
|
||||
# postremove: ./scripts/postremove.sh
|
||||
Loading…
Reference in New Issue
Block a user