From d0a8b6d261627aa49351ea60da9771d9c0f2c899 Mon Sep 17 00:00:00 2001 From: David Kowalski Date: Tue, 27 Aug 2019 19:59:05 +0200 Subject: [PATCH] Add back creating license.key file --- build/ci/Makefile | 3 +++ build/ci/nightly/Jenkinsfile | 3 ++- build/ci/release/Jenkinsfile | 3 ++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/build/ci/Makefile b/build/ci/Makefile index 533d6b3b0b..34804912c7 100644 --- a/build/ci/Makefile +++ b/build/ci/Makefile @@ -55,3 +55,6 @@ yaml-upload: DOCKER_CMD="aws s3 cp $(GO_MOUNT_PATH)/config/all-in-one.yaml \ s3://download.elasticsearch.org/downloads/eck/$(TAG_NAME)/all-in-one.yaml" ci-internal +# reads Elastic public key from Vault into license.key +get-elastic-public-key: + @ VAULT_TOKEN=$(VAULT_TOKEN) vault read -address=$(VAULT_ADDR) -field=pubkey secret/release/license | base64 --decode > license.key diff --git a/build/ci/nightly/Jenkinsfile b/build/ci/nightly/Jenkinsfile index 5fa5b15d69..7cdc48ab8d 100644 --- a/build/ci/nightly/Jenkinsfile +++ b/build/ci/nightly/Jenkinsfile @@ -28,6 +28,7 @@ REGISTRY = "push.docker.elastic.co" REPOSITORY = "eck-snapshots" IMG_NAME = "eck-operator" SNAPSHOT = "true" +LICENSE_PUBKEY = "/go/src/github.com/elastic/cloud-on-k8s/build/ci/license.key" EOF make -C build/ci TARGET=ci ci """ @@ -44,7 +45,7 @@ EOF OPERATOR_IMAGE = "$OPERATOR_IMAGE" LATEST_RELEASED_IMG = "$LATEST_RELEASED_IMG" EOF - make -C build/ci TARGET=ci-release ci + make -C build/ci get-elastic-public-key TARGET=ci-release ci """ } } diff --git a/build/ci/release/Jenkinsfile b/build/ci/release/Jenkinsfile index cc342ee341..313ff7290d 100644 --- a/build/ci/release/Jenkinsfile +++ b/build/ci/release/Jenkinsfile @@ -34,8 +34,9 @@ REPOSITORY = eck IMG_NAME = eck-operator SNAPSHOT = false GO_TAGS = release +LICENSE_PUBKEY = "/go/src/github.com/elastic/cloud-on-k8s/build/ci/license.key" EOF - make -C build/ci TARGET=ci-release ci + make -C build/ci get-elastic-public-key TARGET=ci-release ci """ } }