Skip to content

Commit f31358e

Browse files
committed
add readme
1 parent 146154c commit f31358e

File tree

3 files changed

+39
-3
lines changed

3 files changed

+39
-3
lines changed

README.md

Lines changed: 36 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,36 @@
1-
# Scrum Game Service
1+
# DinoDev Backend
2+
3+
This repository contains the backend of the DinoDev project.
4+
5+
## How to run with Docker
6+
7+
1. Make sure that the Gropius backend is accessible, either by running it locally or by using the deployed version. If
8+
running local, ensure that the public-api and the login-service are in the `scrum-game-network` network.
9+
2. Edit the docker-compose.yml file to set the correct environment variables:
10+
- GROPIUS_URL: http://<public-api-container>:8080
11+
- GROPIUS_FRONTEND_URL: http://localhost:4200
12+
- GROPIUS_AUTH_SECRET: secret of the login service
13+
The frontend URL is used to provide a direct link from issues. The given URL is the default URL of the Gropius
14+
frontend when running locally.
15+
When using a deployed version, ask the administrator for the secret.
16+
3. Run `docker-compose up` to start the backend.
17+
18+
## Dev Setup
19+
20+
1. Follow the instructions of the first step in the previous section.
21+
2. Only run the database, i.e., `docker-compose up database-scrum-game`.
22+
3. Edit the `application-dev` properties similar to step 2 in the previous section. With the default setup, only the
23+
secret needs to be changed.
24+
4. Run the backend in the `dev` profile: `./gradlew bootRun --args='--spring.profiles.active=dev'`. Or simply use an
25+
IntelliJ run configuration, but make sure to set the `dev` profile in the run configuration.
26+
27+
## Package Structure
28+
29+
- `config`: Contains the configuration classes.
30+
- `controller`: Contains the GraphQL controllers.
31+
- `exception`: Code for exception handling.
32+
- `persistance`: Contains the repositories, entities, and mappings.
33+
- `service`: Contains the services.
34+
- `util`: Contains utility classes.
35+
36+

docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ services:
3434
# replace accordingly:
3535
GROPIUS_URL: http://gropius-testing-api-public-1:8080
3636
GROPIUS_FRONTEND_URL: http://localhost:4200
37-
GROPIUS_AUTH_SECRET: xvnoqU54G4GDUx7B9EHiyPhjjnpLDSmTq7XhAcVhszDYzGKPCwPq2nQjszzfg5DVEevQonNaeyQZFdMMNFcXH96Jgu9zw3JUjnj7
37+
GROPIUS_AUTH_SECRET: <GROPIUS_AUTH_SECRET>
3838
networks:
3939
- "scrum-game-network"
4040
volumes:

src/main/resources/application-dev.properties

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ spring.sql.init.continue-on-error=true
99
spring.jpa.hibernate.ddl-auto=update
1010
# Security
1111
logging.level.org.springframework.security=INFO
12-
gropius.auth.secret=xvnoqU54G4GDUx7B9EHiyPhjjnpLDSmTq7XhAcVhszDYzGKPCwPq2nQjszzfg5DVEevQonNaeyQZFdMMNFcXH96Jgu9zw3JUjnj7
12+
# replace accordingly
13+
gropius.auth.secret=<secret>
1314
gropius.url=http://localhost:8080
1415
gropius.frontend.url=http://localhost:4200
1516

0 commit comments

Comments
 (0)