Add Docker configuration and initial server setup for bus_running_record app
This commit is contained in:
+22
@@ -0,0 +1,22 @@
|
||||
# Build stage
|
||||
FROM cirrusci/flutter:latest AS builder
|
||||
|
||||
WORKDIR /app
|
||||
COPY pubspec.* ./
|
||||
COPY lib ./lib
|
||||
COPY web ./web
|
||||
COPY assets ./assets
|
||||
|
||||
RUN flutter pub get
|
||||
RUN flutter build web --release
|
||||
|
||||
# Serve stage
|
||||
FROM nginx:alpine
|
||||
|
||||
COPY --from=builder /app/build/web /usr/share/nginx/html
|
||||
|
||||
COPY nginx.conf /etc/nginx/nginx.conf
|
||||
|
||||
EXPOSE 80
|
||||
|
||||
CMD ["nginx", "-g", "daemon off;"]
|
||||
Reference in New Issue
Block a user