File tree Expand file tree Collapse file tree 3 files changed +11
-6
lines changed
Expand file tree Collapse file tree 3 files changed +11
-6
lines changed Original file line number Diff line number Diff line change 6767 --build-arg "BASE_IMAGE=${bamboo_dockerSnap}"
6868 --build-arg "CACHE_BUSTER=${bamboo_cacheBuster}" \
6969 --build-arg "CHANNEL=${bamboo_channel}" \
70+ --build-arg "VERSION=${bamboo_buildNumber}" \
7071 --output '.' \
7172 --progress 'plain' \
7273 --target 'builder-exporter' \
102103 --build-arg "CACHE_BUSTER=${bamboo_cacheBuster}" \
103104 --build-arg "SNAPCRAFT_CHANNEL=${bamboo_snapcraftChannel}" \
104105 --build-arg "SNAPCRAFT_STORE_CREDENTIALS=${bamboo_snapcraftMacaroonPassword}" \
106+ --build-arg "VERSION=${bamboo_buildNumber}" \
105107 --output '.' \
106108 --progress 'plain' \
107109 --target 'publisher' \
Original file line number Diff line number Diff line change @@ -169,7 +169,7 @@ RUN \
169169<<-'EOF'
170170set -e -f -u -x
171171
172- # Import GPG key if provided
172+ # Import GPG key if provided.
173173if [ "${GPG_SECRET_KEY:-}" != '' ]; then
174174 echo "$GPG_SECRET_KEY" | awk '{ gsub(/\\ n/, "\n "); print; }' | gpg --import --batch --yes
175175fi
Original file line number Diff line number Diff line change @@ -34,27 +34,29 @@ ARG BASE_IMAGE=adguard/snap-builder:2.1
3434FROM "$BASE_IMAGE" AS builder
3535ARG CACHE_BUSTER=0
3636ARG CHANNEL=development
37+ ARG VERSION=""
3738ADD snap /app/snap
3839ADD scripts /app/scripts
3940WORKDIR /app
4041RUN \
4142<<-'EOF'
4243set -e -f -u -x
4344
45+ export VERBOSE='1'
46+
4447env \
4548 CHANNEL="${CHANNEL}" \
46- VERBOSE= '1' \
47- sh ./scripts/snap/download.sh
49+ sh ./scripts/snap/download.sh \
50+ ;
4851
49- env \
50- VERBOSE='1' \
51- sh ./scripts/snap/build.sh
52+ sh ./scripts/snap/build.sh
5253EOF
5354
5455# builder-exporter exports the build artifacts to the host machine so that they
5556# could be published. This stage should only be used in a CI.
5657FROM scratch AS builder-exporter
5758ARG CACHE_BUSTER=0
59+ ARG VERSION=""
5860COPY --from=builder /app/AdGuardHome_amd64.snap /AdGuardHome_amd64.snap
5961COPY --from=builder /app/AdGuardHome_arm64.snap /AdGuardHome_arm64.snap
6062COPY --from=builder /app/AdGuardHome_armhf.snap /AdGuardHome_armhf.snap
@@ -65,6 +67,7 @@ FROM "$BASE_IMAGE" AS publisher
6567ARG CACHE_BUSTER=0
6668ARG SNAPCRAFT_CHANNEL=0
6769ARG SNAPCRAFT_STORE_CREDENTIALS=0
70+ ARG VERSION=""
6871ADD snap /app/snap
6972ADD scripts /app/scripts
7073ADD AdGuardHome_amd64.snap /app/AdGuardHome_amd64.snap
You can’t perform that action at this time.
0 commit comments