From ff4a98f2acb557ad443f279627036bebf06bc4f1 Mon Sep 17 00:00:00 2001 From: Nikolai Rodionov Date: Tue, 27 Feb 2024 16:35:31 +0100 Subject: [PATCH] Add build args support --- scripts/build-container | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/build-container b/scripts/build-container index 9cfe961..b7a6e70 100755 --- a/scripts/build-container +++ b/scripts/build-container @@ -42,8 +42,9 @@ my $custom_tag = $ENV{'CUSTOM_TAG'} || ""; my $username = $ENV{'DRONE_USERNAME'} || "allanger"; my $password = $ENV{'GITEA_TOKEN'} || "YOU NOT AUTHORIZED, PAL"; my $containerfile = $ENV{'CONTAINERFILE'} || "Containerfile"; +my $args = $ENV{'BUILD_ARGS'}; 0 == system ("buildah login --username $username --password $password $container_registry") or die $!; -0 == system ("buildah bud -t $tag -f $containerfile .") or die $!; +0 == system ("buildah bud -t $tag -f $containerfile $args .") or die $!; 0 == system ("buildah push $tag") or die $!; # --------------------------------------------------------------------------- # -- Push the latest if the branch is main