summaryrefslogtreecommitdiffstats
path: root/.ddev/docker-compose.postgrest.yaml
blob: af8e1923b9df4ba70b9f31620ce65ad15a4f79a7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# SPDX-FileCopyrightText: 2024 Eilertsens Kodeknekkeri
# SPDX-FileCopyrightText: 2024 Harald Eilertsen
#
# SPDX-License-Identifier: CC0-1.0

services:
  web:
    # Make the web container wait for the postgrest container
    # to start
    depends_on:
      - db
      - postgrest

  postgrest:
    container_name: ddev-${DDEV_SITENAME}-postgrest
    image: postgrest/postgrest
    labels:
      com.ddev.site-name: ${DDEV_SITENAME}
      com.ddev.approot: ${DDEV_APPROOT}
    environment:
      PGRST_DB_URI: postgres://${PGRST_DB_USER}:${PGRST_DB_PASS}@db:5432/db
      PGRST_DB_ANON_ROLE: web_anon
      PGRST_DB_SCHEMAS: api
      PGRST_JWT_SECRET: ${PGRST_JWT_SECRET}
      VIRTUAL_HOST: ${DDEV_HOSTNAME}
        #HTTP_EXPOSE: 3000
    depends_on:
      - db
    networks:
      default:
        aliases:
          - web