From b77350f90654c4b948d4d3d0108baa863a7dcb4c Mon Sep 17 00:00:00 2001 From: bansikah22 Date: Wed, 11 Sep 2024 16:53:17 +0100 Subject: [PATCH] add status badge --- README.md | 4 ++++ docker-compose.yaml | 32 ++++++++++++-------------------- 2 files changed, 16 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index 64736598..d6bfdfee 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,10 @@ # User Fullstack Application This repository contains a full-stack application with a React frontend (`user-frontend`) and a Spring Boot backend (`user-backend`). The backend provides APIs that the frontend consumes to display data and perform operations. +## Status +![Build and Deploy Frontend](https://github.com/bansikah22/user-fullstack/actions/workflows/frontend.yml/badge.svg) +![Build and Deploy Backend](https://github.com/bansikah22/user-fullstack/actions/workflows/backend.yml/badge.svg) + ## Getting Started diff --git a/docker-compose.yaml b/docker-compose.yaml index 9ee0f00f..bdc889b5 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,38 +1,30 @@ -version: '3.8' +version: "3.8" services: traefik: image: traefik:v3.0 command: - - "--configFile=/etc/traefik/traefik.yml" + - "--api.insecure=true" + - "--providers.docker=true" + - "--entrypoints.web.address=:80" ports: - - "80:80" - - "8080:8080" + - "80:80" # Expose HTTP + - "8080:8080" # Expose Traefik dashboard volumes: - #- "./traefik.yml:/etc/traefik/traefik.yml:rw" - - "/var/run/docker.sock:/var/run/docker.sock:rw" - networks: - - web + - "/var/run/docker.sock:/var/run/docker.sock:ro" # Allow Traefik to listen to Docker events - frontend: + user-frontend: image: user-frontend:1.0 labels: - "traefik.enable=true" - "traefik.http.routers.frontend.rule=Host(`frontend.localhost`)" - - "traefik.http.services.frontend.loadbalancer.server.port=3001" - networks: - - web + - "traefik.http.services.frontend.loadbalancer.server.port=80" + depends_on: + - user-backend - backend: + user-backend: image: user-backend:1.0 labels: - "traefik.enable=true" - "traefik.http.routers.backend.rule=Host(`backend.localhost`)" - "traefik.http.services.backend.loadbalancer.server.port=8082" - networks: - - web - -networks: - web: - external: true -