diff --git a/sls/Dockerfile b/sls/Dockerfile index 87982044..20787531 100644 --- a/sls/Dockerfile +++ b/sls/Dockerfile @@ -1,13 +1,10 @@ FROM node:lts-slim -ENV SERVERLESS_VERSION=1.63.0 \ - CLOUD_SDK_VERSION=279.0.0 \ +ENV SERVERLESS_VERSION=3.27.0 \ VAULT_VERSION=1.4.3 \ AWS_CLI_VERSION=1.17.11 \ - CLOUDSDK_CORE_DISABLE_USAGE_REPORTING=true \ - PATH=$PATH:/usr/local/gcloud/google-cloud-sdk/bin:/usr/local/vault:/root/.pyenv/bin:/root/.pyenv/shims:/tfenv/bin \ - DEBIAN_FRONTEND=noninteractive \ - TFENV_VERSION=v2.0.0 + PATH=$PATH:/bin:/usr/local/vault:/root/.pyenv/bin:/root/.pyenv/shims:/tfenv/bin \ + DEBIAN_FRONTEND=noninteractive # Install dependencies and cleanup RUN apt update && \ @@ -33,20 +30,13 @@ RUN apt update && \ echo "449cf642f48d3baf88c390dc728f5d7684d05fe5ffec47b0a0586fa4dd63c404 /usr/local/bin/pyenv-installer" | sha256sum -c - && \ chmod +x /usr/local/bin/pyenv-installer && \ pyenv-installer && \ - pyenv install 3.6.10 && \ - pyenv install 3.7.6 && \ pyenv install 3.8.1 && \ - pyenv global 3.8.1 3.7.6 3.6.10 && \ + pyenv install 3.9.16 && \ + pyenv global 3.9.16 3.8.1 && \ pyenv rehash && \ pip3 install --upgrade pip && \ pip3 install --upgrade awscli==$AWS_CLI_VERSION && \ mkdir ~/.aws && \ - wget -qO- https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cloud-sdk-${CLOUD_SDK_VERSION}-linux-x86_64.tar.gz > /tmp/google-cloud-sdk.tar.gz && \ - mkdir -p /usr/local/gcloud && \ - tar -xf /tmp/google-cloud-sdk.tar.gz -C /usr/local/gcloud && \ - /usr/local/gcloud/google-cloud-sdk/install.sh && \ - git clone --branch ${TFENV_VERSION} https://github.com/tfutils/tfenv.git /tfenv && \ - tfenv install latest && tfenv install latest:^0.12.28 && \ wget -qO- https://releases.hashicorp.com/vault/${VAULT_VERSION}/vault_${VAULT_VERSION}_linux_amd64.zip > /tmp/vault-linux-amd64.zip && \ mkdir -p /usr/local/vault && \ unzip /tmp/vault-linux-amd64.zip -d /usr/local/vault && \ @@ -57,10 +47,7 @@ RUN apt update && \ find /root/.pyenv/versions -type f '(' -name '*.py[co]' -o -name '*.exe' ')' -exec rm -fv '{}' && + || true # Install gcloud beta and serverless CLI -RUN gcloud components update && \ - gcloud components install beta && \ - npm config set unsafe-perm true && \ - npm install -g serverless@$SERVERLESS_VERSION +RUN npm install -g serverless@$SERVERLESS_VERSION LABEL name=sls version=$SERVERLESS_VERSION \ - maintainer="Dražen Perić " + maintainer="Jurica Grgicevic "