Commit 2ee4c9a2 authored by Kostis Trantzas's avatar Kostis Trantzas
Browse files

Merge branch '61-add-new-mcp-backend-project-in-docker-compose-artifacts' into 'develop'

Resolve "Add new MCP backend project in Docker Compose artifacts"

See merge request !67
parents 13bfe186 c4255d3f
Loading
Loading
Loading
Loading
Loading
+62 −8
Original line number Diff line number Diff line
@@ -86,8 +86,8 @@ services:
    logging:
      driver: "json-file"
      options:
        max-size: "200m"
        max-file: "5"    
        max-size: "400m"
        max-file: "3"    
    ports:
      - 8080:8080
      - 8443:8443
@@ -164,7 +164,7 @@ services:
    logging:
      driver: "json-file"
      options:
        max-size: "800m"
        max-size: "500m"
        max-file: "3"      
    ports:
    - 13011:13011
@@ -239,7 +239,7 @@ services:
      driver: "json-file"
      options:
        max-size: "1g"
        max-file: "3"  
        max-file: "2"  
    volumes:
    - ./repo:/root
    ports:
@@ -272,7 +272,7 @@ services:
      driver: "json-file"
      options:
        max-size: "1g"
        max-file: "3"    
        max-file: "2"    
    ports:
    - 13100:13100
    networks:
@@ -387,7 +387,7 @@ services:
  oslmcp:
    container_name: openslice-mcp
    restart: always
    profiles: ["prod"]
    profiles: ["prod", "mcp-server", "mcp"]
    build:
        context:  ../../org.etsi.osl.mcp.server/
        dockerfile: Dockerfile      
@@ -416,12 +416,66 @@ services:
    logging:
      driver: "json-file"
      options:
        max-size: "500m"
        max-size: "250m"
        max-file: "2" 
    networks:
    - front
    - back


  oslmcpbackend:
    container_name: openslice-mcp-backend
    restart: always
    profiles: ["prod", "mcp-backend", "mcp"]
    build:
      context: ../../org.etsi.osl.mcp.backend/
      dockerfile: Dockerfile
    image: labs.etsi.org:5050/osl/code/org.etsi.osl.mcp.backend:develop
    ports:
      - "11880:11880"
    environment:
      SPRING_APPLICATION_JSON: '{
        "server.forward-headers-strategy":"FRAMEWORK"
        }'

      SERVER_PORT: 11880
      SPRING_APPLICATION_NAME: osl-mcp-backend
      
      # AI Configuration
      SPRING_AI_OLLAMA_BASE_URL: http://ollama:11434 # Change the Ollama API here
      SPRING_AI_OLLAMA_CHAT_MODEL: gpt-oss:20b # Change the used model here
      SPRING_AI_OLLAMA_CHAT_TEMPERATURE: 0.5
      SPRING_AI_CHAT_SYSTEM_PROMPT: "You are an OpenSlice AI Assistant." # Customize your initial Assistant prompt
      SPRING_AI_CHAT_MAX_MESSAGES: 100
      
      # MCP Client Configuration
      SPRING_AI_MCP_CLIENT_TYPE: SYNC
      SPRING_AI_MCP_CLIENT_STREAMABLE_HTTP_CONNECTIONS_OPENSLICE_SERVER_URL: http://openslice-mcp:13015/sse
      
      # OAuth2/Keycloak Configuration
      SPRING_SECURITY_OAUTH2_RESOURCESERVER_JWT_ISSUER_URI: http://keycloak:8080/auth/realms/openslice
      SPRING_SECURITY_OAUTH2_CLIENT_PROVIDER_KEYCLOAK_ISSUER_URI: http://keycloak:8080/auth/realms/openslice
      SPRING_SECURITY_OAUTH2_CLIENT_REGISTRATION_KEYCLOAK_CLIENT_ID: osapiWebClientId
      
      # ActiveMQ Configuration
      SPRING_ACTIVEMQ_BROKER_URL: tcp://anartemis:61616?jms.watchTopicAdvisories=false
      SPRING_ACTIVEMQ_USER: artemis
      SPRING_ACTIVEMQ_PASSWORD: artemis
      
      # Logging Configuration
      LOGGING_LEVEL_ROOT: INFO
      LOGGING_LEVEL_OSL: INFO
      LOGGING_LEVEL_SPRING_AI: INFO
    
    logging:
      driver: "json-file"
      options:
        max-size: "250m"
        max-file: "2" 
    networks:
      - back
      - front 

  portainer:
    container_name: portainer
    image: portainer/portainer-ce:2.18.4
@@ -479,7 +533,7 @@ services:
      driver: "json-file"
      options:
        max-size: "500m"
        max-file: "3"    
        max-file: "2"    
    ports:
      - "8000:8000"
    networks:
+8 −0
Original line number Diff line number Diff line
@@ -99,6 +99,14 @@ http {
#            proxy_set_header X-Forwarded-Port   443;
#       }

        location /ask {
	        proxy_pass http://oslmcpbackend:11880/ask;
            proxy_set_header  X-Real-IP $remote_addr;
			proxy_set_header  X-Forwarded-For $proxy_add_x_forwarded_for;
			proxy_set_header  Host $http_host;
            proxy_set_header  X-Forwarded-Proto $scheme;
        }
        
    }

}