diff --git a/.gitignore b/.gitignore index af8e66d..776c019 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,6 @@ # Ignore packer manifest packer-manifest.json +govcloud-packer-manifest.json snippet-*.json *.pkrvars.json diff --git a/packer/gen-native-images.sh b/packer/gen-native-images.sh index f5b61ca..a664a19 100755 --- a/packer/gen-native-images.sh +++ b/packer/gen-native-images.sh @@ -39,7 +39,8 @@ do ')" arch="amd64" - [ "${name/arm64/}" != "arm64" ] && arch="arm64" + [ "${name/arm64/}" != $name ] && arch="arm64" + nicename="${nicename/-arm64/ (arm64)}" echo " $nicename images:" @@ -99,7 +100,8 @@ done echo "[$json ]" >snippet-temp.json -jq '. | map(select(.Name == "Docker-Duplo-Oregon-Ubuntu22") | .Name = "Docker-Duplo") + .' snippet-NativeImages.json +jq '. | map(select(.Name == "Docker-Duplo-Oregon-Ubuntu22" and .Arch == "amd64") | .Name = "Docker-Duplo") + .' snippet-temp2.json +jq '. | map(select(.Name == "Docker-Duplo-Oregon-Ubuntu22 (arm64)" and .Arch == "arm64") | .Name = "Docker-Duplo (arm64)") + .' snippet-NativeImages.json out "NativeImages JSON: snippet done" # Step 2 - Build a new native images JSON