if macos
docker-compose -f docker-compose.yml -f docker-compose.override.macos.yml up
if windows
docker-compose -f docker-compose.yml -f docker-compose.override.windows.yml up
if linux
docker-compose -f docker-compose.yml -f docker-compose.override.linux.yml up
open
run backend first:
From: ~/InterviewTask
cd src/Api/
dotnet run
run angular app:
From: ~/InterviewTask
cd src/Frontend/
ng serve
navigate to http://localhost:4200
Interview task requires one simple task.
mkdir InterviewTask
cd InterviewTask
dotnet new sln
from ~/InterviewTask
mkdir src
cd src
dotnet new webapi -n InterviewTask.Api -o ./Api
from ~/InterviewTask
dotnet sln add src/Api/InterviewTask.Api.csproj
from ~/InterviewTask/src
ng new Frontend
used angular material for styling and templating.
develop some SW...
- Docker's localhost can be challenging between platforms. I used macos to develop this sample so I use the
docker-compose.override.macos.yml
file when building and running image. - To dynamically change angular apiUrl environment variable, I've added some tweaks to app which can be seen at
index.html
andenvironment.ts
files (included script file at the end of the head tag) - If you set
CreateMockData
toY
(the env variable) at relevant docker-compose.override file, database will be seeded with random todo data.