-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
rhcos: Embed full build metadata in binary, add override envvar
This way we avoid needing a service available at least for AWS installs. The AMIs now get hardcoded into the binary. Further, in order to make it easier for developers to test alternative builds of RHCOS, add an override environment variable just like is available for the release payload. `hack/update-rhcos-bootimage.py` is a small script which accepts a URL to build metadata and updates our cached version with just the subset of keys we care about (or potentially care about); e.g. not the pkgdiff.
- Loading branch information
Showing
7 changed files
with
178 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
{ | ||
"amis": [ | ||
{ | ||
"hvm": "ami-088e16048b7067a11", | ||
"name": "ap-northeast-1" | ||
}, | ||
{ | ||
"hvm": "ami-02d307be73b793f42", | ||
"name": "ap-northeast-2" | ||
}, | ||
{ | ||
"hvm": "ami-0af24a18980d2d990", | ||
"name": "ap-south-1" | ||
}, | ||
{ | ||
"hvm": "ami-0bda8cde9fb69a545", | ||
"name": "ap-southeast-1" | ||
}, | ||
{ | ||
"hvm": "ami-00e1827fc950fb38c", | ||
"name": "ap-southeast-2" | ||
}, | ||
{ | ||
"hvm": "ami-02047f83d438def3e", | ||
"name": "ca-central-1" | ||
}, | ||
{ | ||
"hvm": "ami-0472155d9fea5056f", | ||
"name": "eu-central-1" | ||
}, | ||
{ | ||
"hvm": "ami-08b6d57cc42948927", | ||
"name": "eu-west-1" | ||
}, | ||
{ | ||
"hvm": "ami-0ed12e3715aee7cdb", | ||
"name": "eu-west-2" | ||
}, | ||
{ | ||
"hvm": "ami-036e9773fa7520f7b", | ||
"name": "eu-west-3" | ||
}, | ||
{ | ||
"hvm": "ami-0218529bb6b2a7b6a", | ||
"name": "sa-east-1" | ||
}, | ||
{ | ||
"hvm": "ami-0e6248dbf1f9e164c", | ||
"name": "us-east-1" | ||
}, | ||
{ | ||
"hvm": "ami-026d285b42705e30e", | ||
"name": "us-east-2" | ||
}, | ||
{ | ||
"hvm": "ami-0646b7bd4b7771505", | ||
"name": "us-west-1" | ||
}, | ||
{ | ||
"hvm": "ami-06d3e0b5f0d941b0e", | ||
"name": "us-west-2" | ||
} | ||
], | ||
"images": { | ||
"openstack": { | ||
"path": "rhcos-maipo-400.7.20190306.0-openstack.qcow2.gz", | ||
"sha256": "20c8e556958d49f0baf2ef9dfbc8bc98066219a4c5fceabdfe2faa95f8ba7854", | ||
"uncompressed-sha256": "ac3acb54327724560dbf882537f02c9c9d54feaf97820325e60fed5a4c775443" | ||
}, | ||
"qemu": { | ||
"path": "rhcos-maipo-400.7.20190306.0-qemu.qcow2.gz", | ||
"sha256": "2b662fc001eb026c2ba54a98c2b167c3da3a50ddb4a833dbc6299ea1230d331d", | ||
"uncompressed-sha256": "e4ee475ec31243424f1e7bc61ef0bd9dcfe9a9817d8fa05d0e7dd072d9d3b60a" | ||
} | ||
}, | ||
"buildid": "400.7.20190306.0", | ||
"oscontainer": { | ||
"digest": "sha256:c09f455cc09673a1a13ae7b54cc4348cda0411e06dfa79ecd0130b35d62e8670", | ||
"image": "docker-registry-default.cloud.registry.upshift.redhat.com/redhat-coreos/maipo" | ||
}, | ||
"ostree-commit": "109ec0b9b06e5070a4aec54370fa3787d8ec414d0860cb596771cc585899f2f2", | ||
"ostree-version": "400.7.20190306.0" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#!/usr/bin/python3 | ||
import os,sys,json,argparse | ||
import urllib.request | ||
|
||
dn = os.path.abspath(os.path.dirname(sys.argv[0])) | ||
|
||
parser = argparse.ArgumentParser() | ||
parser.add_argument("meta", action='store') | ||
args = parser.parse_args() | ||
|
||
with urllib.request.urlopen(args.meta) as f: | ||
meta = json.load(f) | ||
newmeta = {} | ||
for k in ['amis', 'images', 'buildid', 'oscontainer', | ||
'ostree-commit', 'ostree-version']: | ||
newmeta[k] = meta[k] | ||
with open(os.path.join(dn, "../data/data/rhcos.json"), 'w') as f: | ||
json.dump(newmeta, f, indent=4) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters