# The manifest for the "chat" service.
# Read the full specification for the "Load Balanced Web Service" type at:
#  https://aws.github.io/copilot-cli/docs/manifest/lb-web-service/

# Your service name will be used in naming your resources like log groups, ECS services, etc.
name: chat
type: Load Balanced Web Service

# Distribute traffic to your service.
http:
  # Requests to this path will be forwarded to your service.
  # To match all requests you can use the "/" path.
  path: '/'
  # You can specify a custom health check path. The default is "/".
  healthcheck: '/health'

# Configuration for your containers and service.
image:
  location: matrixdotorg/synapse
  # Port exposed through your container to route traffic to it.
  port: 8008

cpu: 2048       # Number of CPU units for the task.
memory: 4096    # Amount of memory in MiB used by the task.
count: 1       # Number of tasks that should be running in your service.
exec: true     # Enable running commands in your container.
network:
  connect: true # Enable Service Connect for intra-environment traffic between services.

storage:
  volumes:
    efs:
      path: /var/lib/efs/
      read_only: false
      efs:
        id: fs-0b9130403869b3430
        auth:
          iam: true
          access_point_id: fsap-06cd2e16280eb6c27

# storage:
  # readonly_fs: true       # Limit to read-only access to mounted root filesystems.

# Optional fields for more advanced use-cases.
#
variables:                    # Pass environment variables as key value pairs.
  SYNAPSE_SERVER_NAME: sndev.team
  SYNAPSE_REPORT_STATS: no
  SYNAPSE_CONFIG_DIR: /var/lib/efs/matrix
  SYNAPSE_DATA_DIR: /var/lib/efs/matrix
  UID: 991
  GID: 991