mirror of https://github.com/kubernetes/kops.git
				
				
				
			removed sed hack to get AMI image
This commit is contained in:
		
							parent
							
								
									36d0fe48a2
								
							
						
					
					
						commit
						a4b58e2f6b
					
				|  | @ -54,15 +54,15 @@ Some things to note from here: | ||||||
| 
 | 
 | ||||||
| CoreOS webpage includes a "json" with the updated list of latest images: [https://coreos.com/dist/aws/aws-stable.json](https://coreos.com/dist/aws/aws-stable.json) | CoreOS webpage includes a "json" with the updated list of latest images: [https://coreos.com/dist/aws/aws-stable.json](https://coreos.com/dist/aws/aws-stable.json) | ||||||
| 
 | 
 | ||||||
| By using "jq" you can obtain the "ami" for a specific region (change the region "-" for "_" in the following command): | By using "jq" you can obtain the "ami" for a specific region | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| ```bash | ```bash | ||||||
| curl -s https://coreos.com/dist/aws/aws-stable.json|sed -r 's/-/_/g'|jq '.us_east_1.hvm'|sed -r 's/_/-/g' | curl -s https://coreos.com/dist/aws/aws-stable.json | jq -r '.["us-east-1"].hvm' | ||||||
| "ami-32705b49" | "ami-32705b49" | ||||||
| ``` | ``` | ||||||
| 
 | 
 | ||||||
| The last command will check the all "hvm" CoreOS images on us-east-1 region (us_east_1 for our command). Please, always use "hvm" images. | The last command will check the all "hvm" CoreOS images on us-east-1 region. Please, always use "hvm" images. | ||||||
| 
 | 
 | ||||||
| At the moment we created this document, our ami was: "ami-32705b49". More info about the image can be obtained by using the following "aws-cli" command: | At the moment we created this document, our ami was: "ami-32705b49". More info about the image can be obtained by using the following "aws-cli" command: | ||||||
| 
 | 
 | ||||||
|  | @ -304,4 +304,4 @@ After a brief time, your cluster will be fully deleted on AWS and you'll see the | ||||||
| Deleted cluster: "coreosbasedkopscluster.k8s.local" | Deleted cluster: "coreosbasedkopscluster.k8s.local" | ||||||
| ``` | ``` | ||||||
| 
 | 
 | ||||||
| **NOTE:** Before destroying the cluster, "really ensure" any extra security group "not created" directly by KOPS has been removed by you. Otherwise, KOPS will be unable to delete the cluster. | **NOTE:** Before destroying the cluster, "really ensure" any extra security group "not created" directly by KOPS has been removed by you. Otherwise, KOPS will be unable to delete the cluster. | ||||||
|  | @ -102,7 +102,7 @@ CoreOS has been tested enough to be considered ready for production with kops, b | ||||||
| The following steps are known: | The following steps are known: | ||||||
| 
 | 
 | ||||||
| * The latest stable CoreOS AMI can be found using: | * The latest stable CoreOS AMI can be found using: | ||||||
| ``` | ```bash | ||||||
| aws ec2 describe-images --region=us-east-1 --owner=595879546273 \ | aws ec2 describe-images --region=us-east-1 --owner=595879546273 \ | ||||||
|     --filters "Name=virtualization-type,Values=hvm" "Name=name,Values=CoreOS-stable*" \ |     --filters "Name=virtualization-type,Values=hvm" "Name=name,Values=CoreOS-stable*" \ | ||||||
|     --query 'sort_by(Images,&CreationDate)[-1].{id:ImageLocation}' |     --query 'sort_by(Images,&CreationDate)[-1].{id:ImageLocation}' | ||||||
|  | @ -110,8 +110,8 @@ aws ec2 describe-images --region=us-east-1 --owner=595879546273 \ | ||||||
| 
 | 
 | ||||||
| Also, you can obtain the "AMI ID" from CoreOS web page too. They publish their AMI's using a json file at [https://coreos.com/dist/aws/aws-stable.json](https://coreos.com/dist/aws/aws-stable.json). Using some scripting and a "json" parser (like jq) you can obtain the AMI ID from a specific availability zone: | Also, you can obtain the "AMI ID" from CoreOS web page too. They publish their AMI's using a json file at [https://coreos.com/dist/aws/aws-stable.json](https://coreos.com/dist/aws/aws-stable.json). Using some scripting and a "json" parser (like jq) you can obtain the AMI ID from a specific availability zone: | ||||||
| 
 | 
 | ||||||
| ``` | ```bash | ||||||
| curl -s https://coreos.com/dist/aws/aws-stable.json|sed -r 's/-/_/g'|jq '.us_east_1.hvm'|sed -r 's/_/-/g' | curl -s https://coreos.com/dist/aws/aws-stable.json | jq -r '.["us-east-1"].hvm' | ||||||
| "ami-32705b49" | "ami-32705b49" | ||||||
| ``` | ``` | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue