From d928c5497606f603d3019a91db6e5b5024fb20e8 Mon Sep 17 00:00:00 2001 From: Tom Kirchner Date: Thu, 23 Jul 2020 13:36:58 -0700 Subject: [PATCH] Change default variant to aws-k8s-1.17 --- BUILDING.md | 10 +++++----- Makefile.toml | 2 +- QUICKSTART.md | 10 +++++----- README.md | 4 ++-- bin/amiize.sh | 8 ++++---- sources/models/build.rs | 2 +- sources/updater/updog/src/bin/updata.rs | 6 +++--- 7 files changed, 21 insertions(+), 21 deletions(-) diff --git a/BUILDING.md b/BUILDING.md index 172768295d8..4e58c9c6118 100644 --- a/BUILDING.md +++ b/BUILDING.md @@ -53,11 +53,11 @@ The script has some assumptions about your setup, in particular that you: * have a few other common tools installed, like `jq`, `du`, and `rsync` First, decompress the images. -(Note: these filenames assume an `x86_64` architecture and `aws-k8s-1.15` [variant](README.md).) +(Note: these filenames assume an `x86_64` architecture and `aws-k8s-1.17` [variant](README.md).) ``` -lz4 -d build/latest/bottlerocket-aws-k8s-1.15-x86_64.img.lz4 && \ -lz4 -d build/latest/bottlerocket-aws-k8s-1.15-x86_64-data.img.lz4 +lz4 -d build/images/x86_64-aws-k8s-1.17/latest/bottlerocket-aws-k8s-1.17-x86_64.img.lz4 && \ +lz4 -d build/images/x86_64-aws-k8s-1.17/latest/bottlerocket-aws-k8s-1.17-x86_64-data.img.lz4 ``` Next, register an AMI: @@ -65,8 +65,8 @@ Next, register an AMI: ``` bin/amiize.sh --name YOUR-AMI-NAME-HERE \ --ssh-keypair YOUR-EC2-SSH-KEYPAIR-NAME-HERE \ - --root-image build/latest/bottlerocket-aws-k8s-1.15-x86_64.img \ - --data-image build/latest/bottlerocket-aws-k8s-1.15-x86_64-data.img \ + --root-image build/images/x86_64-aws-k8s-1.17/latest/bottlerocket-aws-k8s-1.17-x86_64.img \ + --data-image build/images/x86_64-aws-k8s-1.17/latest/bottlerocket-aws-k8s-1.17-x86_64-data.img \ --region us-west-2 \ --instance-type m3.xlarge \ --arch x86_64 \ diff --git a/Makefile.toml b/Makefile.toml index 640c8a0c8f8..bb325306a75 100644 --- a/Makefile.toml +++ b/Makefile.toml @@ -16,7 +16,7 @@ BUILDSYS_VERSION_BUILD = { script = ["git describe --always --dirty --exclude '* BUILDSYS_RELEASE_CONFIG_PATH = "${BUILDSYS_ROOT_DIR}/Release.toml" BUILDSYS_VERSION_IMAGE = { script = ["awk -F '[ =\"]+' '$1 == \"version\" {print $2}' ${BUILDSYS_RELEASE_CONFIG_PATH}"] } # This can be overridden with -e to build a different variant from the variants/ directory -BUILDSYS_VARIANT = "aws-k8s-1.15" +BUILDSYS_VARIANT = "aws-k8s-1.17" # Product name used for file and directory naming BUILDSYS_NAME = "bottlerocket" diff --git a/QUICKSTART.md b/QUICKSTART.md index 80ccd3482b7..3f0218e8a58 100644 --- a/QUICKSTART.md +++ b/QUICKSTART.md @@ -118,21 +118,21 @@ us-west-2 ``` The official AMI IDs are stored in [public SSM parameters](https://docs.aws.amazon.com/systems-manager/latest/userguide/parameter-store-public-parameters.html). -Let's say you want to use the `aws-k8s-1.15` variant for the `x86_64` architecture, and you operate in the `us-west-2` region: +Let's say you want to use the `aws-k8s-1.17` variant for the `x86_64` architecture, and you operate in the `us-west-2` region: ``` -aws ssm get-parameter --region us-west-2 --name "/aws/service/bottlerocket/aws-k8s-1.15/x86_64/latest/image_id" --query Parameter.Value --output text +aws ssm get-parameter --region us-west-2 --name "/aws/service/bottlerocket/aws-k8s-1.17/x86_64/latest/image_id" --query Parameter.Value --output text ``` If you have `jq` and would like a bit more information, try this: ``` aws ssm get-parameters --region us-west-2 \ - --names "/aws/service/bottlerocket/aws-k8s-1.15/x86_64/latest/image_id" \ - "/aws/service/bottlerocket/aws-k8s-1.15/x86_64/latest/image_version" \ + --names "/aws/service/bottlerocket/aws-k8s-1.17/x86_64/latest/image_id" \ + "/aws/service/bottlerocket/aws-k8s-1.17/x86_64/latest/image_version" \ --output json | jq -r '.Parameters | .[] | "\(.Name): \(.Value) (updated \(.LastModifiedDate | gmtime | strftime("%c")) UTC)"' ``` -You can replace the variant (`aws-k8s-1.15`) and architecture (`x86_64`) to look for other images. +You can replace the variant (`aws-k8s-1.17`) and architecture (`x86_64`) to look for other images. Supported variants and architectures are described in the [README](README.md). If you know a specific Bottlerocket version you'd like to use, you can replace `latest` with that version. diff --git a/README.md b/README.md index 0988c11d002..3df45bb8096 100644 --- a/README.md +++ b/README.md @@ -45,9 +45,9 @@ We’re excited to get early feedback and to continue working on more use cases! Bottlerocket is architected such that different cloud environments and container orchestrators can be supported in the future. A build of Bottlerocket that supports different features or integration characteristics is known as a 'variant'. The artifacts of a build will include the architecture and variant name. -For example, an `x86_64` build of the `aws-k8s-1.15` variant will produce an image named `bottlerocket-aws-k8s-1.15-x86_64--.img`. +For example, an `x86_64` build of the `aws-k8s-1.17` variant will produce an image named `bottlerocket-aws-k8s-1.17-x86_64--.img`. -Our first supported variant, `aws-k8s-1.15`, supports EKS as described above. +Our first supported variants, `aws-k8s-1.15`, `aws-k8s-1.16`, and `aws-k8s-1.17`, supports EKS as described above. ## Setup diff --git a/bin/amiize.sh b/bin/amiize.sh index fdbf9e7d317..2a10d350199 100755 --- a/bin/amiize.sh +++ b/bin/amiize.sh @@ -31,8 +31,8 @@ # Tested with the Amazon Linux AMI as worker AMI. # Example call: # bin/amiize.sh --region us-west-2 \ -# --root-image build/latest/bottlerocket-aws-k8s-1.15-x86_64.img \ -# --data-image build/latest/bottlerocket-aws-k8s-1.15-x86_64-data.img \ +# --root-image build/images/x86_64-aws-k8s-1.17/latest/bottlerocket-aws-k8s-1.17-x86_64.img \ +# --data-image build/images/x86_64-aws-k8s-1.17/latest/bottlerocket-aws-k8s-1.17-x86_64-data.img \ # --worker-ami ami-0f2176987ee50226e --ssh-keypair tjk \ # --instance-type m3.xlarge --name bottlerocket-20190918-01 --arch x86_64 \ # --user-data 'I2Nsb3VkLWNvbmZpZwpyZXBvX3VwZ3JhZGU6IG5vbmUK' @@ -389,8 +389,8 @@ if [ -n "${registered_ami}" ]; then fi # Determine the size of the images (in G, for EBS) -# 2G bottlerocket-aws-k8s-1.15-x86_64.img -# 8G bottlerocket-aws-k8s-1.15-x86_64-data.img +# 2G bottlerocket-aws-k8s-1.17-x86_64.img +# 8G bottlerocket-aws-k8s-1.17-x86_64-data.img # This is overridden by --root-volume-size and --data-volume-size if you pass those options. root_image_size=$(du --apparent-size --block-size=G "${ROOT_IMAGE}" | sed -r 's,^([0-9]+)G\t.*,\1,') if [ ! "${root_image_size}" -gt 0 ]; then diff --git a/sources/models/build.rs b/sources/models/build.rs index 193019bdb75..1c408a6bc5f 100644 --- a/sources/models/build.rs +++ b/sources/models/build.rs @@ -33,7 +33,7 @@ fn link_current_variant() { let var = "VARIANT"; println!("cargo:rerun-if-env-changed={}", var); let variant = env::var(var).unwrap_or_else(|_| { - eprintln!("For local builds, you must set the {} environment variable so we know which API model to build against. Valid values are the directories in sources/models, for example \"aws-k8s-1.15\".", var); + eprintln!("For local builds, you must set the {} environment variable so we know which API model to build against. Valid values are the directories in variants/, for example \"aws-k8s-1.17\".", var); process::exit(1); }); diff --git a/sources/updater/updog/src/bin/updata.rs b/sources/updater/updog/src/bin/updata.rs index b2dde89afe9..42b15b1ec14 100644 --- a/sources/updater/updog/src/bin/updata.rs +++ b/sources/updater/updog/src/bin/updata.rs @@ -28,7 +28,7 @@ struct AddUpdateArgs { // metadata file to create/modify file: PathBuf, - // image 'variant', eg. 'aws-k8s-1.15' + // image 'variant', eg. 'aws-k8s-1.17' #[structopt(short = "f", long = "variant")] variant: String, @@ -81,7 +81,7 @@ struct RemoveUpdateArgs { // metadata file to create/modify file: PathBuf, - // image 'variant', eg. 'aws-k8s-1.15' + // image 'variant', eg. 'aws-k8s-1.17' #[structopt(short = "l", long = "variant")] variant: String, @@ -125,7 +125,7 @@ struct WaveArgs { // metadata file to create/modify file: PathBuf, - // image 'variant', eg. 'aws-k8s-1.15' + // image 'variant', eg. 'aws-k8s-1.17' #[structopt(short = "l", long = "variant")] variant: String,