Skip to content

VictorioBerra/Pumpkin.Beer.Taste

Repository files navigation

Blind Taste Test App

Contributing

Spin up the MSSQL container using docker compose up pumpkinbeertaste-db -d. This is a one-time thing unless you want to blow away the container and volume and start again.

Docker

  • docker build . --file .\src\Pumpkin.Beer.Taste\Dockerfile

Build using Docker Compose

  • docker-compose up --remove-orphans --build

Manual SQL Server Container Creation

Prod deployment

Get into the container using something like Portainer Console and run these commands. Type GO after each command!!

  • /opt/mssql-tools18/bin/sqlcmd -S localhost -U SA -C
  • CREATE DATABASE BlindTasteTest
  • CREATE LOGIN [pumpkinuser] WITH PASSWORD=N'MyPassword'
  • USE BlindTasteTest
  • CREATE USER [pumpkinuser] FOR LOGIN [pumpkinuser]
  • ALTER ROLE db_owner ADD MEMBER [pumpkinuser]

List users and roles

  • SELECT * FROM sys.database_principals;

To change the password for the user

  • ALTER LOGIN [pumpkinuser] WITH PASSWORD = '6^9*xF4t~5K0-!Gm|wPnxqf'; GO;

Deployment

  • Automated by GitHub Actions

Migrations

  • cd ./src/Pumpkin.Beer.Taste
  • dotnet ef migrations add Whatever

TODO

TimeZones are not implemented at all basically. This app fully assumes CT time zone. Docker compose sets DB to TZ=America/Chicago.

The audit properties save with a zero offset.

When a user creates a tasting, the start and closed date is saved with the offset.

When you use the clock service to get the UtcNow, it comes back without an offset. - TODO did this change when I upgraded TimeProvider? Need to test...

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages