Skip to content

Commit

Permalink
Update documentation
Browse files Browse the repository at this point in the history
Update docker compose
Update kubernetes file
  • Loading branch information
thabart committed Jul 5, 2023
1 parent 33c68ce commit 04b8011
Show file tree
Hide file tree
Showing 12 changed files with 616 additions and 28 deletions.
31 changes: 29 additions & 2 deletions default.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,11 @@ task dockerBuild -depends clean {
exec { dotnet publish $source_dir\IdServer\SimpleIdServer.IdServer.Startup\SimpleIdServer.IdServer.Startup.csproj -c $config -o $result_dir\docker\IdServer }
exec { dotnet publish $source_dir\IdServer\SimpleIdServer.IdServer.Website.Startup\SimpleIdServer.IdServer.Website.Startup.csproj -c $config -o $result_dir\docker\IdServerWebsite }
exec { dotnet publish $source_dir\Scim\SimpleIdServer.Scim.Startup\SimpleIdServer.Scim.Startup.csproj -c $config -o $result_dir\docker\Scim }
exec { docker-compose build --no-cache }
exec { docker-compose -f local-docker-compose.yml build --no-cache }
}

task dockerPublish -depends dockerBuild {
{ exec docker-compose -f local-docker-compose.yml push }
}

task dockerUp {
Expand All @@ -70,13 +74,22 @@ task buildInstaller {
New-Item $result_dir\linux64\IdServerWebsite -Type Directory
New-Item $result_dir\linux64\Scim -Type Directory

New-Item $result_dir\docker -Type Directory

New-Item $result_dir\kubernetes -Type Directory

Copy-Item -Path $base_dir\scripts\IdServer\Windows\run.ps1 -Destination $result_dir\windows64\IdServer -force
Copy-Item -Path $base_dir\scripts\IdServerWebsite\Windows\run.ps1 -Destination $result_dir\windows64\IdServerWebsite -force
Copy-Item -Path $base_dir\scripts\Scim\Windows\run.ps1 -Destination $result_dir\windows64\Scim -force

Copy-Item -Path $base_dir\scripts\IdServer\Linux\* -Destination $result_dir\linux64\IdServer -recurse -force
Copy-Item -Path $base_dir\scripts\IdServerWebsite\Linux\* -Destination $result_dir\linux64\IdServerWebsite -recurse -force
Copy-Item -Path $base_dir\scripts\Scim\Linux\* -Destination $result_dir\linux64\Scim -recurse -force
Copy-Item -Path $base_dir\scripts\Scim\Linux\* -Destination $result_dir\linux64\Scim -recurse -force

Copy-Item -Path $base_dir\docker-compose.yml -Destination $result_dir\docker\docker-compose.yml
Copy-Item -Path $base_dir\compose -Destination $result_dir\docker -recurse -force

Copy-Item -Path $base_dir\sid-kubernetes.yaml -Destination $result_dir\kubernetes -recurse -force

exec { dotnet publish $source_dir\IdServer\SimpleIdServer.IdServer.Startup\SimpleIdServer.IdServer.Startup.csproj -c $config -o $result_dir\windows64\IdServer\Server -r win-x64 }
exec { dotnet publish $source_dir\IdServer\SimpleIdServer.IdServer.Website.Startup\SimpleIdServer.IdServer.Website.Startup.csproj -c $config -o $result_dir\windows64\IdServerWebsite\Server -r win-x64 }
Expand All @@ -99,6 +112,20 @@ task buildInstaller {
DestinationPath = "$result_dir\SimpleIdServer-Linux-x64.zip"
}
Compress-Archive @compress

$compress = @{
Path = "$result_dir\docker\*"
CompressionLevel = "Fastest"
DestinationPath = "$result_dir\Docker.zip"
}
Compress-Archive @compress

$compress = @{
Path = "$result_dir\kubernetes\*"
CompressionLevel = "Fastest"
DestinationPath = "$result_dir\Kubernetes.zip"
}
Compress-Archive @compress
}


Expand Down
15 changes: 3 additions & 12 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,7 @@ services:
networks:
proxy_net: null
scim:
build:
context: .
dockerfile: ./ScimDockerFile
image: simpleidserver/scim:${TAG}
image: simpleidserver/scim:4.0.1
environment:
VIRTUAL_HOST: "scim.localhost.com"
ASPNETCORE_URLS : "http://*:80"
Expand All @@ -40,10 +37,7 @@ services:
networks:
proxy_net: null
idserver:
build:
context: .
dockerfile: ./IdServer
image: simpleidserver/idserver:${TAG}
image: simpleidserver/idserver:4.0.1
environment:
VIRTUAL_HOST: "idserver.localhost.com"
ASPNETCORE_URLS : "http://*:80"
Expand All @@ -58,10 +52,7 @@ services:
networks:
proxy_net: null
website:
build:
context: .
dockerfile: ./IdServerWebsite
image: simpleidserver/website:${TAG}
image: simpleidserver/website:4.0.1
environment:
VIRTUAL_HOST: "website.localhost.com"
ASPNETCORE_URLS : "http://*:80"
Expand Down
84 changes: 84 additions & 0 deletions local-docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
version: "3.9"
services:
nginx-proxy:
image: jwilder/nginx-proxy
container_name: nginx
ports:
- '443:443'
restart: always
volumes:
- /var/run/docker.sock:/tmp/docker.sock:ro
- ./compose/certificates:/etc/nginx/certs:ro
- ./compose/proxy.conf:/etc/nginx/conf.d/customproxy.conf:ro
networks:
proxy_net:
aliases:
- idserver.localhost.com
- scim.localhost.com
- website.localhost.com
db:
image: mcr.microsoft.com/mssql/server:2022-latest
volumes:
- mssqldata:/var/opt/mssql
environment:
ACCEPT_EULA: Y
MSSQL_SA_PASSWORD : "D54DE7hHpkG9"
networks:
proxy_net: null
scim:
build:
context: .
dockerfile: ./ScimDockerFile
image: simpleidserver/scim:${TAG}
environment:
VIRTUAL_HOST: "scim.localhost.com"
ASPNETCORE_URLS : "http://*:80"
ASPNETCORE_FORWARDEDHEADERS_ENABLED: true
StorageConfiguration__ConnectionString: "Data Source=db;Initial Catalog=Scim;TrustServerCertificate=True;User=sa;Password=D54DE7hHpkG9;"
depends_on:
- db
networks:
proxy_net: null
idserver:
build:
context: .
dockerfile: ./IdServer
image: simpleidserver/idserver:${TAG}
environment:
VIRTUAL_HOST: "idserver.localhost.com"
ASPNETCORE_URLS : "http://*:80"
ASPNETCORE_FORWARDEDHEADERS_ENABLED: true
DistributedCacheConfiguration__ConnectionString: "Data Source=db;Initial Catalog=IdServer;TrustServerCertificate=True;User=sa;Password=D54DE7hHpkG9;"
StorageConfiguration__ConnectionString: "Data Source=db;Initial Catalog=IdServer;TrustServerCertificate=True;User=sa;Password=D54DE7hHpkG9;"
SCIMBaseUrl: "https://scim.localhost.com"
Authority: "https://idserver.localhost.com"
depends_on:
- db
- scim
networks:
proxy_net: null
website:
build:
context: .
dockerfile: ./IdServerWebsite
image: simpleidserver/website:${TAG}
environment:
VIRTUAL_HOST: "website.localhost.com"
ASPNETCORE_URLS : "http://*:80"
ASPNETCORE_FORWARDEDHEADERS_ENABLED: true
DefaultSecurityOptions__Issuer: "https://idserver.localhost.com/master"
DefaultSecurityOptions__IgnoreCertificateError: "true"
IdServerBaseUrl: "https://idserver.localhost.com"
ScimBaseUrl: "https://scim.localhost.com"
StorageConfiguration__ConnectionString: "Data Source=db;Initial Catalog=IdServer;TrustServerCertificate=True;User=sa;Password=D54DE7hHpkG9;"
depends_on:
- db
- idserver
- scim
networks:
proxy_net: null
networks:
proxy_net:
driver: bridge
volumes:
mssqldata:
Loading

0 comments on commit 04b8011

Please sign in to comment.