Skip to content

Commit

Permalink
Merge pull request #16 from StackEng/vakil/ASCN-377-Research
Browse files Browse the repository at this point in the history
ASCN-377:  Fix for certain features not working due to SQLClient bugs
  • Loading branch information
WouterDeKort authored Nov 4, 2024
2 parents 4557744 + 5c687d9 commit d21fd3b
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ WORKDIR /app/src/Opserver.Web
RUN dotnet publish -c Release -o publish

# Build runtime image
FROM cr.stackoverflow.software/so-aspnet:6.0-jammy-chiseled AS base
FROM cr.stackoverflow.software/so-aspnet:6.0-jammy-chiseled-extra AS base

USER $APP_UID

Expand Down
4 changes: 2 additions & 2 deletions charts/opserver/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ spec:

{{- if hasKey .Values.opserverSettings "sql" }}
- name: Modules__Sql__defaultConnectionString
value: "Server=$(SQL_EXCEPTIONAL_SERVERNAME);Database=master;User ID=$(SQL_USERNAME);Password=$(SQL_PASSWORD);"
value: "Server=$(SQL_EXCEPTIONAL_SERVERNAME);Database=master;User ID=$(SQL_USERNAME);Password=$(SQL_PASSWORD);TrustServerCertificate=True"
{{- range $i, $instance := .Values.opserverSettings.sql }}
- name: Modules__Sql__instances__{{ $i }}__name
value: "{{ $instance.name }}"
Expand All @@ -165,7 +165,7 @@ spec:
{{- if hasKey .Values.opserverSettings "exceptions" }}
{{- range $i, $instance := .Values.opserverSettings.exceptions }}
- name: Modules__Exceptions__stores__{{ $i }}__connectionString
value: "Server={{ $instance.serverName}};Database={{ $instance.database}};User ID=$(SQL_USERNAME);Password=$(SQL_PASSWORD);"
value: "Server={{ $instance.serverName}};Database={{ $instance.database}};User ID=$(SQL_USERNAME);Password=$(SQL_PASSWORD);TrustServerCertificate=True"
{{- end }}
{{- end }}

Expand Down
2 changes: 1 addition & 1 deletion src/Opserver.Core/Data/SQL/SQLAzureServer.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Data.SqlClient;
using Microsoft.Data.SqlClient;

namespace Opserver.Data.SQL
{
Expand Down
2 changes: 1 addition & 1 deletion src/Opserver.Core/Data/SQL/SQLInstance.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Data.Common;
using System.Data.SqlClient;
using Microsoft.Data.SqlClient;
using System.Runtime.CompilerServices;
using System.Threading.Tasks;
using Opserver.Helpers;
Expand Down
2 changes: 1 addition & 1 deletion src/Opserver.Core/Helpers/Connection.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using System;
using System.Data;
using System.Data.Common;
using System.Data.SqlClient;
using Microsoft.Data.SqlClient;
using System.Threading;
using System.Threading.Tasks;
using StackExchange.Profiling;
Expand Down
2 changes: 1 addition & 1 deletion src/Opserver.Core/Opserver.Core.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
<PackageReference Include="Dapper" Version="2.0.123" />
<PackageReference Include="Enums.NET" Version="4.0.0" />
<PackageReference Include="Jil" Version="2.17.0" />
<PackageReference Include="Microsoft.Data.SqlClient" Version="5.2.2" />
<PackageReference Include="Microsoft.Extensions.Caching.Abstractions" Version="6.0.0" />
<PackageReference Include="Microsoft.Extensions.Logging.Abstractions" Version="6.0.0" />
<PackageReference Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="6.0.0" />
Expand All @@ -20,7 +21,6 @@
<PackageReference Include="StackExchange.Exceptional.Shared" Version="2.2.32" />
<PackageReference Include="StackExchange.Redis" Version="2.6.122" />
<PackageReference Include="StackExchange.Utils.Http" Version="0.3.48" />
<PackageReference Include="System.Data.SqlClient" Version="4.8.5" />
<PackageReference Include="System.DirectoryServices" Version="6.0.0" />
<PackageReference Include="System.Management" Version="6.0.0" />
<PackageReference Include="System.Runtime.Caching" Version="6.0.0" />
Expand Down
3 changes: 2 additions & 1 deletion src/Opserver.Web/Opserver.Web.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,12 @@
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="8.0.1" />
<PackageReference Include="System.Data.SqlClient" Version="4.8.6" />
<ProjectReference Include="..\Opserver.Core\Opserver.Core.csproj" />
<PackageReference Include="BuildBundlerMinifier" Version="3.2.449" PrivateAssets="all" />
<PackageReference Include="BuildWebCompiler" Condition="'$(OS)' == 'Windows_NT'" Version="1.12.405" PrivateAssets="all" />
<PackageReference Include="MiniProfiler.AspNetCore.Mvc" Version="4.2.22" />
<PackageReference Include="Microsoft.IdentityModel.Protocols.OpenIdConnect" Version="6.15.0" />
<PackageReference Include="Microsoft.IdentityModel.Protocols.OpenIdConnect" Version="6.35.0" />
<PackageReference Include="Serilog" Version="4.1.0" />
<PackageReference Include="SerilogAnalyzer" Version="0.15.0" />
<PackageReference Include="Serilog.AspNetCore" Version="8.0.3" />
Expand Down

0 comments on commit d21fd3b

Please sign in to comment.