From c49d71edb3207963662a28cebbc318e2d7076186 Mon Sep 17 00:00:00 2001 From: Leonardo Cecchi Date: Fri, 3 Jan 2025 12:18:12 +0100 Subject: [PATCH 1/2] +cloudnative-pg --- .../cloudnative-pg/cloudnative-pg/package.yml | 34 +++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 projects/github.com/cloudnative-pg/cloudnative-pg/package.yml diff --git a/projects/github.com/cloudnative-pg/cloudnative-pg/package.yml b/projects/github.com/cloudnative-pg/cloudnative-pg/package.yml new file mode 100644 index 0000000000..682c5466a1 --- /dev/null +++ b/projects/github.com/cloudnative-pg/cloudnative-pg/package.yml @@ -0,0 +1,34 @@ +distributable: + url: https://github.com/cloudnative-pg/cloudnative-pg/archive/refs/tags/v{{version}}.tar.gz + strip-components: 1 + +versions: + github: cloudnative-pg/cloudnative-pg + +provides: + - bin/kubectl-cnpg + +build: + dependencies: + go.dev: ^1.23 + script: | + go mod download + mkdir -p "{{ prefix }}"/bin + go build -v -trimpath -ldflags="$LDFLAGS" -o $BUILDLOC ./cmd/kubectl-cnpg/main.go + env: + linux: + LDFLAGS: + - -buildmode=pie + GOPROXY: https://proxy.golang.org,direct + GOSUMDB: sum.golang.org + GO111MODULE: on + CGO_ENABLED: 0 + BUILDLOC: '{{prefix}}/bin/kubectl-cnpg' + LDFLAGS: + - -s + - -w + - -X github.com/cloudnative-pg/cloudnative-pg/pkg/versions.buildVersion={{ version }} + +test: + script: + - kubectl-cnpg version | grep "Version:{{version}} " From 59455d1f5a777e74d1c46c96e95d3669c8bbef7d Mon Sep 17 00:00:00 2001 From: Jacob Heider Date: Fri, 3 Jan 2025 12:29:02 -0500 Subject: [PATCH 2/2] rename, clean up --- projects/cloudnative-pg.io/package.yml | 28 +++++++++++++++ .../cloudnative-pg/cloudnative-pg/package.yml | 34 ------------------- 2 files changed, 28 insertions(+), 34 deletions(-) create mode 100644 projects/cloudnative-pg.io/package.yml delete mode 100644 projects/github.com/cloudnative-pg/cloudnative-pg/package.yml diff --git a/projects/cloudnative-pg.io/package.yml b/projects/cloudnative-pg.io/package.yml new file mode 100644 index 0000000000..bb4dd935b7 --- /dev/null +++ b/projects/cloudnative-pg.io/package.yml @@ -0,0 +1,28 @@ +distributable: + url: https://github.com/cloudnative-pg/cloudnative-pg/archive/refs/tags/{{version.tag}}.tar.gz + strip-components: 1 + +versions: + github: cloudnative-pg/cloudnative-pg + +provides: + - bin/kubectl-cnpg + +build: + dependencies: + go.dev: ~1.23 + script: + - go mod download + - go build -v -trimpath -ldflags="$GO_LDFLAGS" -o '{{prefix}}/bin/kubectl-cnpg' ./cmd/kubectl-cnpg/main.go + env: + linux: + GO_LDFLAGS: + - -buildmode=pie + GO111MODULE: on + CGO_ENABLED: 0 + GO_LDFLAGS: + - -s + - -w + - -X github.com/cloudnative-pg/cloudnative-pg/pkg/versions.buildVersion={{ version }} + +test: kubectl-cnpg version | grep "Version:{{version}} " diff --git a/projects/github.com/cloudnative-pg/cloudnative-pg/package.yml b/projects/github.com/cloudnative-pg/cloudnative-pg/package.yml deleted file mode 100644 index 682c5466a1..0000000000 --- a/projects/github.com/cloudnative-pg/cloudnative-pg/package.yml +++ /dev/null @@ -1,34 +0,0 @@ -distributable: - url: https://github.com/cloudnative-pg/cloudnative-pg/archive/refs/tags/v{{version}}.tar.gz - strip-components: 1 - -versions: - github: cloudnative-pg/cloudnative-pg - -provides: - - bin/kubectl-cnpg - -build: - dependencies: - go.dev: ^1.23 - script: | - go mod download - mkdir -p "{{ prefix }}"/bin - go build -v -trimpath -ldflags="$LDFLAGS" -o $BUILDLOC ./cmd/kubectl-cnpg/main.go - env: - linux: - LDFLAGS: - - -buildmode=pie - GOPROXY: https://proxy.golang.org,direct - GOSUMDB: sum.golang.org - GO111MODULE: on - CGO_ENABLED: 0 - BUILDLOC: '{{prefix}}/bin/kubectl-cnpg' - LDFLAGS: - - -s - - -w - - -X github.com/cloudnative-pg/cloudnative-pg/pkg/versions.buildVersion={{ version }} - -test: - script: - - kubectl-cnpg version | grep "Version:{{version}} "