NOTE:- WeatherApi api key needs to be configured to application.yaml file. Api key is shared one to one over the email. Please use the same api key and use it against weather.api.apiKey property.
Postgres database is required to run the application. Choose one of the options below.
- Build the docker image
docker-compose build
- Create and start all containers in the background
docker-compose up -d
- Check container status with
docker-compose ps
. They should all have status 'Up' - The Application is running with all required dependencies.
- Run the database
docker-compose up -d databse
- (Optional) Run adminer database viewer tool
docker-compose up -d adminer
- Run the application with either:
- gradle, providing datasource configuration explicitly
./gradlew bootRun
- Intellij, providing environment variables in the launch configuration
- SPRING_DATASOURCE_URL=jdbc:postgresql://127.0.0.1:5432/postgres
- SPRING_DATASOURCE_USERNAME=postgres
- SPRING_DATASOURCE_PASSWORD=postgres
- gradle, providing datasource configuration explicitly
Install Postgres manually and have it running on localhost on port 5432. There has to be user "postgres"
with password "postgres" with full access to public schema. Then run gradle wrapper ./gradlew bootRun
.