{% include 'roles/sys-svc-compose/templates/base.yml.j2' %} {% set service_name = SNIPE_IT_SERVICE %} {{ service_name }}: {{ lookup('template', 'roles/sys-svc-container/templates/build.yml.j2') | indent(4) }} args: SNIPE_IT_IMAGE: "{{ SNIPE_IT_IMAGE }}" SNIPE_IT_VERSION: "{{ SNIPE_IT_VERSION }}" {{ lookup('container_image', application_id, 'snipe-it') }} {{ lookup('compose_only', 'container_name', SNIPE_IT_CONTAINER) }} {% include 'roles/sys-svc-container/templates/base.yml.j2' %} {{ lookup('container_volumes', service_name) | indent(4) }} {{ lookup('container_ports', ['snipe-it', 'http', DOCKER_BIND_HOST]) | indent(4) }} {{ lookup('container_depends_on', application_id) | indent(4) }} {{ lookup('container_extra_hosts') | indent(4) }} {{ lookup('container_networks') | indent(4) }} {{ lookup('container_healthcheck', service_name) | indent(4) }} {% if SNIPEIT_MCP_ENABLED | bool %} {% set service_name = SNIPEIT_MCP_SERVICE_KEY %} {% set docker_compose_env = [SNIPEIT_MCP_INSTANCE_DIR, 'upstream.env'] | path_join %} {{ service_name }}: {% include 'roles/sys-svc-container/templates/base.yml.j2' %} {{ lookup('container_image', application_id, 'snipeitmcp') }} build: context: {{ SNIPEIT_MCP_INSTANCE_DIR }} dockerfile: Dockerfile args: MCP_ADAPTER_BASE_IMAGE: {{ lookup('config', application_id, 'services.snipeitmcp.image') }} MCP_ADAPTER_BASE_VERSION: "{{ lookup('config', application_id, 'services.snipeitmcp.version') }}" {{ lookup('compose_only', 'container_name', SNIPEIT_MCP_CONTAINER) }} read_only: true cap_drop: - ALL security_opt: - no-new-privileges:true environment: ADAPTER_CONTRACT: {{ SNIPEIT_MCP_CONTRACT | to_json | to_json | replace('$', '$$') }} ADAPTER_BEARER: {{ SNIPEIT_MCP_BEARER | to_json }} ADAPTER_PORT: "{{ SNIPEIT_MCP_PORT }}" expose: - "{{ SNIPEIT_MCP_PORT }}" {{ lookup('container_networks', own_network_only=True, provider_self_alias=False) | indent(4) }} {% endif %} {{ lookup('compose_volumes') }} {{ lookup('compose_networks') }}