13 Commits

Author SHA1 Message Date
b79b354fdc Merge branch 'hotfix/2.21.3' into develop 2026-01-09 19:42:14 +01:00
a428a77eb1 (ver) web-app: version bump 2026-01-09 19:42:06 +01:00
16eaa5bfa1 (bugfix) Fix hosts file configuration by using extra_hosts at runtime
Docker overwrites /etc/hosts at container runtime, so copying it during
build (COPY command) or mounting it as volume doesn't work reliably.
Moved to extra_hosts in docker-compose files for both standalone and
swarm deployments.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-09 19:41:33 +01:00
2cff1ec18b Merge branch 'release/2.21.2'
All checks were successful
Build and Push Docker Image / build_web_app__check_image_version (push) Successful in 14s
Build and Push Docker Image / build_web_app (push) Successful in 5m57s
2026-01-09 19:18:29 +01:00
3366e85950 Merge branch 'feature/hotfix-hosts-file' into develop 2026-01-09 19:17:58 +01:00
5cb0210668 (ver) web-app: version bump 2026-01-09 19:17:53 +01:00
2ddff15497 (bugfix) Dockerfile: hosts file was copied in wrong step 2026-01-09 19:17:31 +01:00
0492469ed6 (refactor) dockerfile: modified default port 2026-01-09 19:17:01 +01:00
0ecae68c63 Merge branch 'release/2.21.1'
All checks were successful
Build and Push Docker Image / build_web_app__check_image_version (push) Successful in 15s
Build and Push Docker Image / build_web_app (push) Successful in 6m6s
2026-01-09 18:52:07 +01:00
42d1f6276a Merge branch 'feature/fixing-deploy-path' into develop 2026-01-09 18:51:48 +01:00
d17efdc156 (ver) web-app: version bump 2026-01-09 18:51:40 +01:00
de97ce744f (refactor) Move hosts file copy from volume mount to Dockerfile
Bake the custom hosts file into the Docker image instead of mounting it as a volume. This simplifies deployment configuration and makes the image more self-contained.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-09 18:51:05 +01:00
c9cc32b811 (config) Convert docker-compose paths to absolute for Portainer compatibility
Changed relative volume paths to absolute paths and updated image reference to use full registry path. This enables deployment via Portainer which doesn't have working directory context.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-09 18:49:00 +01:00
5 changed files with 18 additions and 22 deletions

View File

@@ -13,12 +13,15 @@ networks:
services:
web-app:
image: utility-bills-tracker:${IMAGE_VERSION}
image: registry.budakova.org/knee-cola/utility-bills-tracker:${IMAGE_VERSION}
networks:
- traefik-network
- util-bills-mongo-network
volumes:
- ./web-app/etc/hosts/:/etc/hosts
# NextJS will do name resolution for `rezije.app` and will crash if it
# resolves to an IP adress different from the one assigned to the Docker container.
# This will prevent that from happening.
extra_hosts:
- "rezije.app:0.0.0.0"
environment:
MONGODB_URI: mongodb://rezije.app:w4z4piJBgCdAm4tpawqB@mongo:27017/utility-bills
GOOGLE_ID: 355397364527-adjrokm6hromcaaar0qfhk050mfr35ou.apps.googleusercontent.com
@@ -28,7 +31,7 @@ services:
LINKEDIN_SECRET: ugf61aJ2iyErLK40
HOSTNAME: rezije.app # IP address at which the server will be listening (0.0.0.0 = listen on all addresses)
NEXTAUTH_URL: https://rezije.app # URL next-auth will use while redirecting user during authentication (if not set - will use HOSTNAME)
PORT: ${PORT:-80}
PORT: ${PORT:-3000}
# Share link security
SHARE_LINK_SECRET: ef68362357315d5decb27d24ff9abdb4a02a3351cd2899f79bf238dce0fe08c5
SHARE_TTL_INITIAL_DAYS: 10
@@ -43,7 +46,7 @@ services:
labels:
- traefik.enable=true
- traefik.docker.network=traefik-network # mreže preko koje ide komunikacija sa Traefikom
- traefik.http.services.web-app.loadbalancer.server.port=80
- traefik.http.services.web-app.loadbalancer.server.port=3000
- traefik.http.routers.web-app.entrypoints=http
- traefik.http.routers.web-app.rule=Host(`${FQDN:-rezije.app}`)
@@ -55,8 +58,8 @@ services:
MONGO_INITDB_ROOT_USERNAME: root
MONGO_INITDB_ROOT_PASSWORD: example
volumes:
- ./mongo-volume:/data/db
- ./mongo-backup:/backup
- /home/knee-cola/docker/evidencija-rezija/mongo-volume:/data/db
- /home/knee-cola/docker/evidencija-rezija/mongo-backup:/backup
networks:
- util-bills-mongo-network
mongo-express:

View File

@@ -17,8 +17,11 @@ services:
networks:
- traefik-network
- util-bills-mongo-network
volumes:
- ./web-app/etc/hosts/:/etc/hosts
# NextJS will do name resolution for `rezije.app` and will crash if it
# resolves to an IP adress different from the one assigned to the Docker container.
# This will prevent that from happening.
extra_hosts:
- "rezije.app:0.0.0.0"
environment:
MONGODB_URI: mongodb://rezije.app:w4z4piJBgCdAm4tpawqB@mongo:27017/utility-bills
GOOGLE_ID: 355397364527-adjrokm6hromcaaar0qfhk050mfr35ou.apps.googleusercontent.com

View File

@@ -1,10 +0,0 @@
127.0.0.1 localhost
::1 localhost ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
# NextJS will do name resolution for `rezije.app` and will crash if it
# resolves to an IP adress different from the one assigned to the Docker container.
# This will prevent that from happening.
0.0.0.0 rezije.app

View File

@@ -1,11 +1,11 @@
{
"name": "evidencija-rezija",
"version": "2.21.0",
"version": "2.21.3",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"version": "2.21.0",
"version": "2.21.3",
"dependencies": {
"@emotion/react": "^11.14.0",
"@emotion/styled": "^11.14.1",

View File

@@ -58,5 +58,5 @@
"engines": {
"node": ">=18.17.0"
},
"version": "2.21.0"
"version": "2.21.3"
}