[PR #5765] [management] Add static connectors to combined server #28490

Closed
opened 2026-08-05 08:06:27 -04:00 by saavagebueno · 0 comments
Owner

Original Pull Request: https://github.com/netbirdio/netbird/pull/5765

State: closed
Merged: No


Describe your changes

With the release of #5586 we now allow users to setup static connectors through management.json, which allows them to provision dex IdP entries directly through config, this PR introduces the same capability for the combined server.

Example config.yaml:


server:
  listenAddress: ":80"
  exposedAddress: "https://example.com:443"
  stunPorts:
    - 3478
  metricsPort: 9090
  healthcheckAddress: ":9000"
  logLevel: "info"
  logFile: "console"

  authSecret: "secret"
  dataDir: "/var/lib/netbird"

  auth:
    localAuthDisabled: true
    issuer: "https://example.com/oauth2"
    signKeyRefreshEnabled: true
    dashboardRedirectURIs:
      - "https://example.com/nb-auth"
      - "https://example.com/nb-silent-auth"
    cliRedirectURIs:
      - "http://localhost:53000/"
    staticConnectors:
      - type: keycloak
        name: keycloak
        id: keycloak
        config:
          issuer: "https://keycloak.domain.com/realms/netbird"
          clientID: clientId
          clientSecret: secret
          redirectURI: https://example.com/oauth2/callback


      - type: authentik
        name: authentik
        id: authentik
        config:
          issuer: https://authentik.domain.com/application/o/netbird/
          clientID: clientId
          clientSecret: secret
          redirectURI: https://example.com/oauth2/callback

  reverseProxy:
    trustedHTTPProxies:
      - "172.30.0.10/32"

  store:
    engine: "sqlite"
    encryptionKey: secretKey

Caveats

  • config.yaml parameters will override any "dashboard" change if the management server restarts
  • first user to log-in is the owner, no way to change this programatically

Checklist

  • Is it a bug fix
  • Is a typo/documentation fix
  • Is a feature enhancement
  • It is a refactor
  • Created tests that fail without the change (if possible)

By submitting this pull request, you confirm that you have read and agree to the terms of the Contributor License Agreement.

Documentation

Select exactly one:

  • I added/updated documentation for this change
  • Documentation is not needed for this change (explain why)

Docs PR URL (required if "docs added" is checked)

Paste the PR link from https://github.com/netbirdio/docs here:

https://github.com/netbirdio/docs/pull/__

Summary by CodeRabbit

  • New Features

    • Added support for configuring static identity provider connectors through configuration settings, providing enhanced flexibility in authentication provider setup.
  • Refactor

    • Updated internal type declarations to align with modern standards and improve code consistency.
**Original Pull Request:** https://github.com/netbirdio/netbird/pull/5765 **State:** closed **Merged:** No --- ## Describe your changes With the release of #5586 we now allow users to setup static connectors through management.json, which allows them to provision dex IdP entries directly through config, this PR introduces the same capability for the combined server. Example config.yaml: ```yaml server: listenAddress: ":80" exposedAddress: "https://example.com:443" stunPorts: - 3478 metricsPort: 9090 healthcheckAddress: ":9000" logLevel: "info" logFile: "console" authSecret: "secret" dataDir: "/var/lib/netbird" auth: localAuthDisabled: true issuer: "https://example.com/oauth2" signKeyRefreshEnabled: true dashboardRedirectURIs: - "https://example.com/nb-auth" - "https://example.com/nb-silent-auth" cliRedirectURIs: - "http://localhost:53000/" staticConnectors: - type: keycloak name: keycloak id: keycloak config: issuer: "https://keycloak.domain.com/realms/netbird" clientID: clientId clientSecret: secret redirectURI: https://example.com/oauth2/callback - type: authentik name: authentik id: authentik config: issuer: https://authentik.domain.com/application/o/netbird/ clientID: clientId clientSecret: secret redirectURI: https://example.com/oauth2/callback reverseProxy: trustedHTTPProxies: - "172.30.0.10/32" store: engine: "sqlite" encryptionKey: secretKey ``` ### Caveats - config.yaml parameters will override any "dashboard" change if the management server restarts - first user to log-in is the owner, no way to change this programatically ### Checklist - [ ] Is it a bug fix - [ ] Is a typo/documentation fix - [x] Is a feature enhancement - [ ] It is a refactor - [ ] Created tests that fail without the change (if possible) > By submitting this pull request, you confirm that you have read and agree to the terms of the [Contributor License Agreement](https://github.com/netbirdio/netbird/blob/main/CONTRIBUTOR_LICENSE_AGREEMENT.md). ## Documentation Select exactly one: - [x] I added/updated documentation for this change - [ ] Documentation is **not needed** for this change (explain why) ### Docs PR URL (required if "docs added" is checked) Paste the PR link from https://github.com/netbirdio/docs here: https://github.com/netbirdio/docs/pull/__ <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added support for configuring static identity provider connectors through configuration settings, providing enhanced flexibility in authentication provider setup. * **Refactor** * Updated internal type declarations to align with modern standards and improve code consistency. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
saavagebueno added the pull-request label 2026-08-05 08:06:27 -04:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: DYNR/netbird#28490