-
Notifications
You must be signed in to change notification settings - Fork 0
Add Zot registry support and enhance reverse proxy #47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| { | ||
| "permissions": { | ||
| "allow": [ | ||
| "Bash(docker stop:*)", | ||
| "Bash(docker rm:*)" | ||
| ] | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -487,3 +487,5 @@ $RECYCLE.BIN/ | |
|
|
||
| # Intellij | ||
| *.iml | ||
| *.db | ||
| /cli/src/Vdk/images | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| { | ||
| "distSpecVersion": "1.1.0", | ||
| "storage": { | ||
| "rootDirectory": "/var/lib/registry", | ||
| "gc": true, | ||
| "gcDelay": "1h", | ||
| "gcInterval": "24h" | ||
| }, | ||
| "http": { | ||
| "address": "0.0.0.0", | ||
| "port": "5000" | ||
| }, | ||
| "log": { | ||
| "level": "info" | ||
| }, | ||
| "extensions": { | ||
| "ui": { | ||
| "enable": true | ||
| }, | ||
| "search": { | ||
| "enable": true, | ||
| "cve": { | ||
| "updateInterval": "24h" | ||
| } | ||
| } | ||
| } | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -3,11 +3,11 @@ namespace Vdk.Constants; | |
| public static class Containers | ||
| { | ||
| public const string RegistryName = "vega-registry"; | ||
| public const string RegistryImage = "registry:2"; | ||
| public const string RegistryImage = "ghcr.io/project-zot/zot-linux-amd64:v2.1.0"; | ||
| public const int RegistryContainerPort = 5000; | ||
| public const int RegistryHostPort = 50000; | ||
| public const int RegistryHostPort = 5000; | ||
|
||
| public const string ProxyName = "vega-proxy"; | ||
| public const string ProxyImage = "nginx:latest"; | ||
| public const string ProxyImage = "nginx:1.27"; | ||
| public const string CloudProviderKindName = "cloud-provider-kind"; | ||
| public const string CloudProviderKindImage = "registry.k8s.io/cloud-provider-kind/cloud-controller-manager:v0.6.0"; | ||
| } | ||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -8,13 +8,30 @@ public class DockerHubClient(IDockerEngine docker, IConsole console) : IHubClien | |||||||||||||||||
| public void CreateRegistry() | ||||||||||||||||||
| { | ||||||||||||||||||
| if (ExistRegistry()) return; | ||||||||||||||||||
| console.WriteLine("Creating Vega VDK Registry"); | ||||||||||||||||||
| console.WriteLine("Creating Vega VDK Registry (Zot)"); | ||||||||||||||||||
| console.WriteLine(" - This may take a few minutes..."); | ||||||||||||||||||
|
|
||||||||||||||||||
| // Mount the config file and images directory for persistence | ||||||||||||||||||
| var configFile = new FileInfo(Path.Combine("ConfigMounts", "zot-config.json")); | ||||||||||||||||||
| var imagesDir = new DirectoryInfo("images"); | ||||||||||||||||||
|
|
||||||||||||||||||
|
||||||||||||||||||
| // Ensure config file exists | |
| if (!configFile.Exists) | |
| { | |
| console.WriteWarning($"Config file '{configFile.FullName}' not found. Skipping Vega VDK Registry creation."); | |
| return; | |
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -60,7 +60,7 @@ | |
| if (tuple is { isVdk: true, master: not null } && tuple.master.HttpsHostPort.HasValue) | ||
| { | ||
| _console.WriteLine($" - Adding cluster {tuple.name} to reverse proxy configuration"); | ||
| UpsertCluster(tuple.name, tuple.master.HttpsHostPort.Value, tuple.master.HttpHostPort.Value, false); | ||
| } | ||
| }); | ||
| } | ||
|
|
@@ -103,7 +103,7 @@ | |
| return true; | ||
| } | ||
|
|
||
| return false; | ||
| } | ||
|
|
||
| private void InitConfFile(FileInfo conf) | ||
|
|
@@ -175,6 +175,11 @@ | |
| writer.WriteLine(" proxy_set_header X-Real-IP $remote_addr;"); | ||
| writer.WriteLine(" proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;"); | ||
| writer.WriteLine(" proxy_set_header X-Forwarded-Proto $scheme;"); | ||
| writer.WriteLine(); | ||
| writer.WriteLine(" # Support WebSocket protocol upgrades"); | ||
| writer.WriteLine(" proxy_http_version 1.1;"); | ||
| writer.WriteLine(" proxy_set_header Upgrade $http_upgrade;"); | ||
| writer.WriteLine(" proxy_set_header Connection \"upgrade\";"); | ||
| writer.WriteLine(" }"); | ||
| writer.WriteLine("}"); | ||
| writer.WriteLine($"##### END {clusterName}"); | ||
|
|
@@ -415,6 +420,43 @@ | |
| throw new NotImplementedException(); | ||
| } | ||
|
|
||
| public void RegenerateConfigs() | ||
| { | ||
| var conf = new FileInfo(NginxConf); | ||
| if (!conf.Exists) | ||
| { | ||
| _console.WriteWarning("Nginx configuration file does not exist. Run 'vega create proxy' first."); | ||
| return; | ||
| } | ||
|
|
||
| _console.WriteLine("Regenerating nginx configuration for all VDK clusters..."); | ||
|
|
||
| // Reinitialize the conf file with the hub server block | ||
| conf.Delete(); | ||
| InitConfFile(conf); | ||
|
|
||
| // Iterate through all VDK clusters and add their server blocks | ||
| var clusters = _kind.ListClusters(); | ||
| var vdkClusters = clusters.Where(c => c.isVdk && c.master != null && c.master.HttpsHostPort.HasValue).ToList(); | ||
|
|
||
| if (vdkClusters.Count == 0) | ||
| { | ||
| _console.WriteLine("No VDK clusters found to configure."); | ||
| ReloadConfigs(); | ||
| return; | ||
| } | ||
|
|
||
| foreach (var cluster in vdkClusters) | ||
| { | ||
| _console.WriteLine($" Adding cluster '{cluster.name}' to nginx configuration"); | ||
| PatchNginxConfig(cluster.name, cluster.master!.HttpsHostPort!.Value); | ||
| } | ||
|
|
||
| _console.WriteLine($"Regenerated configuration for {vdkClusters.Count} cluster(s)."); | ||
| ReloadConfigs(); | ||
| _console.WriteLine("Nginx configuration reloaded."); | ||
| } | ||
|
Comment on lines
+423
to
+458
|
||
|
|
||
| private static int GetEnvironmentVariableAsInt(string variableName, int defaultValue = 0) | ||
| { | ||
| string strValue = Environment.GetEnvironmentVariable(variableName); | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -40,6 +40,13 @@ | |
| <None Update="ConfigMounts\hosts.toml"> | ||
| <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> | ||
| </None> | ||
| <None Update="ConfigMounts\zot-config.json"> | ||
| <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> | ||
| </None> | ||
| </ItemGroup> | ||
|
|
||
| <ItemGroup> | ||
| <Content Include="images\**" CopyToOutputDirectory="PreserveNewest" LinkBase="images" /> | ||
|
||
| </ItemGroup> | ||
|
|
||
| </Project> | ||
|
|
||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,42 @@ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| server { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| listen 443 ssl; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| listen [::]:443 ssl; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| http2 on; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| server_name hub.dev-k8s.cloud; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ssl_certificate /etc/certs/fullchain.pem; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ssl_certificate_key /etc/certs/privkey.pem; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| location / { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| client_max_body_size 0; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| proxy_pass http://host.docker.internal:5000; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| proxy_set_header Host $host; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| proxy_set_header X-Real-IP $remote_addr; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| proxy_set_header X-Forwarded-Proto $scheme; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ##### START idp | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| server { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| listen 443 ssl; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| listen [::]:443 ssl; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| http2 on; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| server_name idp.dev-k8s.cloud; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ssl_certificate /etc/certs/fullchain.pem; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ssl_certificate_key /etc/certs/privkey.pem; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| location / { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| proxy_pass https://host.docker.internal:40237; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| proxy_set_header Host $host; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| proxy_set_header X-Real-IP $remote_addr; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| proxy_set_header X-Forwarded-Proto $scheme; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| # Support WebSocket protocol upgrades | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| proxy_http_version 1.1; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| proxy_set_header Upgrade $http_upgrade; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| proxy_set_header Connection "upgrade"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+1
to
+40
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| server { | |
| listen 443 ssl; | |
| listen [::]:443 ssl; | |
| http2 on; | |
| server_name hub.dev-k8s.cloud; | |
| ssl_certificate /etc/certs/fullchain.pem; | |
| ssl_certificate_key /etc/certs/privkey.pem; | |
| location / { | |
| client_max_body_size 0; | |
| proxy_pass http://host.docker.internal:5000; | |
| proxy_set_header Host $host; | |
| proxy_set_header X-Real-IP $remote_addr; | |
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| proxy_set_header X-Forwarded-Proto $scheme; | |
| } | |
| } | |
| ##### START idp | |
| server { | |
| listen 443 ssl; | |
| listen [::]:443 ssl; | |
| http2 on; | |
| server_name idp.dev-k8s.cloud; | |
| ssl_certificate /etc/certs/fullchain.pem; | |
| ssl_certificate_key /etc/certs/privkey.pem; | |
| location / { | |
| proxy_pass https://host.docker.internal:40237; | |
| proxy_set_header Host $host; | |
| proxy_set_header X-Real-IP $remote_addr; | |
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| proxy_set_header X-Forwarded-Proto $scheme; | |
| # Support WebSocket protocol upgrades | |
| proxy_http_version 1.1; | |
| proxy_set_header Upgrade $http_upgrade; | |
| proxy_set_header Connection "upgrade"; | |
| } | |
| } | |
| # vega.conf - example reverse proxy configuration | |
| # | |
| # This file is intentionally kept as a *template* configuration and should | |
| # not contain environment-specific or runtime-generated values. | |
| # | |
| # In many deployments, a component such as ReverseProxyClient.InitConfFile | |
| # is responsible for generating the actual configuration used at runtime. | |
| # To avoid merge conflicts and leaking environment details, copy this file | |
| # and customize it outside of version control (for example, in a deployment | |
| # repository or via your configuration management system). | |
| # | |
| # To use this template: | |
| # 1. Copy it to an appropriate location for your environment. | |
| # 2. Replace placeholder values (example.com, backend:port, cert paths). | |
| # 3. Enable or adjust the server blocks as needed. | |
| # | |
| # NOTE: All configuration below is commented out and uses placeholder | |
| # values. Adjust and uncomment in your own, non-committed copy. | |
| # server { | |
| # listen 443 ssl; | |
| # listen [::]:443 ssl; | |
| # http2 on; | |
| # server_name app.example.com; | |
| # | |
| # # Paths to your TLS certificate and key for this host. | |
| # # Replace with the correct locations for your environment. | |
| # ssl_certificate /path/to/your/fullchain.pem; | |
| # ssl_certificate_key /path/to/your/privkey.pem; | |
| # | |
| # location / { | |
| # # Adjust maximum request body size to your needs. | |
| # client_max_body_size 0; | |
| # | |
| # # Upstream application endpoint. | |
| # # Replace "backend-app" and port with your actual backend. | |
| # proxy_pass http://backend-app:5000; | |
| # | |
| # proxy_set_header Host $host; | |
| # proxy_set_header X-Real-IP $remote_addr; | |
| # proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| # proxy_set_header X-Forwarded-Proto $scheme; | |
| # } | |
| # } | |
| ##### START idp (example Identity Provider endpoint) | |
| # server { | |
| # listen 443 ssl; | |
| # listen [::]:443 ssl; | |
| # http2 on; | |
| # server_name idp.example.com; | |
| # | |
| # # Paths to your TLS certificate and key for this host. | |
| # ssl_certificate /path/to/your/fullchain.pem; | |
| # ssl_certificate_key /path/to/your/privkey.pem; | |
| # | |
| # location / { | |
| # # Upstream IDP/authorization server endpoint. | |
| # proxy_pass https://identity-provider:443; | |
| # | |
| # proxy_set_header Host $host; | |
| # proxy_set_header X-Real-IP $remote_addr; | |
| # proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| # proxy_set_header X-Forwarded-Proto $scheme; | |
| # | |
| # # Support WebSocket protocol upgrades, if required by the IDP. | |
| # proxy_http_version 1.1; | |
| # proxy_set_header Upgrade $http_upgrade; | |
| # proxy_set_header Connection "upgrade"; | |
| # } | |
| # } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The .claude/settings.local.json file appears to contain local development configuration and should be excluded from version control by adding it to .gitignore. Local settings files are typically environment-specific and should not be shared across different development environments.