Skip to content

Commit 39b4a18

Browse files
author
Alexander Patrikalakis
committed
[skip ci] Use AL2 in CloudFormation script (fixes amazon-archives#279)
1 parent 9272131 commit 39b4a18

File tree

2 files changed

+42
-52
lines changed

2 files changed

+42
-52
lines changed

dynamodb-janusgraph-storage-backend-cfn.yaml

+39-49
Original file line numberDiff line numberDiff line change
@@ -2,61 +2,55 @@
22
Description: This stack creates a VPC, an EC2 Amazon Linux host in the VPC with a
33
Public IP, and deploys Gremlin Server on it. **WARNING** This template creates
44
an Amazon EC2 instance. You will be billed for the AWS resources used if you
5-
create a stack from this template.
5+
create a stack from this template. Uses 2018-06-22 AL2 and HVM virts only.
66
AWSTemplateFormatVersion: '2010-09-09'
77
Mappings:
88
AWSRegionArch2AMI:
9-
ap-south-1:
10-
HVMG2: ami-52c7b43d
11-
HVM64: ami-f5c6b59a
12-
eu-west-2:
13-
HVMG2: ami-b6daced2
14-
HVM64: ami-b7daced3
15-
eu-west-1:
16-
HVMG2: ami-01ccc867
17-
PV64: ami-d1c0c4b7
18-
HVM64: ami-d3c0c4b5
19-
ap-northeast-2:
20-
HVM64: ami-9a15c7f4
21-
HVMG2: ami-9d15c7f3
229
ap-northeast-1:
23-
PV64: ami-30391657
24-
HVM64: ami-6a3b140d
25-
HVMG2: ami-923d12f5
26-
sa-east-1:
27-
HVM64: ami-2bccae47
28-
PV64: ami-36cfad5a
29-
HVMG2: ami-37cfad5b
30-
ca-central-1:
31-
HVMG2: ami-0bd66a6f
32-
HVM64: ami-73d06c17
10+
HVMG2: ami-e99f4896
11+
HVM64: ami-ef9e4990
12+
ap-northeast-2:
13+
HVM64: ami-66c67308
14+
HVMG2: ami-afd86dc1
15+
ap-south-1:
16+
HVM64: ami-cf82a8a0
17+
HVMG2: ami-d783a9b8
3318
ap-southeast-1:
34-
PV64: ami-ab5ce5c8
35-
HVM64: ami-b65de4d5
36-
HVMG2: ami-fc5ae39f
19+
HVMG2: ami-05868579
20+
HVM64: ami-838685ff
3721
ap-southeast-2:
38-
HVMG2: ami-162c2575
39-
HVM64: ami-762a2315
40-
PV64: ami-af2128cc
22+
HVMG2: ami-39f8215b
23+
HVM64: ami-7bf82119
24+
ca-central-1:
25+
HVMG2: ami-0ee86a6a
26+
HVM64: ami-72e96b16
4127
eu-central-1:
42-
HVM64: ami-506fbd3f
43-
HVMG2: ami-b968bad6
44-
PV64: ami-ba68bad5
28+
HVMG2: ami-7c4f7097
29+
HVM64: ami-e2526d09
30+
eu-west-1:
31+
HVMG2: ami-466768ac
32+
HVM64: ami-776a659d
33+
eu-west-2:
34+
HVM64: ami-a4b950c3
35+
HVMG2: ami-b8b45ddf
36+
eu-west-3:
37+
HVM64: ami-2af54557
38+
HVMG2: ami-2cf54551
39+
sa-east-1:
40+
HVMG2: ami-6dca9001
41+
HVM64: ami-a3c892cf
4542
us-east-1:
46-
PV64: ami-668f1e70
47-
HVMG2: ami-c58c1dd3
48-
HVM64: ami-fd8617eb
43+
HVM64: ami-7105540e
44+
HVMG2: ami-b70554c8
4945
us-east-2:
50-
HVMG2: ami-4191b524
51-
HVM64: ami-6693b703
46+
HVMG2: ami-8c122be9
47+
HVM64: ami-d80c35bd
5248
us-west-1:
53-
PV64: ami-0f85a06f
54-
HVMG2: ami-7a85a01a
55-
HVM64: ami-f887a298
49+
HVM64: ami-57876134
50+
HVMG2: ami-e0ba5c83
5651
us-west-2:
57-
HVM64: ami-3234a652
58-
HVMG2: ami-4836a428
59-
PV64: ami-c737a5a7
52+
HVMG2: ami-a9d09ed1
53+
HVM64: ami-bdd09ec5
6054
AWSInstanceType2Arch:
6155
t2.nano:
6256
Arch: HVM64
@@ -562,11 +556,7 @@ Resources:
562556
- - "#!/bin/bash\n"
563557
- "export SDKMAN_DIR=/usr/local/sdkman && curl -s https://get.sdkman.io | bash && source /usr/local/sdkman/bin/sdkman-init.sh\n"
564558
- "echo 'export SDKMAN_DIR=/usr/local/sdkman; source /usr/local/sdkman/bin/sdkman-init.sh' > /etc/profile.d/sdkman.sh\n"
565-
- "yum update -y -q -e 0 && yum upgrade -y -q -e 0 && yum install -y java-1.8.0-openjdk > /home/ec2-user/yumupdates.log\n"
566-
- "yum remove -y java-1.7.0-openjdk > /home/ec2-user/yumremovejava7.log\n"
567-
- "java -version > /home/ec2-user/java-version-before-sdkmvn.log\n"
568-
- "sdk install java < /dev/null\n"
569-
- "sdk current java > /home/ec2-user/java-version-from-sdkman.log\n"
559+
- "yum update -y -q -e 0 && yum upgrade -y -q -e 0 && yum install -y -q java-1.8.0-openjdk-devel wget gpg zip unzip > /home/ec2-user/yumupdates.log\n"
570560
- "sdk install maven < /dev/null && set -x\n"
571561
- "mvn -version > /home/ec2-user/maven-installation-settings.log\n"
572562
- "export GREMLIN_SERVER_USERNAME='ec2-user'\n"

src/test/resources/get-recent-al-amis.sh

+3-3
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,13 @@
1717

1818
LATER_THAN_DATE=$1
1919

20-
aws ec2 describe-regions --query 'Regions[*].[RegionName]' | sed -e '/\[/d' -e '/\]/d' -e "s/^[ \t]*//" | sed 's/\"//g' | while read region; do
20+
aws ec2 describe-regions --query 'Regions[*].[RegionName]' | sed -e '/\[/d' -e '/\]/d' -e "s/^[ \t]*//" | sed 's/\"//g' | sort | while read region; do
2121
echo " ${region}:"
2222
aws ec2 describe-images \
2323
--region ${region} \
2424
--owners amazon \
25-
--filters "Name=root-device-type,Values=ebs" "Name=name,Values=amzn-ami-*" \
26-
--query 'Images[? CreationDate > `'${LATER_THAN_DATE}'` && !contains(Name, `minimal`) && !contains(Name, `nat`)].[ImageId, ImageLocation]' |\
25+
--filters "Name=root-device-type,Values=ebs" "Name=name,Values=amzn2-ami*" \
26+
--query 'Images[? CreationDate > `'${LATER_THAN_DATE}'` && !contains(Name, `minimal`) && !contains(Name, `dotnetcore`) && !contains(Name, `nat`)].[ImageId, ImageLocation]' |\
2727
grep "\"" |\
2828
sed -e 's/^[ ]*\(.*\)[ ]*$/\1/' -e '/\"$/s/$/%/' |\
2929
tr "\n" "@" |\

0 commit comments

Comments
 (0)