From 4df7311d4d17932338a9d0ef8ce256d740b29834 Mon Sep 17 00:00:00 2001 From: Rob Day-Reynolds Date: Fri, 20 Oct 2017 12:03:37 -0700 Subject: [PATCH] Create 3468.x stemcell branch [#152152804](https://www.pivotaltracker.com/story/show/152152804) Signed-off-by: Danny Berger --- ci/configure.sh | 7 +++++-- ci/os-images/configure.sh | 7 +++++-- ci/pipeline.yml | 5 +++-- docs/new_stemcell_line.md | 23 +++++++++++++---------- 4 files changed, 26 insertions(+), 16 deletions(-) diff --git a/ci/configure.sh b/ci/configure.sh index faeb33338..073c8f324 100755 --- a/ci/configure.sh +++ b/ci/configure.sh @@ -3,6 +3,9 @@ set -eu fly -t production set-pipeline \ - -p bosh:stemcells -c ci/pipeline.yml \ + -p bosh:stemcells:3468.x -c ci/pipeline.yml \ -l <(lpass show --note "concourse:production pipeline:bosh:stemcells") \ - -l <(lpass show --note "bats-concourse-pool:vsphere secrets") + -l <(lpass show --note "bats-concourse-pool:vsphere secrets") \ + -v stemcell_branch=3468.x \ + -v stemcell_version_key=bosh-stemcell/version-3468.x \ + -v stemcell_version_semver_bump=minor diff --git a/ci/os-images/configure.sh b/ci/os-images/configure.sh index 06232e57e..02fb738ea 100755 --- a/ci/os-images/configure.sh +++ b/ci/os-images/configure.sh @@ -2,6 +2,9 @@ set -eu -fly -t production set-pipeline -p bosh:os-image \ +STEMCELL_VERSION=3468.x + +fly -t production set-pipeline -p bosh:os-image:$STEMCELL_VERSION \ -c ci/os-images/pipeline.yml \ - --load-vars-from <(lpass show "concourse:production pipeline:os-images" --notes) + --load-vars-from <(lpass show "concourse:production pipeline:os-images" --notes) \ + -v branch=$STEMCELL_VERSION diff --git a/ci/pipeline.yml b/ci/pipeline.yml index a55c32012..09986c741 100644 --- a/ci/pipeline.yml +++ b/ci/pipeline.yml @@ -761,14 +761,14 @@ resources: type: git source: uri: git@github.com:cloudfoundry/bosh-linux-stemcell-builder - branch: {{stemcell-branch}} + branch: {{stemcell_branch}} private_key: {{bosh_src_key}} - name: bosh-linux-stemcell-builder type: git source: uri: https://github.com/cloudfoundry/bosh-linux-stemcell-builder - branch: master + branch: {{stemcell_branch}} - name: stemcells-index type: git @@ -785,6 +785,7 @@ resources: bucket: {{candidate_stemcell_bucket}} access_key_id: {{stemcell_aws_access_key}} secret_access_key: {{stemcell_aws_secret_key}} + initial_version: 3468.0.0 - name: syslog-release type: bosh-io-release diff --git a/docs/new_stemcell_line.md b/docs/new_stemcell_line.md index 0727ded5e..d2d347a53 100644 --- a/docs/new_stemcell_line.md +++ b/docs/new_stemcell_line.md @@ -12,16 +12,19 @@ #### Stemcells and OS Images 1. Create a new branch in `bosh-linux-stemcell-builder` named `9999.x` -1. Using the version of the published stemcell, create a new lastpass note for that stemcell line (include version in the name, see pre-existing notes) - 1. Change the `stemcell_branch` value to `9999.x`. - 1. Change the `stemcell_version_key` value to `bosh-stemcell/version-9999.x` - 1. Change the `stemcell_version_semver_bump` value to `minor` - 1. Disregard: ~~Change the `fly` command to refer to the `9999.x` branch, `9999.x` note, and `9999.x` pipeline (or delete that command, we have configure scripts).~~ *Moved to configure.sh* -1. Create a new note for `concourse:production pipeline:os-images:9999.x` - copy & paste the previous branch `concourse:production pipeline:os-images` into a new secure note, in Shared Folder "Shared-BOSH Core (Pivotal Only)". - 1. Update the `branch` value. -1. Update the `configure.sh` scripts to create `bosh:os-image:9999.x` and `bosh:stemcell:9999.x` pipelines, using the note(s) for 9999.x. +1. Using the version of the published stemcell, add some variables to the `ci/configure.sh` +``` + -v stemcell_branch=9999.x \ + -v stemcell_version_key=bosh-stemcell/version-9999.x \ + -v stemcell_version_semver_bump=minor +``` +1. Using the version of the published stemcell, add some variables to the `ci/os-image/configure.sh` +``` + -v branch=9999.x +``` +1. Update the `configure.sh` scripts to create `bosh:os-image:9999.x` and `bosh:stemcell:9999.x` pipelines. 1. Log in to the `bosh core os images stemcells` AWS account. Go into the `bosh-core-stemcells-candidate` bucket, then the `bosh-stemcell` folder. -1. Locally, `echo -n 9999.0.0 > version-9999.x`. Upload that file. (We do this because the file cannot contain newlines.) +1. Update `initial_version` value for the `version` semver resource in `ci/pipeline.yml` and update it to `9999.0.0` 1. Push changes to the branch. 1. Run the configure scripts: `ci/configure.sh` & `ci/os-images/configure.sh` 1. That creates os-image and stemcell pipelines; check them to make sure that they're pointing to the right repos, branches, and version file. @@ -45,4 +48,4 @@ * [spreadsheet with context, links, and directions](https://docs.google.com/spreadsheets/d/11LgvmuR-XxXpKB-UVi91FL0nkITGhoB-G1NHPwfnweo/edit#gid=0) - not open to everyone, probably * [BOSH DavCLI Repo](https://github.com/cloudfoundry/bosh-davcli) * [BOSH S3CLI Repo](https://github.com/cloudfoundry/bosh-s3cli) -* [BOSH GCSCLI Repo](https://github.com/cloudfoundry/bosh-gcscli) \ No newline at end of file +* [BOSH GCSCLI Repo](https://github.com/cloudfoundry/bosh-gcscli)