Install Docker and Docker-compose :
wget -O - https://gist.githubusercontent.com/wdullaer/f1af16bd7e970389bad3/raw/install.sh | bash
Last active
August 8, 2018 15:13
-
-
Save mostafabahri/7c1adb62473768323f3312474d379d42 to your computer and use it in GitHub Desktop.
Minimal Dockerized Postgres for Laravel
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '2' | |
services: | |
dev-pg: | |
image: 'postgres:10-alpine' | |
volumes: | |
- 'dev:/var/lib/postgresql/data' | |
environment: | |
- POSTGRES_DB=app_dev | |
- POSTGRES_USER=laravel | |
- POSTGRES_PASSWORD=secret | |
ports: | |
- '5433:5432' | |
test-pg: | |
image: 'postgres:10-alpine' | |
# volumes: // no need to persist test data | |
# - null | |
environment: | |
- POSTGRES_DB=app_test | |
- POSTGRES_USER=laravel | |
- POSTGRES_PASSWORD=secret | |
ports: | |
- '5434:5432' | |
volumes: | |
dev: |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment