mirror of
https://gitdl.cn/https://github.com/chakralinux/desktop.git
synced 2025-01-24 18:42:12 +08:00
69 lines
2.8 KiB
Bash
69 lines
2.8 KiB
Bash
# Arch Maintainer: Sven-Hendrik Haase <sh@lutzhaase.com>
|
|
|
|
pkgname=gitlab-runner
|
|
pkgver=10.7.2
|
|
pkgrel=1
|
|
pkgdesc="The official GitLab CI runner written in Go"
|
|
arch=('x86_64')
|
|
url='https://gitlab.com/gitlab-org/gitlab-runner'
|
|
license=('GPL3')
|
|
depends=('ca-certificates' 'curl' 'git' 'glibc' 'tar')
|
|
makedepends=('git' 'go' 'git' 'go-bindata')
|
|
install='gitlab-runner.install'
|
|
backup=('etc/gitlab-runner/config.toml')
|
|
noextract=('prebuilt-x86_64.tar.xz')
|
|
|
|
# Note: This should be built using git because the runner gets its version information from there and I
|
|
# haven't found the place to patch that yet.
|
|
source=("git+https://gitlab.com/gitlab-org/gitlab-runner.git#tag=v${pkgver}"
|
|
"prebuilt-${pkgver}-x86_64.tar.xz::https://gitlab-runner-downloads.s3.amazonaws.com/v${pkgver}/docker/prebuilt-x86_64.tar.xz"
|
|
"gitlab-runner.service"
|
|
"gitlab-runner.sysusers"
|
|
"gitlab-runner.tmpfiles"
|
|
"config.toml")
|
|
sha512sums=('SKIP'
|
|
'01c872629a283a106c31227f5b1968f8fd199748fd9dc8a3146bf7bc2409e51f3585ad8c5abef0d33be5c7ac7f391251cb0f0385a6af800f392b31956573fc0c'
|
|
'8a5a8b7654d3864722e784b2814c6278c17876f1c0c4fc0676fbcf6817ad2ba4be55501e67ce88c62b5b63ca886b01afc6feac98ba49842acd244abdd1a8296f'
|
|
'8aa7f08702e99053c696fcc2aaba83beb9e9cd6f31973d82862db9350ac46df3a095377625d31fe909677525290d2de922d7a97930ed235774cb8f0da8944d40'
|
|
'6751d9fa0b27172d1b419c4138f5ac15cbc7c9147653a7258cf1470216142c637210bb60608c7ed0974e0e4057e5ddeae32225df1bb36e7dd1f20fec71e33cc3'
|
|
'f39c23fc06636f31c3fadb9a630c54527e8255098f18d275772cb30875d0a7463717101704070d432f2b69ab71f076a9538172a439bc307722dad2c7e260f752')
|
|
|
|
|
|
prepare() {
|
|
mkdir -p "${srcdir}/src/gitlab.com/gitlab-org/"
|
|
ln -sf "${srcdir}/gitlab-runner" "${srcdir}/src/gitlab.com/gitlab-org/gitlab-runner"
|
|
cd "${srcdir}/src/gitlab.com/gitlab-org/gitlab-runner"
|
|
|
|
make version
|
|
|
|
export GOPATH="${srcdir}"
|
|
#make deps
|
|
|
|
ln -sf "${srcdir}/prebuilt-${pkgver}-x86_64.tar.xz" prebuilt-x86_64.tar.xz
|
|
}
|
|
|
|
build() {
|
|
cd "${srcdir}/src/gitlab.com/gitlab-org/gitlab-runner"
|
|
|
|
export GOPATH="${srcdir}"
|
|
go-bindata \
|
|
-pkg docker \
|
|
-nocompress \
|
|
-nomemcopy \
|
|
-prefix out/docker/ \
|
|
-o executors/docker/bindata.go \
|
|
prebuilt-x86_64.tar.xz
|
|
|
|
make build_simple
|
|
}
|
|
|
|
package() {
|
|
cd "${srcdir}/src/gitlab.com/gitlab-org/gitlab-runner"
|
|
|
|
install -Dm644 "${srcdir}/config.toml" "${pkgdir}/etc/gitlab-runner/config.toml"
|
|
install -Dm644 "${srcdir}/gitlab-runner.service" "${pkgdir}/usr/lib/systemd/system/gitlab-runner.service"
|
|
install -Dm644 "${srcdir}/gitlab-runner.sysusers" "${pkgdir}/usr/lib/sysusers.d/gitlab-runner.conf"
|
|
install -Dm644 "${srcdir}/gitlab-runner.tmpfiles" "${pkgdir}/usr/lib/tmpfiles.d/gitlab-runner.conf"
|
|
install -Dm755 out/binaries/gitlab-runner "${pkgdir}/usr/bin/gitlab-runner"
|
|
}
|