You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
556 B
26 lines
556 B
#!/usr/bin/env pwsh |
|
param ( |
|
[Parameter(Mandatory)] |
|
$Name |
|
) |
|
|
|
# DB service provider name |
|
$service = "mysql" |
|
|
|
Write-Output "--- Attempting to start $service service ---" |
|
|
|
docker-compose --profile $service up -d --no-recreate |
|
|
|
dotnet tool restore |
|
|
|
$providers = @{ |
|
MySql = "../util/MySqlMigrations" |
|
Postgres = "../util/PostgresMigrations" |
|
Sqlite = "../util/SqliteMigrations" |
|
} |
|
|
|
foreach ($key in $providers.keys) { |
|
Write-Output "--- START $key ---" |
|
dotnet ef migrations add $Name -s $providers[$key] |
|
Write-Output "--- END $key ---" |
|
}
|
|
|