Skip to content

Commit

Permalink
Fix docker setup
Browse files Browse the repository at this point in the history
  • Loading branch information
KordonDev committed Dec 11, 2023
1 parent 519c7ad commit 9fca377
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 7 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,4 @@ vendor
.vscode

dist/
docker/data
2 changes: 1 addition & 1 deletion docker/configuration
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
debug: false
domain: localhost
origin: http://localhost:1080
databaseConnection: ./equipment-watchdog.db
databaseConnection: /data/equipment-watchdog.db
jwtSecret: changeMe
8 changes: 4 additions & 4 deletions docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@ version: '3.6'

services:
backend:
image: ghcr.io/kordondev/equipment-watchdog-backend
image: ghcr.io/kordondev/equipment-watchdog-backend:0.0.10-arm64
container_name: equipment-watchdog-backend
ports:
- "8080:8080"
volumes:
- ./configuration:/configuration:ro
- ./equipment-watchdog.db:/equipment-watchdog.db
- ./configuration:/equipment-watchdog/configuration:ro
- ./data:/data
restart: always

frontend:
Expand All @@ -18,4 +18,4 @@ services:
ports:
- "1080:80"
environment:
- URL=http://localhost:8080
- URL=http://localhost:8080/api
2 changes: 1 addition & 1 deletion frontend/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ ADD docker/nginx.conf /etc/nginx/nginx.conf
WORKDIR /var/www

COPY --from=build /var/frontend/dist /var/www
COPY docker/entrypoint.sh /entrypoint.sh
ADD docker/entrypoint.sh /entrypoint.sh
RUN chmod -R 777 /entrypoint.sh

CMD ["/entrypoint.sh"]
2 changes: 1 addition & 1 deletion frontend/docker/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/sh

echo $URL
sed -i "s/.*BASE_URL.*/window.BASE_URL=\"$(echo $URL | sed -En 's/\//\\\//pg')\";/g" /var/www/index.html
Expand Down

0 comments on commit 9fca377

Please sign in to comment.