From 153db9749171021f0c0048c587c6679814f5eafe Mon Sep 17 00:00:00 2001 From: "octo-sts[bot]" <157150467+octo-sts[bot]@users.noreply.github.com> Date: Wed, 23 Oct 2024 16:52:57 -0700 Subject: [PATCH] Adding VersionStream for gitaly-17.5 (#31201) Signed-off-by: RJ Trujillo Co-authored-by: octo-sts[bot] <157150467+octo-sts@users.noreply.github.com> Co-authored-by: RJ Trujillo --- gitaly-17.5.yaml | 121 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 121 insertions(+) create mode 100644 gitaly-17.5.yaml diff --git a/gitaly-17.5.yaml b/gitaly-17.5.yaml new file mode 100644 index 00000000000..4c7cc0d5aa3 --- /dev/null +++ b/gitaly-17.5.yaml @@ -0,0 +1,121 @@ +package: + name: gitaly-17.5 + version: "17.5.1" + epoch: 0 + description: + copyright: + - license: MIT + dependencies: + provides: + - gitaly=${{package.full-version}} + runtime: + - gitaly-backup-${{vars.major-minor-version}} + +var-transforms: + - from: ${{package.version}} + match: ^(\d+\.\d+)\.\d+$ + replace: "$1" + to: major-minor-version + +environment: + contents: + packages: + - build-base + - busybox + - curl-dev + - expat-dev + - openssl-dev + - pcre2-dev + - wolfi-base + - zlib-dev + environment: + WITH_BUNDLED_GIT: YesPlease + +pipeline: + - uses: git-checkout + with: + repository: https://gitlab.com/gitlab-org/gitaly.git + tag: v${{package.version}} + expected-commit: 42b2dc21d50d19003ae74ba9cdadc94aed686162 + + - runs: | + make install DESTDIR="${{targets.destdir}}" PREFIX=/usr + + - uses: strip + +subpackages: + # Leave at the top so that links are created for all binaries in package + - name: gitaly-compat-${{vars.major-minor-version}} + description: "Compatibility package to place binaries in the location expected by upstream Dockerfile" + dependencies: + provides: + - gitaly-compat=${{package.full-version}} + pipeline: + - runs: | + mkdir -p "${{targets.contextdir}}"/usr/local/bin + cd ${{targets.destdir}}/usr/bin + for binary in *; do + ln -sf /usr/bin/$binary ${{targets.contextdir}}/usr/local/bin/$binary + done + + - name: gitaly-git-${{vars.major-minor-version}} + description: Bundled Git for Gitaly + dependencies: + provides: + - gitaly-git=${{vars.major-minor-version}} + pipeline: + - runs: | + mkdir -p ${{targets.contextdir}}/usr/bin + mv ${{targets.destdir}}/usr/bin/gitaly-git-* ${{targets.contextdir}}/usr/bin + + - name: gitaly-backup-${{vars.major-minor-version}} + description: Git repository backup tool + dependencies: + provides: + - gitaly-backup=${{vars.major-minor-version}} + pipeline: + - runs: | + mkdir -p ${{targets.contextdir}}/usr/bin + mv ${{targets.destdir}}/usr/bin/gitaly-backup ${{targets.contextdir}}/usr/bin/ + + - name: gitaly-init-cgroups-${{vars.major-minor-version}} + # https://gitlab.com/gitlab-org/build/CNG/-/blob/master/gitaly-init-cgroups/Dockerfile + description: gitaly-init-cgroups + dependencies: + provides: + - gitaly-init-cgroups=${{package.full-version}} + pipeline: + - uses: go/build + with: + packages: . + modroot: ./tools/gitaly-init-cgroups/ + output: setup_cgroups + + - name: gitaly-init-cgroups-compat-${{vars.major-minor-version}} + description: "Compatibility package to place binaries in the location expected by upstream Dockerfile" + dependencies: + provides: + - gitaly-init-cgroups-compat=${{package.full-version}} + pipeline: + - runs: | + mkdir -p "${{targets.contextdir}}"/ + ln -sf /usr/bin/setup_cgroups "${{targets.contextdir}}"/setup_cgroups + +update: + enabled: true + git: + strip-prefix: v + tag-filter-prefix: v17.5 + +test: + pipeline: + - runs: | + gitaly -v | grep "${{package.version}}" + gitaly-blackbox -version | grep "${{package.version}}" + gitaly-backup -v | grep "${{package.version}}" + gitaly --version + gitaly --help + gitaly-blackbox --version + gitaly-blackbox --help + praefect --version + praefect --help