Added Dockerfile and changed baseUrl to current deployment
This commit is contained in:
27
backend_splatournament_manager/Dockerfile
Normal file
27
backend_splatournament_manager/Dockerfile
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
FROM node:lts-alpine AS build
|
||||||
|
|
||||||
|
WORKDIR /usr/src/app
|
||||||
|
|
||||||
|
# Copy package.json
|
||||||
|
COPY package.json ./
|
||||||
|
|
||||||
|
# Install dependencies
|
||||||
|
RUN yarn install --production
|
||||||
|
|
||||||
|
# Copy all files
|
||||||
|
COPY . .
|
||||||
|
|
||||||
|
RUN yarn run build
|
||||||
|
|
||||||
|
FROM node:lts-alpine
|
||||||
|
WORKDIR /usr/src/app
|
||||||
|
|
||||||
|
COPY package.json ./
|
||||||
|
COPY --from=build /usr/src/app/dist ./dist
|
||||||
|
|
||||||
|
RUN yarn install --production
|
||||||
|
# Expose port 3000
|
||||||
|
EXPOSE 3000
|
||||||
|
|
||||||
|
# Run app
|
||||||
|
CMD [ "node", "dist/app.js" ]
|
||||||
@@ -27,7 +27,7 @@ void main() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
class SplatournamentApp extends StatelessWidget {
|
class SplatournamentApp extends StatelessWidget {
|
||||||
static const String baseUrl = "http://10.0.2.2:3000";
|
static const String baseUrl = "https://kaintim.duckdns.org/splatournament-backend";
|
||||||
const SplatournamentApp({super.key});
|
const SplatournamentApp({super.key});
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
|
|||||||
Reference in New Issue
Block a user