David Li commited on
Commit
ad12618
·
1 Parent(s): b03b249

fix: dart off server

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -8
Dockerfile CHANGED
@@ -2,16 +2,14 @@ FROM dart:2.19.1 as builder
2
  WORKDIR /app
3
  COPY pubspec.yaml pubspec.lock ./
4
  RUN dart pub get
5
- RUN mkdir -p /dart/bin/dart_off_server
6
  COPY . .
7
- RUN dart compile exe bin/cli.dart -o /dart/bin/dart_off_server
8
 
9
  # copy server file to basic image to run the app
10
- FROM alpine:latest
 
11
  RUN apk add --no-cache bash
12
- RUN mkdir -p /dart/bin
13
- COPY --from=builder /dart/bin/dart_off_server /dart/bin/dart_off_server
14
  RUN ls -la
15
- RUN ls /dart/bin
16
- RUN pwd /dart/bin
17
- CMD ["/dart/bin/dart_off_server"]
 
2
  WORKDIR /app
3
  COPY pubspec.yaml pubspec.lock ./
4
  RUN dart pub get
 
5
  COPY . .
6
+ RUN dart compile exe bin/cli.dart -o /app/dart_off_server
7
 
8
  # copy server file to basic image to run the app
9
+ FROM ubuntu:latest
10
+ WORKDIR /app
11
  RUN apk add --no-cache bash
12
+ COPY --from=builder /app/dart_off_server /app/dart_off_server
 
13
  RUN ls -la
14
+ RUN pwd
15
+ CMD ["/app/dart_off_server"]