Skip to content

Commit

Permalink
feat(packer): Update version to support AWS assume_role (#764)
Browse files Browse the repository at this point in the history
Co-authored-by: Cameron Motevasselani <cmotevasselani@gmail.com>
  • Loading branch information
karlskewes and link108 committed Feb 9, 2021
1 parent 5a60bef commit 0a10984
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 10 deletions.
11 changes: 7 additions & 4 deletions Dockerfile.slim
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
FROM alpine:3.12
LABEL maintainer="sig-platform@spinnaker.io"

ENV KUSTOMIZE_VERSION=3.8.5
ENV PACKER_VERSION=1.6.6

WORKDIR /packer

RUN apk --no-cache add --update bash wget curl openssl openjdk11-jre git openssh-client && \
wget https://releases.hashicorp.com/packer/1.4.5/packer_1.4.5_linux_amd64.zip && \
unzip packer_1.4.5_linux_amd64.zip && \
rm packer_1.4.5_linux_amd64.zip
wget https://releases.hashicorp.com/packer/${PACKER_VERSION}/packer_${PACKER_VERSION}_linux_amd64.zip && \
unzip packer_${PACKER_VERSION}_linux_amd64.zip && \
rm packer_${PACKER_VERSION}_linux_amd64.zip

ENV PATH "/packer:$PATH"

Expand All @@ -24,7 +27,7 @@ RUN wget https://raw.githubusercontent.com/kubernetes/helm/master/scripts/get &&
rm get

RUN mkdir kustomize && \
curl -s -L https://github.com/kubernetes-sigs/kustomize/releases/download/kustomize/v3.8.1/kustomize_v3.8.1_linux_amd64.tar.gz|\
curl -s -L https://github.com/kubernetes-sigs/kustomize/releases/download/kustomize/v${KUSTOMIZE_VERSION}/kustomize_v${KUSTOMIZE_VERSION}_linux_amd64.tar.gz|\
tar xvz -C kustomize/

ENV PATH "kustomize:$PATH"
Expand Down
11 changes: 7 additions & 4 deletions Dockerfile.ubuntu
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
FROM ubuntu:bionic
LABEL maintainer="sig-platform@spinnaker.io"

ENV KUSTOMIZE_VERSION=3.8.5
ENV PACKER_VERSION=1.6.6

WORKDIR /packer

RUN apt-get update && apt-get -y install openjdk-11-jre-headless wget unzip curl git openssh-client && \
wget https://releases.hashicorp.com/packer/1.4.5/packer_1.4.5_linux_amd64.zip && \
unzip packer_1.4.5_linux_amd64.zip && \
rm packer_1.4.5_linux_amd64.zip
wget https://releases.hashicorp.com/packer/${PACKER_VERSION}/packer_${PACKER_VERSION}_linux_amd64.zip && \
unzip packer_${PACKER_VERSION}_linux_amd64.zip && \
rm packer_${PACKER_VERSION}_linux_amd64.zip

ENV PATH "/packer:$PATH"

Expand All @@ -24,7 +27,7 @@ RUN wget https://raw.githubusercontent.com/kubernetes/helm/master/scripts/get &&
rm get

RUN mkdir kustomize && \
curl -s -L https://github.com/kubernetes-sigs/kustomize/releases/download/kustomize/v3.8.1/kustomize_v3.8.1_linux_amd64.tar.gz|\
curl -s -L https://github.com/kubernetes-sigs/kustomize/releases/download/kustomize/v${KUSTOMIZE_VERSION}/kustomize_v${KUSTOMIZE_VERSION}_linux_amd64.tar.gz|\
tar xvz -C kustomize/

ENV PATH "kustomize:$PATH"
Expand Down
2 changes: 1 addition & 1 deletion halconfig/packer/aws-windows-2012-r2.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@

"source_ami": "{{user `aws_source_ami`}}",

"ami_name": "{{user `aws_target_ami` | clean_ami_name}}",
"ami_name": "{{user `aws_target_ami` | clean_resource_name}}",

"associate_public_ip_address": "{{user `aws_associate_public_ip_address`}}",

Expand Down
2 changes: 1 addition & 1 deletion rosco-web/pkg_scripts/postInstall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ if [ -z `getent passwd spinnaker` ]; then
fi

install_packer() {
PACKER_VERSION="1.4.5"
PACKER_VERSION="1.6.6"
local packer_version=$(/usr/bin/packer --version)
local packer_status=$?
if [ $packer_status -ne 0 ] || [ "$packer_version" != "$PACKER_VERSION" ]; then
Expand Down

0 comments on commit 0a10984

Please sign in to comment.