diff --git a/dev/Makefile b/dev/Makefile index 7c644802..7f75b630 100644 --- a/dev/Makefile +++ b/dev/Makefile @@ -10,8 +10,3 @@ down: .PHONY: up up: podman-compose up --detach - sleep 2 - podman-compose exec db psql \ - --user=firefish \ - --dbname=firefish_db \ - --command='CREATE EXTENSION pgroonga;' diff --git a/dev/docker-compose.yml b/dev/docker-compose.yml index 8059ab14..4c616147 100644 --- a/dev/docker-compose.yml +++ b/dev/docker-compose.yml @@ -14,3 +14,5 @@ services: - "POSTGRES_DB=firefish_db" ports: - "5432:5432" + volumes: + - "../neko/pgroonga.sql:/docker-entrypoint-initdb.d/pgroonga.sql:ro" diff --git a/docker-compose.example.yml b/docker-compose.example.yml index fbad1f21..91b3a7d9 100644 --- a/docker-compose.example.yml +++ b/docker-compose.example.yml @@ -40,6 +40,7 @@ services: - .config/docker.env volumes: - ./db:/var/lib/postgresql/data + - ./neko/pgroonga.sql:/docker-entrypoint-initdb.d/pgroonga.sql:ro networks: calcnet: diff --git a/neko/pgroonga.sql b/neko/pgroonga.sql new file mode 100644 index 00000000..11418be3 --- /dev/null +++ b/neko/pgroonga.sql @@ -0,0 +1 @@ +CREATE EXTENSION pgroonga;