Build scripts: fixed timestamp setting

This commit is contained in:
SChernykh
2025-07-07 16:17:18 +02:00
parent c5b4e84652
commit 24ac83e88b
27 changed files with 72 additions and 63 deletions

View File

@@ -1,4 +1,4 @@
FROM p2pool_build_ubuntu
ARG P2POOL_VERSION BUILD_TIMESTAMP
ARG P2POOL_VERSION
ADD p2pool_source.sh /root
RUN /root/p2pool_source.sh ${P2POOL_VERSION} ${BUILD_TIMESTAMP}
RUN /root/p2pool_source.sh ${P2POOL_VERSION}

View File

@@ -4,7 +4,7 @@
cd "$(dirname "$0")"
docker build --build-arg P2POOL_VERSION=$1 --build-arg BUILD_TIMESTAMP="$(git show --no-patch --format=%ct $1)" -t p2pool_source_build .
docker build --build-arg P2POOL_VERSION=$1 -t p2pool_source_build .
docker create --name p2pool_source_build_container p2pool_source_build:latest
docker cp p2pool_source_build_container:/p2pool_source-$1.tar.xz ../p2pool_source-$1.tar.xz

View File

@@ -8,9 +8,10 @@ git submodule update --recursive --jobs $(nproc)
export TZ=UTC0
CURRENT_DATE=$(date -u -d @$2 +"%Y-%m-%d")
CURRENT_TIME=$(date -u -d @$2 +"%H:%M:%S")
TOUCH_DATE=$(date -u -d @$2 +"%Y%m%d%H%M.%S")
BUILD_TIMESTAMP=$(git show --no-patch --format=%ct $1)
CURRENT_DATE=$(date -u -d @$BUILD_TIMESTAMP +"%Y-%m-%d")
CURRENT_TIME=$(date -u -d @$BUILD_TIMESTAMP +"%H:%M:%S")
TOUCH_DATE=$(date -u -d @$BUILD_TIMESTAMP +"%Y%m%d%H%M.%S")
cd /