Prerequisites :
- .Net 6 SDK (https://dotnet.microsoft.com/en-us/download/dotnet/6.0)
- Docker (https://www.docker.com/)
The project can be improved on different ways. You are totally free to improve the tests, codebase, etc... as you want. You can explain your improvements and choices on the SOLUTION.md file
- Run
cd c#-dotnet
- Run
docker compose up
(this will build the listingapi project and the database) - For the listingapi swagger go to http://localhost:8686/swagger/index.html
- Open the solution file
listingapi.sln
found in the folderc#-dotnet
- Set the project docker-compose as the startup project
- Run the Docker Compose project
- The listingapi swagger should open automatically or go to https://localhost:8686/swagger/index.html
You should then see your 2 containers running!
- After running your docker compose, using your favorite database management tool you will be able to explore the database using the following credentials :
- POSTGRES_DB: listing
- POSTGRES_USER: listing
- POSTGRES_PASSWORD: listing
Example :
- Using visual studio server explorer go to : View > Server Explorer (CTRL+ALT+S)
- Install the PostgreSQL integration following : https://marketplace.visualstudio.com/items?itemName=RojanskyS.NpgsqlPostgreSQLIntegration
- Add a new connection with the following configuration
- Explore to your heart content