diff options
author | Freya Murphy <freya@freyacat.org> | 2024-03-29 22:29:56 -0400 |
---|---|---|
committer | Freya Murphy <freya@freyacat.org> | 2024-03-29 22:29:56 -0400 |
commit | 944b6b0526032ad8c1b4a2612d6723bec75e0e4c (patch) | |
tree | d3da5584df33a7878c087622b4fc2ec2883cf880 /docker-compose.yml | |
download | xssbook2-944b6b0526032ad8c1b4a2612d6723bec75e0e4c.tar.gz xssbook2-944b6b0526032ad8c1b4a2612d6723bec75e0e4c.tar.bz2 xssbook2-944b6b0526032ad8c1b4a2612d6723bec75e0e4c.zip |
start database (user and post), and initial barebones home page
Diffstat (limited to 'docker-compose.yml')
-rw-r--r-- | docker-compose.yml | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..af31ac6 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,62 @@ +services: + web: + image: nginx:alpine + restart: unless-stopped + ports: + - '80:80' + volumes: + - ./web:/opt/xssbook + - ./conf/nginx:/etc/nginx/conf.d:ro + depends_on: + - rest + - swagger + - php + + php: + build: ./build/php + restart: unless-stopped + env_file: + - ./conf/postgres/database.env + volumes: + - ./web:/opt/xssbook + - ./data/status:/status + depends_on: + - db + + db: + #image: postgres:16-alpine + build: ./build/postgres + restart: unless-stopped + env_file: + - ./conf/postgres/database.env + environment: + - POSTGRES_INITDB_ARGS=--encoding=UTF-8 --lc-collate=C --lc-ctype=C + volumes: + - './data/schemas:/var/lib/postgresql/data' + - ./db:/db:ro + + rest: + build: ./build/postgrest + env_file: + - ./conf/postgres/database.env + depends_on: + - db + + init: + build: ./build/dbinit + env_file: + - ./conf/postgres/database.env + volumes: + - ./db:/db:ro + - ./data/status:/status + depends_on: + - db + + swagger: + image: swaggerapi/swagger-ui + environment: + SWAGGER_JSON_URL: '/api' + BASE_URL: '/apidocs' + PORT: 3000 + depends_on: + - db |