-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Some nuget upgrades; removed all constants from Kubernetes deployment…
… files
- Loading branch information
1 parent
ba2ef67
commit 62297a0
Showing
17 changed files
with
134 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#See https://aka.ms/customizecontainer to learn how to customize your debug container and how Visual Studio uses this Dockerfile to build your images for faster debugging. | ||
|
||
# Using the SDK image as the base instead of the aspnet image lets us run a shell for debugging. | ||
#FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base | ||
FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base | ||
WORKDIR /app | ||
EXPOSE 5000 | ||
EXPOSE 5001 | ||
|
||
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build | ||
WORKDIR /src | ||
COPY ["Grace.Server/Grace.Server.fsproj", "./Grace.Server/"] | ||
COPY ["Grace.Actors/Grace.Actors.fsproj", "./Grace.Actors/"] | ||
COPY ["Grace.Shared/Grace.Shared.fsproj", "./Grace.Shared/"] | ||
COPY ["CosmosSerializer/CosmosJsonSerializer.csproj", "./CosmosSerializer/"] | ||
RUN dotnet restore "Grace.Server/Grace.Server.fsproj" | ||
COPY . . | ||
WORKDIR "/src/Grace.Server" | ||
#RUN dotnet build "Grace.Server.fsproj" -c Debug -o /app/build | ||
|
||
FROM build AS publish | ||
RUN dotnet publish "Grace.Server.fsproj" -c Debug -o /app/publish /p:UseAppHost=false | ||
|
||
# Set environment variables to configure ASP.NET Core to use the certificate | ||
#ENV ASPNETCORE_URLS="https://+;http://+" | ||
ENV ASPNETCORE_HTTPS_PORT=5001 | ||
ENV ASPNETCORE_HTTP_PORT=5000 | ||
ENV DOTNET_GENERATE_ASPNET_CERTIFICATE=false | ||
|
||
FROM base AS final | ||
WORKDIR /app | ||
COPY --from=publish /app/publish . | ||
ENTRYPOINT ["dotnet", "Grace.Server.dll"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
param ( | ||
[Parameter(Mandatory=$true)] | ||
[string]$SecretName, | ||
|
||
[Parameter(Mandatory=$false)] | ||
[switch]$CreateCommand | ||
) | ||
|
||
# Get the secret from Kubernetes | ||
$encodedSecret = kubectl get secret $SecretName -o jsonpath="{.data}" | ||
|
||
# Decode the secret | ||
$deserialized = $encodedSecret | ConvertFrom-Json | ||
|
||
$decodedSecret = [System.Text.Encoding]::UTF8.GetString([System.Convert]::FromBase64String($deserialized.$SecretName)) | ||
|
||
# Display the secret | ||
$decodedSecret | ||
|
||
# Create a command to set the secret | ||
if ($CreateCommand) { | ||
"kubectl create secret generic $SecretName --from-literal=$SecretName=""$decodedSecret""" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.