From d8f57161aeed1a199e6b0def78883d5a8b7b62ec Mon Sep 17 00:00:00 2001 From: LittleSheep Date: Tue, 16 Sep 2025 23:36:26 +0800 Subject: [PATCH] :hammer: Add aspire build workflow --- .github/workflows/docker-build.yml | 190 +++++------------------------ DysonNetwork.sln.DotSettings.user | 2 + publish/.env | 35 ++++++ publish/docker-compose.yaml | 181 +++++++++++++++++++++++++++ settings/develop.json | 26 ++++ settings/drive.json | 133 ++++++++++++++++++++ settings/pass.json | 88 +++++++++++++ settings/ring.json | 50 ++++++++ settings/sphere.json | 41 +++++++ 9 files changed, 587 insertions(+), 159 deletions(-) create mode 100644 publish/.env create mode 100644 publish/docker-compose.yaml create mode 100644 settings/develop.json create mode 100644 settings/drive.json create mode 100644 settings/pass.json create mode 100644 settings/ring.json create mode 100644 settings/sphere.json diff --git a/.github/workflows/docker-build.yml b/.github/workflows/docker-build.yml index f4f3bac..14c1e75 100644 --- a/.github/workflows/docker-build.yml +++ b/.github/workflows/docker-build.yml @@ -1,4 +1,4 @@ -name: Build and Push Microservices +name: Aspire Publish Workflow on: push: @@ -7,7 +7,7 @@ on: workflow_dispatch: jobs: - build-sphere: + publish: runs-on: ubuntu-latest permissions: contents: read @@ -15,174 +15,46 @@ jobs: steps: - name: Checkout repository uses: actions/checkout@v3 - with: - fetch-depth: 0 - - name: Setup NBGV - uses: dotnet/nbgv@master - id: nbgv - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v3 - - name: Log in to GitHub Container Registry - uses: docker/login-action@v3 - with: - registry: ghcr.io - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} - - name: Build and push DysonNetwork.Sphere Docker image - uses: docker/build-push-action@v6 - with: - file: DysonNetwork.Sphere/Dockerfile - context: . - push: true - tags: ghcr.io/${{ vars.PACKAGE_OWNER }}/dyson-sphere:latest - platforms: linux/amd64 - build-pass: - runs-on: ubuntu-latest - permissions: - contents: read - packages: write - steps: - - name: Checkout repository - uses: actions/checkout@v3 + - name: Setup .NET + uses: actions/setup-dotnet@v3 with: - fetch-depth: 0 - - name: Setup NBGV - uses: dotnet/nbgv@master - id: nbgv - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v3 - - name: Log in to GitHub Container Registry - uses: docker/login-action@v3 - with: - registry: ghcr.io - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} - - name: Build and push DysonNetwork.Pass Docker image - uses: docker/build-push-action@v6 - with: - file: DysonNetwork.Pass/Dockerfile - context: . - push: true - tags: ghcr.io/${{ vars.PACKAGE_OWNER }}/dyson-pass:latest - platforms: linux/amd64 + dotnet-version: "9.0.x" - build-ring: - runs-on: ubuntu-latest - permissions: - contents: read - packages: write - steps: - - name: Checkout repository - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - name: Setup NBGV - uses: dotnet/nbgv@master - id: nbgv - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v3 - name: Log in to GitHub Container Registry uses: docker/login-action@v3 with: registry: ghcr.io username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - - name: Build and push DysonNetwork.Pusher Docker image - uses: docker/build-push-action@v6 - with: - file: DysonNetwork.Ring/Dockerfile - context: . - push: true - tags: ghcr.io/${{ vars.PACKAGE_OWNER }}/dyson-ring:latest - platforms: linux/amd64 - build-drive: - runs-on: ubuntu-latest - permissions: - contents: read - packages: write - steps: - - name: Checkout repository - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - name: Setup NBGV - uses: dotnet/nbgv@master - id: nbgv - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v3 - - name: Log in to GitHub Container Registry - uses: docker/login-action@v3 - with: - registry: ghcr.io - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} - - name: Build and push DysonNetwork.Drive Docker image - uses: docker/build-push-action@v6 - with: - file: DysonNetwork.Drive/Dockerfile - context: . - push: true - tags: ghcr.io/${{ vars.PACKAGE_OWNER }}/dyson-drive:latest - platforms: linux/amd64 + - name: Install Aspire CLI + run: dotnet tool install -g Aspire.Cli --prerelease - build-gateway: - runs-on: ubuntu-latest - permissions: - contents: read - packages: write - steps: - - name: Checkout repository - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - name: Setup NBGV - uses: dotnet/nbgv@master - id: nbgv - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v3 - - name: Log in to GitHub Container Registry - uses: docker/login-action@v3 - with: - registry: ghcr.io - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} - - name: Build and push DysonNetwork.Gateway Docker image - uses: docker/build-push-action@v6 - with: - file: DysonNetwork.Gateway/Dockerfile - context: . - push: true - tags: ghcr.io/${{ vars.PACKAGE_OWNER }}/dyson-gateway:latest - platforms: linux/amd64 + - name: Build and Publish Aspire Application + run: aspire publish --project ./DysonNetwork.Control/DysonNetwork.Control.csproj --output publish - build-develop: - runs-on: ubuntu-latest - permissions: - contents: read - packages: write - steps: - - name: Checkout repository - uses: actions/checkout@v3 + - name: Tag and Push Images + run: | + IMAGES=( "sphere" "pass" "ring" "drive" "develop" ) + + for image in "${IMAGES[@]}"; do + IMAGE_NAME="ghcr.io/${{ vars.PACKAGE_OWNER }}/dyson-$image:latest" + SOURCE_IMAGE_NAME="$image:latest" # Aspire's default local image name + + echo "Tagging and pushing $SOURCE_IMAGE_NAME to $IMAGE_NAME..." + docker tag $SOURCE_IMAGE_NAME $IMAGE_NAME + docker push $IMAGE_NAME + done + + - name: Upload Aspire Publish Directory + uses: actions/upload-artifact@v3 with: - fetch-depth: 0 - - name: Setup NBGV - uses: dotnet/nbgv@master - id: nbgv - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v3 - - name: Log in to GitHub Container Registry - uses: docker/login-action@v3 + name: aspire-publish-output + path: ./publish/ + + - name: Upload Docker Compose file + uses: actions/upload-artifact@v3 with: - registry: ghcr.io - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} - - name: Build and push DysonNetwork.Develop Docker image - uses: docker/build-push-action@v6 - with: - file: DysonNetwork.Develop/Dockerfile - context: . - push: true - tags: ghcr.io/${{ vars.PACKAGE_OWNER }}/dyson-develop:latest - platforms: linux/amd64 + name: docker-compose-output + path: ./publish/docker-compose.yml diff --git a/DysonNetwork.sln.DotSettings.user b/DysonNetwork.sln.DotSettings.user index 383843d..72dd347 100644 --- a/DysonNetwork.sln.DotSettings.user +++ b/DysonNetwork.sln.DotSettings.user @@ -22,6 +22,7 @@ ForceIncluded ForceIncluded ForceIncluded + ForceIncluded ForceIncluded ForceIncluded ForceIncluded @@ -33,6 +34,7 @@ ForceIncluded ForceIncluded ForceIncluded + ForceIncluded ForceIncluded ForceIncluded ForceIncluded diff --git a/publish/.env b/publish/.env new file mode 100644 index 0000000..13c2b1d --- /dev/null +++ b/publish/.env @@ -0,0 +1,35 @@ +# Default container port for ring +RING_PORT=8080 + +# Default container port for pass +PASS_PORT=8080 + +# Default container port for drive +DRIVE_PORT=8080 + +# Default container port for sphere +SPHERE_PORT=8080 + +# Default container port for develop +DEVELOP_PORT=8080 + +# Parameter cache-password +CACHE_PASSWORD=KS3jSPaU9e + +# Parameter queue-password +QUEUE_PASSWORD=8xEECa4ckz + +# Container image name for ring +RING_IMAGE=ring:latest + +# Container image name for pass +PASS_IMAGE=pass:latest + +# Container image name for drive +DRIVE_IMAGE=drive:latest + +# Container image name for sphere +SPHERE_IMAGE=sphere:latest + +# Container image name for develop +DEVELOP_IMAGE=develop:latest diff --git a/publish/docker-compose.yaml b/publish/docker-compose.yaml new file mode 100644 index 0000000..d439bed --- /dev/null +++ b/publish/docker-compose.yaml @@ -0,0 +1,181 @@ +services: + docker-compose-dashboard: + image: "mcr.microsoft.com/dotnet/nightly/aspire-dashboard:latest" + expose: + - "18888" + - "18889" + networks: + - "aspire" + restart: "always" + cache: + image: "docker.io/library/redis:7.4" + command: + - "-c" + - "redis-server --requirepass $$REDIS_PASSWORD" + entrypoint: + - "/bin/sh" + environment: + REDIS_PASSWORD: "${CACHE_PASSWORD}" + expose: + - "6379" + networks: + - "aspire" + queue: + image: "docker.io/library/nats:2.11" + command: + - "--user" + - "nats" + - "--pass" + - "${QUEUE_PASSWORD}" + - "-js" + expose: + - "4222" + networks: + - "aspire" + ring: + image: "${RING_IMAGE}" + environment: + OTEL_DOTNET_EXPERIMENTAL_OTLP_EMIT_EXCEPTION_LOG_ATTRIBUTES: "true" + OTEL_DOTNET_EXPERIMENTAL_OTLP_EMIT_EVENT_LOG_ATTRIBUTES: "true" + OTEL_DOTNET_EXPERIMENTAL_OTLP_RETRY: "in_memory" + ASPNETCORE_FORWARDEDHEADERS_ENABLED: "true" + HTTP_PORTS: "${RING_PORT}" + ConnectionStrings__queue: "nats://nats:${QUEUE_PASSWORD}@queue:4222" + services__pass__http__0: "http://pass:${PASS_PORT}" + OTEL_EXPORTER_OTLP_ENDPOINT: "http://docker-compose-dashboard:18889" + OTEL_EXPORTER_OTLP_PROTOCOL: "grpc" + OTEL_SERVICE_NAME: "ring" + expose: + - "${RING_PORT}" + networks: + - "aspire" + pass: + image: "${PASS_IMAGE}" + environment: + OTEL_DOTNET_EXPERIMENTAL_OTLP_EMIT_EXCEPTION_LOG_ATTRIBUTES: "true" + OTEL_DOTNET_EXPERIMENTAL_OTLP_EMIT_EVENT_LOG_ATTRIBUTES: "true" + OTEL_DOTNET_EXPERIMENTAL_OTLP_RETRY: "in_memory" + ASPNETCORE_FORWARDEDHEADERS_ENABLED: "true" + HTTP_PORTS: "${PASS_PORT}" + ConnectionStrings__cache: "cache:6379,password=${CACHE_PASSWORD}" + ConnectionStrings__queue: "nats://nats:${QUEUE_PASSWORD}@queue:4222" + services__ring__http__0: "http://ring:${RING_PORT}" + OTEL_EXPORTER_OTLP_ENDPOINT: "http://docker-compose-dashboard:18889" + OTEL_EXPORTER_OTLP_PROTOCOL: "grpc" + OTEL_SERVICE_NAME: "pass" + expose: + - "${PASS_PORT}" + networks: + - "aspire" + drive: + image: "${DRIVE_IMAGE}" + environment: + OTEL_DOTNET_EXPERIMENTAL_OTLP_EMIT_EXCEPTION_LOG_ATTRIBUTES: "true" + OTEL_DOTNET_EXPERIMENTAL_OTLP_EMIT_EVENT_LOG_ATTRIBUTES: "true" + OTEL_DOTNET_EXPERIMENTAL_OTLP_RETRY: "in_memory" + ASPNETCORE_FORWARDEDHEADERS_ENABLED: "true" + HTTP_PORTS: "${DRIVE_PORT}" + ConnectionStrings__cache: "cache:6379,password=${CACHE_PASSWORD}" + ConnectionStrings__queue: "nats://nats:${QUEUE_PASSWORD}@queue:4222" + services__pass__http__0: "http://pass:${PASS_PORT}" + services__ring__http__0: "http://ring:${RING_PORT}" + OTEL_EXPORTER_OTLP_ENDPOINT: "http://docker-compose-dashboard:18889" + OTEL_EXPORTER_OTLP_PROTOCOL: "grpc" + OTEL_SERVICE_NAME: "drive" + expose: + - "${DRIVE_PORT}" + networks: + - "aspire" + sphere: + image: "${SPHERE_IMAGE}" + environment: + OTEL_DOTNET_EXPERIMENTAL_OTLP_EMIT_EXCEPTION_LOG_ATTRIBUTES: "true" + OTEL_DOTNET_EXPERIMENTAL_OTLP_EMIT_EVENT_LOG_ATTRIBUTES: "true" + OTEL_DOTNET_EXPERIMENTAL_OTLP_RETRY: "in_memory" + ASPNETCORE_FORWARDEDHEADERS_ENABLED: "true" + HTTP_PORTS: "${SPHERE_PORT}" + ConnectionStrings__cache: "cache:6379,password=${CACHE_PASSWORD}" + ConnectionStrings__queue: "nats://nats:${QUEUE_PASSWORD}@queue:4222" + services__pass__http__0: "http://pass:${PASS_PORT}" + services__ring__http__0: "http://ring:${RING_PORT}" + OTEL_EXPORTER_OTLP_ENDPOINT: "http://docker-compose-dashboard:18889" + OTEL_EXPORTER_OTLP_PROTOCOL: "grpc" + OTEL_SERVICE_NAME: "sphere" + expose: + - "${SPHERE_PORT}" + networks: + - "aspire" + develop: + image: "${DEVELOP_IMAGE}" + environment: + OTEL_DOTNET_EXPERIMENTAL_OTLP_EMIT_EXCEPTION_LOG_ATTRIBUTES: "true" + OTEL_DOTNET_EXPERIMENTAL_OTLP_EMIT_EVENT_LOG_ATTRIBUTES: "true" + OTEL_DOTNET_EXPERIMENTAL_OTLP_RETRY: "in_memory" + ASPNETCORE_FORWARDEDHEADERS_ENABLED: "true" + HTTP_PORTS: "${DEVELOP_PORT}" + ConnectionStrings__cache: "cache:6379,password=${CACHE_PASSWORD}" + services__pass__http__0: "http://pass:${PASS_PORT}" + services__ring__http__0: "http://ring:${RING_PORT}" + OTEL_EXPORTER_OTLP_ENDPOINT: "http://docker-compose-dashboard:18889" + OTEL_EXPORTER_OTLP_PROTOCOL: "grpc" + OTEL_SERVICE_NAME: "develop" + expose: + - "${DEVELOP_PORT}" + networks: + - "aspire" + gateway: + image: "mcr.microsoft.com/dotnet/nightly/yarp:2.3.0-preview.4" + command: + - "/app/yarp.dll" + entrypoint: + - "dotnet" + environment: + ASPNETCORE_ENVIRONMENT: "Production" + services__ring__http__0: "http://ring:${RING_PORT}" + REVERSEPROXY__ROUTES__route0__MATCH__PATH: "/ws" + REVERSEPROXY__ROUTES__route0__CLUSTERID: "cluster_ring" + REVERSEPROXY__ROUTES__route1__MATCH__PATH: "/ring/{**catch-all}" + REVERSEPROXY__ROUTES__route1__CLUSTERID: "cluster_ring" + REVERSEPROXY__ROUTES__route1__TRANSFORMS__0__PathRemovePrefix: "/ring" + REVERSEPROXY__ROUTES__route1__TRANSFORMS__1__PathPrefix: "/api" + REVERSEPROXY__ROUTES__route2__MATCH__PATH: "/.well-known/openid-configuration" + REVERSEPROXY__ROUTES__route2__CLUSTERID: "cluster_pass" + REVERSEPROXY__ROUTES__route3__MATCH__PATH: "/.well-known/jwks" + REVERSEPROXY__ROUTES__route3__CLUSTERID: "cluster_pass" + REVERSEPROXY__ROUTES__route4__MATCH__PATH: "/id/{**catch-all}" + REVERSEPROXY__ROUTES__route4__CLUSTERID: "cluster_pass" + REVERSEPROXY__ROUTES__route4__TRANSFORMS__0__PathRemovePrefix: "/id" + REVERSEPROXY__ROUTES__route4__TRANSFORMS__1__PathPrefix: "/api" + REVERSEPROXY__ROUTES__route5__MATCH__PATH: "/api/tus" + REVERSEPROXY__ROUTES__route5__CLUSTERID: "cluster_drive" + REVERSEPROXY__ROUTES__route6__MATCH__PATH: "/drive/{**catch-all}" + REVERSEPROXY__ROUTES__route6__CLUSTERID: "cluster_drive" + REVERSEPROXY__ROUTES__route6__TRANSFORMS__0__PathRemovePrefix: "/drive" + REVERSEPROXY__ROUTES__route6__TRANSFORMS__1__PathPrefix: "/api" + REVERSEPROXY__ROUTES__route7__MATCH__PATH: "/sphere/{**catch-all}" + REVERSEPROXY__ROUTES__route7__CLUSTERID: "cluster_sphere" + REVERSEPROXY__ROUTES__route7__TRANSFORMS__0__PathRemovePrefix: "/sphere" + REVERSEPROXY__ROUTES__route7__TRANSFORMS__1__PathPrefix: "/api" + REVERSEPROXY__ROUTES__route8__MATCH__PATH: "/develop/{**catch-all}" + REVERSEPROXY__ROUTES__route8__CLUSTERID: "cluster_develop" + REVERSEPROXY__ROUTES__route8__TRANSFORMS__0__PathRemovePrefix: "/develop" + REVERSEPROXY__ROUTES__route8__TRANSFORMS__1__PathPrefix: "/api" + REVERSEPROXY__CLUSTERS__cluster_ring__DESTINATIONS__destination1__ADDRESS: "http://_http.ring" + REVERSEPROXY__CLUSTERS__cluster_pass__DESTINATIONS__destination1__ADDRESS: "http://_http.pass" + REVERSEPROXY__CLUSTERS__cluster_drive__DESTINATIONS__destination1__ADDRESS: "http://_http.drive" + REVERSEPROXY__CLUSTERS__cluster_sphere__DESTINATIONS__destination1__ADDRESS: "http://_http.sphere" + REVERSEPROXY__CLUSTERS__cluster_develop__DESTINATIONS__destination1__ADDRESS: "http://_http.develop" + services__pass__http__0: "http://pass:${PASS_PORT}" + services__drive__http__0: "http://drive:${DRIVE_PORT}" + services__sphere__http__0: "http://sphere:${SPHERE_PORT}" + services__develop__http__0: "http://develop:${DEVELOP_PORT}" + OTEL_EXPORTER_OTLP_ENDPOINT: "http://docker-compose-dashboard:18889" + OTEL_EXPORTER_OTLP_PROTOCOL: "grpc" + OTEL_SERVICE_NAME: "gateway" + expose: + - "5000" + networks: + - "aspire" +networks: + aspire: + driver: "bridge" diff --git a/settings/develop.json b/settings/develop.json new file mode 100644 index 0000000..b81e2d8 --- /dev/null +++ b/settings/develop.json @@ -0,0 +1,26 @@ +{ + "Debug": true, + "BaseUrl": "http://localhost:5071", + "SiteUrl": "https://solian.app", + "Logging": { + "LogLevel": { + "Default": "Information", + "Microsoft.AspNetCore": "Warning" + } + }, + "AllowedHosts": "*", + "ConnectionStrings": { + "App": "Host=localhost;Port=5432;Database=dyson_network_dev;Username=postgres;Password=postgres;Include Error Detail=True;Maximum Pool Size=20;Connection Idle Lifetime=60" + }, + "KnownProxies": [ + "127.0.0.1", + "::1" + ], + "Etcd": { + "Insecure": true + }, + "Service": { + "Name": "DysonNetwork.Develop", + "Url": "https://localhost:7192" + } +} diff --git a/settings/drive.json b/settings/drive.json new file mode 100644 index 0000000..f025412 --- /dev/null +++ b/settings/drive.json @@ -0,0 +1,133 @@ +{ + "Debug": true, + "BaseUrl": "http://localhost:5090", + "GatewayUrl": "http://localhost:5094", + "Logging": { + "LogLevel": { + "Default": "Information", + "Microsoft.AspNetCore": "Warning" + } + }, + "AllowedHosts": "*", + "ConnectionStrings": { + "App": "Host=localhost;Port=5432;Database=dyson_drive;Username=postgres;Password=postgres;Include Error Detail=True;Maximum Pool Size=20;Connection Idle Lifetime=60" + }, + "Authentication": { + "Schemes": { + "Bearer": { + "ValidAudiences": [ + "http://localhost:5071", + "https://localhost:7099" + ], + "ValidIssuer": "solar-network" + } + } + }, + "AuthToken": { + "PublicKeyPath": "Keys/PublicKey.pem", + "PrivateKeyPath": "Keys/PrivateKey.pem" + }, + "OidcProvider": { + "IssuerUri": "https://nt.solian.app", + "PublicKeyPath": "Keys/PublicKey.pem", + "PrivateKeyPath": "Keys/PrivateKey.pem", + "AccessTokenLifetime": "01:00:00", + "RefreshTokenLifetime": "30.00:00:00", + "AuthorizationCodeLifetime": "00:30:00", + "RequireHttpsMetadata": true + }, + "Tus": { + "StorePath": "Uploads" + }, + "Storage": { + "PreferredRemote": "2adceae3-981a-4564-9b8d-5d71a211c873", + "Remote": [ + { + "Id": "minio", + "Label": "Minio", + "Region": "auto", + "Bucket": "solar-network-development", + "Endpoint": "localhost:9000", + "SecretId": "littlesheep", + "SecretKey": "password", + "EnabledSigned": true, + "EnableSsl": false + }, + { + "Id": "cloudflare", + "Label": "Cloudflare R2", + "Region": "auto", + "Bucket": "solar-network", + "Endpoint": "0a70a6d1b7128888c823359d0008f4e1.r2.cloudflarestorage.com", + "SecretId": "8ff5d06c7b1639829d60bc6838a542e6", + "SecretKey": "fd58158c5201be16d1872c9209d9cf199421dae3c2f9972f94b2305976580d67", + "EnableSigned": true, + "EnableSsl": true + } + ] + }, + "Captcha": { + "Provider": "cloudflare", + "ApiKey": "0x4AAAAAABCDUdOujj4feOb_", + "ApiSecret": "0x4AAAAAABCDUWABiJQweqlB7tYq-IqIm8U" + }, + "Notifications": { + "Topic": "dev.solsynth.solian", + "Endpoint": "http://localhost:8088" + }, + "Email": { + "Server": "smtp4dev.orb.local", + "Port": 25, + "UseSsl": false, + "Username": "no-reply@mail.solsynth.dev", + "Password": "password", + "FromAddress": "no-reply@mail.solsynth.dev", + "FromName": "Alphabot", + "SubjectPrefix": "Solar Network" + }, + "RealtimeChat": { + "Endpoint": "https://solar-network-im44o8gq.livekit.cloud", + "ApiKey": "APIs6TiL8wj3A4j", + "ApiSecret": "SffxRneIwTnlHPtEf3zicmmv3LUEl7xXael4PvWZrEhE" + }, + "GeoIp": { + "DatabasePath": "./Keys/GeoLite2-City.mmdb" + }, + "Oidc": { + "Google": { + "ClientId": "961776991058-963m1qin2vtp8fv693b5fdrab5hmpl89.apps.googleusercontent.com", + "ClientSecret": "" + }, + "Apple": { + "ClientId": "dev.solsynth.solian", + "TeamId": "W7HPZ53V6B", + "KeyId": "B668YP4KBG", + "PrivateKeyPath": "./Keys/Solarpass.p8" + }, + "Microsoft": { + "ClientId": "YOUR_MICROSOFT_CLIENT_ID", + "ClientSecret": "YOUR_MICROSOFT_CLIENT_SECRET", + "DiscoveryEndpoint": "YOUR_MICROSOFT_DISCOVERY_ENDPOINT" + } + }, + "Payment": { + "Auth": { + "Afdian": "" + }, + "Subscriptions": { + "Afdian": { + "7d17aae23c9611f0b5705254001e7c00": "solian.stellar.primary", + "7dfae4743c9611f0b3a55254001e7c00": "solian.stellar.nova", + "141713ee3d6211f085b352540025c377": "solian.stellar.supernova" + } + } + }, + "KnownProxies": [ + "127.0.0.1", + "::1" + ], + "Service": { + "Name": "DysonNetwork.Drive", + "Url": "https://localhost:7092" + } +} diff --git a/settings/pass.json b/settings/pass.json new file mode 100644 index 0000000..066d1a3 --- /dev/null +++ b/settings/pass.json @@ -0,0 +1,88 @@ +{ + "Debug": true, + "BaseUrl": "http://localhost:5216", + "SiteUrl": "https://id.solian.app", + "Logging": { + "LogLevel": { + "Default": "Information", + "Microsoft.AspNetCore": "Warning" + } + }, + "AllowedHosts": "*", + "ConnectionStrings": { + "App": "Host=localhost;Port=5432;Database=dyson_pass;Username=postgres;Password=postgres;Include Error Detail=True;Maximum Pool Size=20;Connection Idle Lifetime=60" + }, + "Authentication": { + "Schemes": { + "Bearer": { + "ValidAudiences": [ + "http://localhost:5071", + "https://localhost:7099" + ], + "ValidIssuer": "solar-network" + } + } + }, + "AuthToken": { + "CookieDomain": "localhost", + "PublicKeyPath": "Keys/PublicKey.pem", + "PrivateKeyPath": "Keys/PrivateKey.pem" + }, + "OidcProvider": { + "IssuerUri": "https://nt.solian.app", + "PublicKeyPath": "Keys/PublicKey.pem", + "PrivateKeyPath": "Keys/PrivateKey.pem", + "AccessTokenLifetime": "01:00:00", + "RefreshTokenLifetime": "30.00:00:00", + "AuthorizationCodeLifetime": "00:30:00", + "RequireHttpsMetadata": true + }, + "Captcha": { + "Provider": "cloudflare", + "ApiKey": "0x4AAAAAABCDUdOujj4feOb_", + "ApiSecret": "0x4AAAAAABCDUWABiJQweqlB7tYq-IqIm8U" + }, + "GeoIp": { + "DatabasePath": "./Keys/GeoLite2-City.mmdb" + }, + "Oidc": { + "Google": { + "ClientId": "961776991058-963m1qin2vtp8fv693b5fdrab5hmpl89.apps.googleusercontent.com", + "ClientSecret": "" + }, + "Apple": { + "ClientId": "dev.solsynth.solian", + "TeamId": "W7HPZ53V6B", + "KeyId": "B668YP4KBG", + "PrivateKeyPath": "./Keys/Solarpass.p8" + }, + "Microsoft": { + "ClientId": "YOUR_MICROSOFT_CLIENT_ID", + "ClientSecret": "YOUR_MICROSOFT_CLIENT_SECRET", + "DiscoveryEndpoint": "YOUR_MICROSOFT_DISCOVERY_ENDPOINT" + } + }, + "Payment": { + "Auth": { + "Afdian": "" + }, + "Subscriptions": { + "Afdian": { + "7d17aae23c9611f0b5705254001e7c00": "solian.stellar.primary", + "7dfae4743c9611f0b3a55254001e7c00": "solian.stellar.nova", + "141713ee3d6211f085b352540025c377": "solian.stellar.supernova" + } + } + }, + "KnownProxies": [ + "127.0.0.1", + "::1" + ], + "Service": { + "Name": "DysonNetwork.Pass", + "Url": "https://localhost:7058" + }, + "Etcd": { + "Insecure": true + } +} diff --git a/settings/ring.json b/settings/ring.json new file mode 100644 index 0000000..2ab4e9e --- /dev/null +++ b/settings/ring.json @@ -0,0 +1,50 @@ +{ + "Debug": true, + "BaseUrl": "http://localhost:5212", + "Logging": { + "LogLevel": { + "Default": "Information", + "Microsoft.AspNetCore": "Warning" + } + }, + "AllowedHosts": "*", + "ConnectionStrings": { + "App": "Host=localhost;Port=5432;Database=dyson_pusher;Username=postgres;Password=postgres;Include Error Detail=True;Maximum Pool Size=20;Connection Idle Lifetime=60" + }, + "Notifications": { + "Push": { + "Production": true, + "Google": "./Keys/Solian.json", + "Apple": { + "PrivateKey": "./Keys/Solian.p8", + "PrivateKeyId": "4US4KSX4W6", + "TeamId": "W7HPZ53V6B", + "BundleIdentifier": "dev.solsynth.solian" + } + } + }, + "Email": { + "Server": "smtp4dev.orb.local", + "Port": 25, + "UseSsl": false, + "Username": "no-reply@mail.solsynth.dev", + "Password": "password", + "FromAddress": "no-reply@mail.solsynth.dev", + "FromName": "Alphabot", + "SubjectPrefix": "Solar Network" + }, + "GeoIp": { + "DatabasePath": "./Keys/GeoLite2-City.mmdb" + }, + "KnownProxies": [ + "127.0.0.1", + "::1" + ], + "Service": { + "Name": "DysonNetwork.Ring", + "Url": "https://localhost:7259" + }, + "Etcd": { + "Insecure": true + } +} diff --git a/settings/sphere.json b/settings/sphere.json new file mode 100644 index 0000000..1157d91 --- /dev/null +++ b/settings/sphere.json @@ -0,0 +1,41 @@ +{ + "Debug": true, + "BaseUrl": "http://localhost:5071", + "SiteUrl": "https://solian.app", + "Logging": { + "LogLevel": { + "Default": "Information", + "Microsoft.AspNetCore": "Warning" + } + }, + "AllowedHosts": "*", + "ConnectionStrings": { + "App": "Host=localhost;Port=5432;Database=dyson_network;Username=postgres;Password=postgres;Include Error Detail=True;Maximum Pool Size=20;Connection Idle Lifetime=60" + }, + "GeoIp": { + "DatabasePath": "./Keys/GeoLite2-City.mmdb" + }, + "RealtimeChat": { + "Endpoint": "https://solar-network-im44o8gq.livekit.cloud", + "ApiKey": "", + "ApiSecret": "" + }, + "Translation": { + "Provider": "Tencent", + "Region": "ap-hongkong", + "ProjectId": "0", + "SecretId": "", + "SecretKey": "" + }, + "KnownProxies": [ + "127.0.0.1", + "::1" + ], + "Etcd": { + "Insecure": true + }, + "Service": { + "Name": "DysonNetwork.Sphere", + "Url": "https://localhost:7099" + } +}