Skip to content

Commit

Permalink
Pull request 1896: fix-docker
Browse files Browse the repository at this point in the history
Squashed commit of the following:

commit e64194b
Author: Ainar Garipov <A.Garipov@AdGuard.COM>
Date:   Wed Jun 28 18:02:22 2023 +0300

    scripts: fix docker tags
  • Loading branch information
ainar-g committed Jun 28, 2023
1 parent c652653 commit 2069edd
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions scripts/make/build-docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -62,24 +62,29 @@ readonly docker_output
case "$channel"
in
('release')
docker_tags="--tag=${docker_image_name}:${version},${docker_image_name}:latest"
docker_version_tag="${docker_image_name}:${version}"
docker_channel_tag="${docker_image_name}:latest"
;;
('beta')
docker_tags="--tag=${docker_image_name}:${version},${docker_image_name}:beta"
docker_version_tag="${docker_image_name}:${version}"
docker_channel_tag="${docker_image_name}:beta"
;;
('edge')
docker_tags="--tag=${docker_image_name}:edge"
# Don't set the version tag when pushing to the edge channel.
docker_version_tag="${docker_image_name}:edge"
docker_channel_tag="${docker_image_name}"
;;
('development')
docker_tags="--tag=${docker_image_name}"
docker_version_tag="${docker_image_name}"
docker_channel_tag="${docker_image_name}"
;;
(*)
echo "invalid channel '$channel', supported values are\
'development', 'edge', 'beta', and 'release'" 1>&2
exit 1
;;
esac
readonly docker_tags
readonly docker_version_tag docker_channel_tag

# Copy the binaries into a new directory under new names, so that it's easier to
# COPY them later. DO NOT remove the trailing underscores. See file
Expand Down Expand Up @@ -122,6 +127,7 @@ $sudo_cmd docker\
--build-arg VERSION="$version"\
--output "$docker_output"\
--platform "$docker_platforms"\
"$docker_tags"\
--tag="$docker_version_tag"\
--tag="$docker_channel_tag"\
-f ./docker/Dockerfile\
.

0 comments on commit 2069edd

Please sign in to comment.