github.com/hazelops/ize@v1.1.12-0.20230915191306-97d7c0e48f11/examples/ecs-apps-monorepo/apps/squibby/Dockerfile-console (about) 1 FROM golang:1.12-alpine as builder 2 ARG VERSION=2.3.930.0 3 RUN set -ex && apk add --no-cache make git gcc libc-dev curl bash && \ 4 curl -sLO https://github.com/aws/amazon-ssm-agent/archive/${VERSION}.tar.gz && \ 5 mkdir -p /go/src/github.com && \ 6 tar xzf ${VERSION}.tar.gz && \ 7 mv amazon-ssm-agent-${VERSION} /go/src/github.com/amazon-ssm-agent && \ 8 cd /go/src/github.com/amazon-ssm-agent && \ 9 echo ${VERSION} > VERSION && \ 10 gofmt -w agent && make checkstyle || ./Tools/bin/goimports -w agent && \ 11 make build-linux 12 13 FROM python:3.7-alpine 14 15 ARG PROJECT_PATH=. 16 ENV \ 17 APP_HOME=/app \ 18 PORT=3000 \ 19 APP_NAME=Default 20 21 # Adding ssm 22 RUN set -ex && apk add --no-cache sudo ca-certificates && \ 23 adduser -D ssm-user && echo "ssm-user ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/ssm-agent-users && \ 24 mkdir -p /etc/amazon/ssm 25 COPY --from=builder /go/src/github.com/amazon-ssm-agent/bin/linux_amd64/ /usr/bin 26 COPY --from=builder /go/src/github.com/amazon-ssm-agent/bin/amazon-ssm-agent.json.template /etc/amazon/ssm/amazon-ssm-agent.json 27 COPY --from=builder /go/src/github.com/amazon-ssm-agent/bin/seelog_unix.xml /etc/amazon/ssm/seelog.xml 28 COPY ${PROJECT_PATH}/entrypoint.sh /usr/bin/entrypoint.sh 29 RUN chmod +x /usr/bin/entrypoint.sh 30 31 # App 32 WORKDIR $APP_HOME 33 RUN set -ex && \ 34 apk add --no-cache \ 35 python3 \ 36 bash \ 37 curl \ 38 && \ 39 ln -s /usr/bin/python3 /usr/bin/python 40 41 #Copy files and pipenv 42 COPY ${PROJECT_PATH}/app.py ./ 43 COPY ${PROJECT_PATH}/Pipfile* ./ 44 45 RUN python3 -m pip install pipenv 46 RUN pipenv install --deploy --system 47 48 EXPOSE $PORT 49 EXPOSE 22 50 ENTRYPOINT ["entrypoint.sh"]