From 3a0e93e18f176bb2c6ccfaf81405b74bf73cf617 Mon Sep 17 00:00:00 2001 From: Ben Vincent Date: Mon, 2 Dec 2024 22:00:38 +1100 Subject: [PATCH] feat: change to nfpm from rpms - nfpm has been packaged and stored in unkin repo --- Dockerfile | 11 ++++------- Makefile | 4 ---- 2 files changed, 4 insertions(+), 11 deletions(-) diff --git a/Dockerfile b/Dockerfile index 5c4a1b6..58a5d08 100644 --- a/Dockerfile +++ b/Dockerfile @@ -6,13 +6,10 @@ RUN dnf module enable -y nodejs:20 && \ dnf install -y nodejs # Install build tools and dependencies for building RPMs -RUN dnf groupinstall -y 'Development Tools' && \ - dnf install -y make cmake gcc gcc-c++ rpm rpmdevtools wget tar gzip go - -# Install nfpm using the RPM package -ARG NFPM_VERSION -ENV NFPM_VERSION=${NFPM_VERSION} -RUN dnf install -y https://github.com/goreleaser/nfpm/releases/download/v${NFPM_VERSION}/nfpm-${NFPM_VERSION}-1.x86_64.rpm +RUN dnf clean all && \ + dnf makecache && \ + dnf groupinstall -y 'Development Tools' && \ + dnf install -y make cmake gcc gcc-c++ rpm rpmdevtools wget tar gzip go nfpm # Cleanup RUN dnf clean all && \ diff --git a/Makefile b/Makefile index a7e38f9..dfe41f6 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,3 @@ -# Set the nfpm version to install -NFPM_VERSION := 2.41.1 - # Get the current Git commit hash GIT_COMMIT := $(shell git rev-parse --short HEAD) @@ -16,7 +13,6 @@ OWNER := unkin build: docker build \ --network=host \ - --build-arg NFPM_VERSION=$(NFPM_VERSION) \ -t $(REGISTRY)/$(OWNER)/$(IMAGE_NAME) . # Tag the Docker image with the Git commit hash, the date, and 'latest'