test
Some checks failed
Main Build Process / generate documentation (pull_request) Failing after 17s

This commit is contained in:
2024-09-07 16:45:56 +02:00
parent aa2694585e
commit b9899c96c8
4 changed files with 15 additions and 8 deletions

View File

@@ -26,9 +26,13 @@ jobs:
program: "asciidoctor -D docs --backend=html5 -o index.html documentation/readme.adoc"
- name: Print execution time
run: echo "Time ${{ steps.adocbuild.outputs.time }}"
- name: Deploy docs to ghpages
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: Doc
path: ./docs
retention-days: 5
- name: build docker images
run: docker build -t gitea.borealian.ovh/mcmuzzle/ludikzone:latest -f ./docker-prod/Dockerfile .
- name: upload image
run: echo "${{ secrets.PERSO_GITEAPASSWORD}}" | docker login gitea.borealian.ovh --username mcmuzzle --password-stdin

View File

@@ -7,10 +7,6 @@
<UserSecretsId>aspnet-LudikZoneBlazor-b18f2a2e-d082-4232-8521-6cacaa2a4ba2</UserSecretsId>
</PropertyGroup>
<ItemGroup>
<None Update="Data\app.db" CopyToOutputDirectory="PreserveNewest" ExcludeFromSingleFile="true" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore" Version="8.*" />

View File

@@ -74,4 +74,11 @@ app.MapRazorComponents<App>()
// Add additional endpoints required by the Identity /Account Razor components.
app.MapAdditionalIdentityEndpoints();
// Appliquer les migrations automatiquement lors du démarrage
using (var scope = app.Services.CreateScope())
{
var dbContext = scope.ServiceProvider.GetRequiredService<ApplicationDbContext>();
dbContext.Database.Migrate(); // Applique les migrations
}
app.Run();

View File

@@ -1,12 +1,12 @@
{
"ConnectionStrings": {
"DefaultConnection": "DataSource=Data\\app.db;Cache=Shared"
},
"Logging": {
"LogLevel": {
"Default": "Information",
"Microsoft.AspNetCore": "Warning"
}
},
"ConnectionStrings": {
"DefaultConnection": "host=localhost;username=admin;database=ludikZone;Pooling=false;Timeout=300;CommandTimeout=300;Port=5432;"
},
"AllowedHosts": "*"
}