install play wrigth
This commit is contained in:
parent
fd4feccc41
commit
3f51cf48e8
@ -6,15 +6,12 @@ RUN apt update && apt install git
|
|||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
COPY . .
|
COPY . .
|
||||||
RUN go mod tidy
|
RUN go mod tidy
|
||||||
|
RUN go run github.com/playwright-community/playwright-go/cmd/playwright@v0.4802.0 install --with-deps
|
||||||
# https://stackoverflow.com/questions/70369368/check-architecture-in-dockerfile-to-get-amd-arm
|
# https://stackoverflow.com/questions/70369368/check-architecture-in-dockerfile-to-get-amd-arm
|
||||||
RUN go build -o bin/crawler \
|
RUN go build -o bin/crawler \
|
||||||
-ldflags "-X main.Shortsha=${SHORTSHA} \
|
-ldflags "-X main.Shortsha=${SHORTSHA} \
|
||||||
-X main.Version=${version} \
|
-X main.Version=${version} \
|
||||||
-X main.Aarch=${TARGETARCH}" ./cmd/crawler/main.go
|
-X main.Aarch=${TARGETARCH}" ./cmd/crawler/main.go
|
||||||
|
COPY /app/bin/crawler /usr/bin/
|
||||||
FROM mcr.microsoft.com/playwright
|
|
||||||
#FROM alpine AS runner
|
|
||||||
COPY --from=builder /app/bin/crawler /usr/bin/
|
|
||||||
WORKDIR /app
|
|
||||||
ENTRYPOINT /usr/bin/crawler
|
ENTRYPOINT /usr/bin/crawler
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user