1
0
mirror of https://github.com/ebosas/microservices.git synced 2025-06-24 22:26:56 +02:00

Using images from ECR

This commit is contained in:
ebosas
2021-11-02 19:06:39 +02:00
parent 45aef82cf9
commit 26eb161a24
4 changed files with 8 additions and 3 deletions

View File

@ -1,9 +1,11 @@
FROM golang:1.17-alpine AS backend
# FROM golang:1.17-alpine AS backend
# AWS CodeBuild fails due to Docker's pull rate limit.
FROM public.ecr.aws/bitnami/golang:1.17 AS backend
WORKDIR /go/src/app
COPY go.* .
COPY go.* ./
COPY internal ./internal
RUN go mod download
COPY cmd/backend .
COPY cmd/backend ./
RUN CGO_ENABLED=0 GOOS=linux go build -ldflags '-s' -o backend .
FROM scratch

View File

@ -1,4 +1,5 @@
# FROM golang:1.17-alpine AS cache
# AWS CodeBuild fails due to Docker's pull rate limit.
FROM public.ecr.aws/bitnami/golang:1.17 AS cache
WORKDIR /go/src/app
COPY go.* ./

View File

@ -1,4 +1,5 @@
# FROM golang:1.17-alpine AS database
# AWS CodeBuild fails due to Docker's pull rate limit.
FROM public.ecr.aws/bitnami/golang:1.17 AS database
WORKDIR /go/src/app
COPY go.* ./

View File

@ -1,4 +1,5 @@
# FROM node:14-alpine AS react
# AWS CodeBuild fails due to Docker's pull rate limit.
FROM public.ecr.aws/bitnami/node:16 AS react
WORKDIR /usr/src/app
COPY web/react/package*.json ./