[Fix] Risolto problema SQLite in container Docker Linux
- Cambiato immagine base da Alpine a Debian per migliore compatibilità SQLite - Aggiunto SQLitePCLRaw.bundle_e_sqlite3 per librerie native cross-platform - Installato sqlite3 e libsqlite3-dev in Debian - Risolve definitivamente: 'Error loading shared library libe_sqlite3.so'
This commit is contained in:
@@ -15,6 +15,7 @@
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Sqlite" Version="9.0.3" />
|
||||
<PackageReference Include="Microsoft.Data.SqlClient" Version="5.2.5" />
|
||||
<PackageReference Include="Microsoft.Data.Sqlite" Version="9.0.3" />
|
||||
<PackageReference Include="SQLitePCLRaw.bundle_e_sqlite3" Version="2.1.10" />
|
||||
<PackageReference Include="System.Data.Odbc" Version="9.0.3" />
|
||||
</ItemGroup>
|
||||
|
||||
|
||||
+7
-6
@@ -30,16 +30,17 @@ RUN dotnet publish "Data_Coupler.csproj" -c Release -o /app/publish \
|
||||
/p:PublishSingleFile=false
|
||||
|
||||
# Stage 3: Runtime
|
||||
FROM mcr.microsoft.com/dotnet/aspnet:9.0-alpine AS final
|
||||
FROM mcr.microsoft.com/dotnet/aspnet:9.0 AS final
|
||||
WORKDIR /app
|
||||
|
||||
# Installa le dipendenze necessarie per ExcelDataReader, SQLite e altre librerie
|
||||
RUN apk add --no-cache \
|
||||
# Installa le dipendenze necessarie per ExcelDataReader e SQLite
|
||||
RUN apt-get update && apt-get install -y \
|
||||
libgdiplus \
|
||||
icu-libs \
|
||||
sqlite-libs \
|
||||
libc6-dev \
|
||||
sqlite3 \
|
||||
libsqlite3-dev \
|
||||
curl \
|
||||
&& rm -rf /var/cache/apk/*
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Crea la directory per il database con i permessi corretti
|
||||
RUN mkdir -p /var/lib/Data_Coupler && \
|
||||
|
||||
Reference in New Issue
Block a user