docker-compose.yml 906 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. version: '3.8'
  2. networks:
  3. dev:
  4. driver: bridge
  5. services:
  6. mt-app:
  7. image: docker.io/library/hr
  8. depends_on:
  9. - "mt-db"
  10. container_name: mt-app-services
  11. ports:
  12. - "8080:80"
  13. build:
  14. context: .
  15. dockerfile: Dockerfile
  16. environment:
  17. - ConnectionStrings__MTWorkHRConnectionString=Server=mt-db;Database=MTWorkHRDB;User=sa;Password=p@ssw0rd;MultipleActiveResultSets=true;Integrated Security=True;Encrypt=False;
  18. - ASPNETCORE_URLS=http://+80
  19. networks:
  20. - dev
  21. mt-db:
  22. image: mcr.microsoft.com/mssql/server:2022-preview-ubuntu-22.04
  23. container_name: mt-db
  24. user: root
  25. environment:
  26. SA_USER: "sa"
  27. SA_PASSWORD: "p@ssw0rd"
  28. SA_DATABASE: "MTWorkHRDB"
  29. ACCEPT_EULA: "Y"
  30. ports:
  31. - "1433:1433"
  32. restart: always
  33. volumes:
  34. - app_data:/var/opt/mssql/data
  35. networks:
  36. - dev
  37. volumes:
  38. app_data: