refactor: move download logic from Dockerfiles to build.sh scripts

Move complex download commands from Dockerfiles to build.sh scripts for consistency:
- pgbouncer_exporter, bind_exporter, exportarr, node_exporter, postgres_exporter: GitHub downloads
- vmagent, vmalert: VictoriaMetrics vmutils downloads
- vminsert, vmselect, vmstorage: VictoriaMetrics cluster downloads

All Dockerfiles now follow the simple template pattern with download logic properly contained in build scripts.
This commit is contained in:
2025-09-29 21:53:08 +10:00
parent 325b830952
commit 46016bae5c
20 changed files with 55 additions and 43 deletions
+1 -5
View File
@@ -11,13 +11,9 @@ ENV PACKAGE_RELEASE=${PACKAGE_RELEASE}
ARG PACKAGE_VERSION
ENV PACKAGE_VERSION=${PACKAGE_VERSION}
# Copy nfpm.yaml from the context into the container
# Copy resources from the context into the container
COPY resources /app/resources
# Download the required files
RUN wget -O /app/victoria-metrics-linux-amd64-v${PACKAGE_VERSION}-cluster.tar.gz \
https://github.com/VictoriaMetrics/VictoriaMetrics/releases/download/v${PACKAGE_VERSION}/victoria-metrics-linux-amd64-v${PACKAGE_VERSION}-cluster.tar.gz && \
tar xf victoria-metrics-linux-amd64-v${PACKAGE_VERSION}-cluster.tar.gz
# Default command to build RPMs
CMD /app/resources/build.sh
+5
View File
@@ -1,2 +1,7 @@
#!/usr/bin/bash
# Download the required files
wget -O /app/victoria-metrics-linux-amd64-v${PACKAGE_VERSION}-cluster.tar.gz https://github.com/VictoriaMetrics/VictoriaMetrics/releases/download/v${PACKAGE_VERSION}/victoria-metrics-linux-amd64-v${PACKAGE_VERSION}-cluster.tar.gz
tar xf victoria-metrics-linux-amd64-v${PACKAGE_VERSION}-cluster.tar.gz
nfpm pkg --config /app/resources/nfpm.yaml --target /app/dist --packager rpm