Skip to content

Commit 19fb49e

Browse files
committed
Support ghcr.io registry for docker:push
1 parent eb5ddae commit 19fb49e

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

Rakefile

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -239,10 +239,18 @@ namespace :docker do
239239
ruby_version, tags = make_tags(ruby_version, version_suffix, tag_suffix)
240240

241241
tags.each do |tag|
242+
if ENV['registry_name'].start_with?('ghcr.io')
243+
docker_tag = tag.split("/").last
244+
sh 'docker', 'tag', docker_tag, tag
245+
end
242246
sh 'docker', 'push', tag
243247
end
244248

245249
each_nightly_tag(ruby_version, tags) do |_, tag|
250+
if ENV['registry_name'].start_with?('ghcr.io')
251+
docker_tag = tag.split("/").last
252+
sh 'docker', 'tag', docker_tag, tag
253+
end
246254
sh 'docker', 'push', tag
247255
end
248256
end

0 commit comments

Comments
 (0)