Skip to content

Commit

Permalink
First deployment (#3)
Browse files Browse the repository at this point in the history
  • Loading branch information
maxirmx authored Apr 14, 2024
1 parent 61cfcd3 commit 7ecddbc
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 16 deletions.
2 changes: 1 addition & 1 deletion dkgNode/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
Host = Environment.GetEnvironmentVariable("DKG_NODE_SERVER_GRPC_HOST") ?? "localhost",
NiceName = Environment.GetEnvironmentVariable("DKG_NODE_SERVER_NAME")
};
var serviceNodeUrl = Environment.GetEnvironmentVariable("DKG_SERVICE_NODE_URL") ?? "http://localhost:8080";
var serviceNodeUrl = Environment.GetEnvironmentVariable("DKG_SERVICE_NODE_URL") ?? "https://localhost:8081";

var loggerFactory = app.Services.GetRequiredService<ILoggerFactory>();
var logger = loggerFactory.CreateLogger("DkgNode");
Expand Down
2 changes: 1 addition & 1 deletion dkgServiceNode/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@

app.UseMiddleware<JwtMiddleware>();

// app.UseHttpsRedirection();
//app.UseHttpsRedirection();
app.UseAuthorization();
app.MapControllers();

Expand Down
6 changes: 6 additions & 0 deletions dkgServiceNode/dkgServiceNode.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,10 @@
<ProjectReference Include="..\dkgCommon\dkgCommon.csproj" />
</ItemGroup>

<ItemGroup>
<None Update="s.pfx">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>

</Project>
10 changes: 6 additions & 4 deletions docker-compose-ghrc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,14 @@ services:
image: ghcr.io/maxirmx/dkg-service-node:latest
environment:
- ASPNETCORE_ENVIRONMENT=Development
- ASPNETCORE_HTTP_PORTS=8081
# - ASPNETCORE_HTTPS_PORTS=8081
- ASPNETCORE_HTTP_PORTS=8080
- ASPNETCORE_HTTPS_PORTS=8081
- Kestrel__Certificates__Default__Password_FILE=/etc/dkg/s.pwd
ports:
- "8080:8080"
# - "8081:8081"
# volumes:
- "8081:8081"
volumes:
- /etc/dkg:/etc/dkg
# - ${APPDATA}/Microsoft/UserSecrets:/home/app/.microsoft/usersecrets:ro
# - ${APPDATA}/ASP.NET/Https:/home/app/.aspnet/https:ro
depends_on:
Expand Down
23 changes: 13 additions & 10 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,16 @@ services:
- ASPNETCORE_ENVIRONMENT=Development
- ASPNETCORE_HTTP_PORTS=8080
- ASPNETCORE_HTTPS_PORTS=8081
- ASPNETCORE_Kestrel__Certificates__Default__Path=/etc/dkg/s.pfx
# - ASPNETCORE_Kestrel__Certificates__Default__Password=
# - ASPNETCORE_Kestrel__Certificates__Default__Password_FILE=/etc/dkg/s.pwd
ports:
- "8080:8080"
- "8081:8081"
volumes:
- ${APPDATA}/Microsoft/UserSecrets:/home/app/.microsoft/usersecrets:ro
- ${APPDATA}/ASP.NET/Https:/home/app/.aspnet/https:ro
- /etc/dkg:/etc/dkg
# - ${APPDATA}/Microsoft/UserSecrets:/home/app/.microsoft/usersecrets:ro
# - ${APPDATA}/ASP.NET/Https:/home/app/.aspnet/https:ro
depends_on:
- dkgservice_db

Expand Down Expand Up @@ -110,14 +114,13 @@ services:
- POSTGRES_DB=dkgservice
volumes:
- pgdata:/var/lib/postgresql
adminer:
container_name: adminer
image: adminer
restart: always
ports:
- 8082:8080

# adminer:
# container_name: adminer
# image: adminer
# restart: always
# ports:
# - 8082:8080

volumes:
pgdata: {}

0 comments on commit 7ecddbc

Please sign in to comment.