Skip to content

Commit 808d0d9

Browse files
committed
Elasticsearch upgrade and Docker refactor
Upgraded the development Docker compose to the latest minor version of Elasticsearch for our current major version. Upgraded the client to the same version. Refactored Yarn scripts and Docker compose to comply with the modern compose spec
1 parent 8382891 commit 808d0d9

File tree

3 files changed

+3215
-2761
lines changed

3 files changed

+3215
-2761
lines changed

infrastructure/dev/docker-compose.yml infrastructure/dev/compose.yaml

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
version: "2"
2-
31
services:
42
postgresql:
53
image: postgres:11.19-bullseye
@@ -13,8 +11,9 @@ services:
1311
- POSTGRES_USER=postgres
1412
env_file:
1513
- ../../.env
14+
1615
es:
17-
image: docker.elastic.co/elasticsearch/elasticsearch-oss:7.10.2
16+
image: docker.elastic.co/elasticsearch/elasticsearch:7.17.24
1817
ports:
1918
- 9200:9200
2019
environment:

package.json

+5-5
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,13 @@
2222
"about:populateES": "//// Updates Elasticsearch to contain all the data we currently have in the database",
2323
"populateES": "yarn babel-node-ts scripts/populateES.ts",
2424
"about:dev:docker": "//// Creates the Docker containers needed to run the API locally",
25-
"dev:docker": "docker-compose -f infrastructure/dev/docker-compose.yml up -d",
25+
"dev:docker": "docker compose -f infrastructure/dev/compose.yaml up -d",
2626
"about:dev:docker:del": "//// Deletes the aforementioned Docker containers",
27-
"dev:docker:del": "docker-compose -f infrastructure/dev/docker-compose.yml down -v",
27+
"dev:docker:del": "docker compose -f infrastructure/dev/compose.yaml down -v",
2828
"about:dev:docker:server": "//// Experimental: runs the FULL STACK (ie. including searchneu) via Docker",
29-
"dev:docker:server": "docker-compose -f infrastructure/dev/docker-compose-server.yml up -d",
29+
"dev:docker:server": "docker compose -f infrastructure/dev/docker-compose-server.yml up -d",
3030
"about:dev:docker:server:del": "//// Deletes the aforementioned Docker containers",
31-
"dev:docker:server:del": "docker-compose -f infrastructure/dev/docker-compose-server.yml down -v",
31+
"dev:docker:server:del": "docker compose -f infrastructure/dev/docker-compose-server.yml down -v",
3232
"about:db:migrate": "//// Applies Prisma migrations. Think of migrations as `git` for databases - this allows us to change the structure of the DB in a way that can be easily replicated by all developers (and in production)",
3333
"db:migrate": "yarn prisma migrate dev",
3434
"about:db:refresh": "//// Generates Typescript files based on the schema of the database",
@@ -64,7 +64,7 @@
6464
"@babel/node": "^7.0.0",
6565
"@babel/plugin-proposal-class-properties": "^7.8.3",
6666
"@babel/register": "^7.0.0",
67-
"@elastic/elasticsearch": "7.13.0",
67+
"@elastic/elasticsearch": "7.17.0",
6868
"@prisma/client": "^4.5.0",
6969
"@typescript-eslint/typescript-estree": "^5.10.2",
7070
"amplitude": "^5.2.0",

0 commit comments

Comments
 (0)