File tree Expand file tree Collapse file tree 3 files changed +9
-7
lines changed Expand file tree Collapse file tree 3 files changed +9
-7
lines changed Original file line number Diff line number Diff line change 28
28
},
29
29
// Use 'forwardPorts' to make a list of ports inside the container available locally.
30
30
// This can be used to network with other containers or the host.
31
- "forwardPorts" : [3000 , 5432 ],
31
+ "forwardPorts" : [3100 , 5432 ],
32
32
// Use 'postCreateCommand' to run commands after the container is created.
33
- "postCreateCommand" : " bundle install && bundle exec rake db: setup" ,
33
+ "postCreateCommand" : " ./bin/ setup" ,
34
34
// Configure tool-specific properties.
35
35
"customizations" : {
36
36
"vscode" : {
Original file line number Diff line number Diff line change @@ -17,6 +17,7 @@ services:
17
17
# (Adding the "ports" property to this file will not forward from a Codespace.)
18
18
19
19
environment :
20
+ PORT : 3100
20
21
POSTGRES_USER : postgres
21
22
POSTGRES_DB : postgres
22
23
POSTGRES_PASSWORD : postgres
Original file line number Diff line number Diff line change @@ -36,15 +36,16 @@ export DOCKER_DEFAULT_PLATFORM=linux/arm64/v8
36
36
37
37
``` sh
38
38
echo " RAILS_ENV=development" > .env
39
+ echo " PORT=3100" >> .env
39
40
cp config/database.example.yml config/database.yml
40
41
docker network create null_signal
41
42
docker compose build
42
43
docker compose -f docker-compose.yml -f docker-compose.override.init.yml up -d
43
44
```
44
45
45
- Wait until ` docker compose logs nrdb_api_server | tail ` shows ` Listening on http://0.0.0.0:3000 ` .
46
+ Wait until ` docker compose logs nrdb_api_server | tail ` shows ` Listening on http://0.0.0.0:3100 ` .
46
47
47
- Test that ` http://localhost:3000 /api/docs/ ` loads in your browser. Afterwords,
48
+ Test that ` http://localhost:3100 /api/docs/ ` loads in your browser. Afterwords,
48
49
49
50
``` sh
50
51
docker compose up -d
@@ -65,12 +66,12 @@ docker compose exec -e RAILS_ENV=test bundle exec rails db:seed
65
66
## Getting Started
66
67
67
68
Once your server is running you can hit the api!
68
- ex. ` http://localhost:3000 /api/v3/public/cards/sure_gamble `
69
+ ex. ` http://localhost:3100 /api/v3/public/cards/sure_gamble `
69
70
70
71
You can find the full list of routes here:
71
- ` http://localhost:3000 /rails/info/routes `
72
+ ` http://localhost:3100 /rails/info/routes `
72
73
73
- API Documentation will be available at ` http://localhost:3000 /api/docs/ ` .
74
+ API Documentation will be available at ` http://localhost:3100 /api/docs/ ` .
74
75
75
76
Run ` RAILS_ENV=test bundle exec rails db:reset ` with ` docker compose run ` or in a
76
77
shell in the container to load the fixture data for the tests.
You can’t perform that action at this time.
0 commit comments