From d52006f8e8e7e141bca240fcd9c9cbaf1f42038e Mon Sep 17 00:00:00 2001 From: Nikolai Rodionov Date: Fri, 20 Sep 2024 06:36:27 +0200 Subject: [PATCH] Update scripts to use zot --- scripts/build-container | 4 ++-- scripts/cleanup | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/scripts/build-container b/scripts/build-container index b7a6e70..78f7264 100755 --- a/scripts/build-container +++ b/scripts/build-container @@ -35,12 +35,12 @@ chomp($git_commit_sha); # -- Build the image with SHA tag # -- my main build system is DRONE, so I'm using DRONE variables a lot # --------------------------------------------------------------------------- -my $container_registry = $ENV{'CONTAINER_REGISTRY'} || 'git.badhouseplants.net'; +my $container_registry = $ENV{'CONTAINER_REGISTRY'} || 'zot.badhouseplants.net'; my $image_name = $ENV{'PACKAGE_NAME'} | $ENV{'DRONE_REPO'} || "badhouseplants/badhouseplants-net"; my $tag = "$container_registry/$image_name:$git_commit_sha"; my $custom_tag = $ENV{'CUSTOM_TAG'} || ""; my $username = $ENV{'DRONE_USERNAME'} || "allanger"; -my $password = $ENV{'GITEA_TOKEN'} || "YOU NOT AUTHORIZED, PAL"; +my $password = $ENV{'REGISTRY_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 $!; diff --git a/scripts/cleanup b/scripts/cleanup index ae95533..4e9a6a6 100755 --- a/scripts/cleanup +++ b/scripts/cleanup @@ -25,12 +25,12 @@ use warnings; # -------------------------------------- # -- Gitea variables # -------------------------------------- -my $gitea_url=$ENV{'GITEA_URL'} || 'https://git.badhouseplants.net/api/v1'; +my $gitea_url=$ENV{'GITEA_URL'} || 'https://zot.badhouseplants.net/api/v1'; my $gitea_org=$ENV{'DRONE_REPO_NAMESPACE'} || 'badhouseplants'; my $gitea_package=$ENV{'DRONE_REPO_NAME'} || 'badhouseplants-net'; my $gitea_api="$gitea_url/packages/$gitea_org/container/$gitea_package"; my $gitea_list_api="$gitea_url/packages/$gitea_org?page=1&type=container&q=$gitea_package"; -my $gitea_token=$ENV{'GITEA_TOKEN'}; +my $gitea_token=$ENV{'REGISTRY_TOKEN'}; my $gitea_user=$ENV{'GITEA_USER'} || $ENV{'DRONE_COMMIT_AUTHOR'}; # --------------------------------------- # -- Get tags from Gitea @@ -85,4 +85,4 @@ if (defined $ENV{CLEANUP_MINIO}) { print "$output \n"; } } -} \ No newline at end of file +}