diff --git a/.tool-versions b/.tool-versions index 99d4d627834566563538854a6e3966dd0bdeaab2..98d58c7798d009e2c62433fd7ee39cc13359644c 100644 --- a/.tool-versions +++ b/.tool-versions @@ -13,8 +13,6 @@ gitleaks 8.16.4 # 1.21.5: # - https://gitlab.com/gitlab-org/gitlab/-/raw/master/workhorse/.tool-versions # 1.21.4: -# - https://gitlab.com/gitlab-org/gitlab-pages/-/raw/master/.tool-versions -# - https://gitlab.com/gitlab-org/gitlab-pages -> https://gitlab.com/gitlab-org/gitlab/-/raw/master/GITLAB_PAGES_VERSION # - https://gitlab.com/gitlab-org/gitaly/-/raw/master/.tool-versions # - https://gitlab.com/gitlab-org/gitaly -> https://gitlab.com/gitlab-org/gitlab/-/raw/master/GITALY_SERVER_VERSION # - https://gitlab.com/gitlab-org/gitlab-elasticsearch-indexer/-/raw/main/.tool-versions diff --git a/support/asdf-combine b/support/asdf-combine index 5fec74a3c8789bcd4cadd49100b652fe21f9f4aa..0b66df2b18d70a3cd9f7c6bcd4d3d4cd38993567 100755 --- a/support/asdf-combine +++ b/support/asdf-combine @@ -13,7 +13,6 @@ FileNotFoundError = Class.new(StandardError) GITLAB_ORG_URL = 'https://gitlab.com/gitlab-org' GITLAB_URL = "#{GITLAB_ORG_URL}/gitlab".freeze -GITLAB_PAGES_URL = "#{GITLAB_ORG_URL}/gitlab-pages".freeze GITALY_URL = "#{GITLAB_ORG_URL}/gitaly".freeze GITLAB_RUNNER_URL = "#{GITLAB_ORG_URL}/gitlab-runner".freeze GITLAB_ELASTICSEARCH_INDEXER_URL = "#{GITLAB_ORG_URL}/gitlab-elasticsearch-indexer".freeze @@ -172,8 +171,6 @@ end tool_versions_files = [ RemoteToolVersionFile.new(GITLAB_URL), RemoteToolVersionFile.new(GITLAB_URL, path: 'workhorse'), - RemoteToolVersionFile.new(GITLAB_PAGES_URL), - RemoteToolVersionFile.new(GITLAB_PAGES_URL, ref: ref_from_remote_file_for_gitlab_project('GITLAB_PAGES_VERSION'), label_ref: url_for_remote_file_for_gitlab_project('GITLAB_PAGES_VERSION')), RemoteToolVersionFile.new(GITALY_URL), RemoteToolVersionFile.new(GITALY_URL, ref: ref_from_remote_file_for_gitlab_project('GITALY_SERVER_VERSION'), label_ref: url_for_remote_file_for_gitlab_project('GITALY_SERVER_VERSION')), RemoteToolVersionFile.new(GITLAB_RUNNER_URL, ref: 'main'), diff --git a/support/makefiles/Makefile.gitlab-pages.mk b/support/makefiles/Makefile.gitlab-pages.mk index 862a09e429d08b6d5ab3d1357363e0835c597953..b93903fdd4f5962ef1be5884d6f99f43c21fb549 100644 --- a/support/makefiles/Makefile.gitlab-pages.mk +++ b/support/makefiles/Makefile.gitlab-pages.mk @@ -1,4 +1,4 @@ -gitlab_pages_clone_dir = gitlab-pages +gitlab_pages_dir = ${gitlab_development_root}/gitlab-pages gitlab_pages_version = $(shell support/resolve-dependency-commitish "${gitlab_development_root}/gitlab/GITLAB_PAGES_VERSION") ifeq ($(gitlab_pages_enabled),true) @@ -18,21 +18,33 @@ endif .PHONY: gitlab-pages-update-run gitlab-pages-update-run: gitlab-pages-secret gitlab-pages/gitlab-pages.conf gitlab-pages/bin/gitlab-pages +gitlab-pages-asdf-install: +ifeq ($(asdf_opt_out),false) + @echo + @echo "${DIVIDER}" + @echo "Installing asdf tools from ${gitlab_pages_dir}/.tool-versions" + @echo "${DIVIDER}" + $(Q)cd ${gitlab_pages_dir} && ASDF_DEFAULT_TOOL_VERSIONS_FILENAME="${gitlab_pages_dir}/.tool-versions" asdf install + $(Q)cd ${gitlab_pages_dir} && asdf reshim +else + @true +endif + .PHONY: gitlab-pages/bin/gitlab-pages -gitlab-pages/bin/gitlab-pages: gitlab-pages/.git/pull +gitlab-pages/bin/gitlab-pages: gitlab-pages/.git/pull gitlab-pages-asdf-install @echo @echo "${DIVIDER}" @echo "Compiling gitlab-org/gitlab-pages" @echo "${DIVIDER}" $(Q)rm -f gitlab-pages/bin/gitlab-pages - $(Q)support/asdf-exec ${gitlab_pages_clone_dir} $(MAKE) ${QQ} + $(Q)support/asdf-exec ${gitlab_pages_dir} $(MAKE) ${QQ} gitlab-pages/.git: - $(Q)support/move-existing-gitlab-pages-directory || GIT_REVISION="${gitlab_pages_version}" support/component-git-clone ${git_params} ${gitlab_pages_repo} ${gitlab_pages_clone_dir} ${QQ} + $(Q)support/move-existing-gitlab-pages-directory || GIT_REVISION="${gitlab_pages_version}" support/component-git-clone ${git_params} ${gitlab_pages_repo} ${gitlab_pages_dir} ${QQ} gitlab-pages/.git/pull: gitlab-pages/.git @echo @echo "${DIVIDER}" @echo "Updating gitlab-org/gitlab-pages to ${gitlab_pages_version}" @echo "${DIVIDER}" - $(Q)support/component-git-update gitlab_pages "${gitlab_pages_clone_dir}" "${gitlab_pages_version}" master + $(Q)support/component-git-update gitlab_pages "${gitlab_pages_dir}" "${gitlab_pages_version}" master