-
Notifications
You must be signed in to change notification settings - Fork 76
feat(reference): add deployment profiles for environment-specific con… #1611
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
Open
vadika
wants to merge
1
commit into
tiiuae:main
Choose a base branch
from
vadika:deployment-profile
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
85d0197 to
1c491a6
Compare
1c491a6 to
6fa7ed7
Compare
6fa7ed7 to
835d707
Compare
835d707 to
30efd8e
Compare
30efd8e to
aef8140
Compare
aef8140 to
127e602
Compare
127e602 to
0daff81
Compare
0daff81 to
4347a12
Compare
4347a12 to
038958e
Compare
038958e to
2de1c86
Compare
2de1c86 to
3cea890
Compare
3cea890 to
4f7c29a
Compare
4f7c29a to
626d912
Compare
626d912 to
ee7a4d2
Compare
ee7a4d2 to
4fc84e1
Compare
…figuration
Introduce a deployment profile system that separates deployment-specific
settings (logging endpoints, security policies, networking) from use-case
profiles.
This allows the same Ghaf build to be customized for different deployment
environments without modifying core profile definitions.
New files:
- modules/reference/deployments/default.nix: Core options for logging,
business-vm, networking, security, features, and branding
- modules/reference/deployments/tii-internal.nix: TII internal deployment
- modules/reference/deployments/demo.nix: Demo/conference deployment
- modules/reference/deployments/flake-module.nix: Flake integration
Usage:
ghaf.reference.deployments.profiles.tii-internal.enable = true;
The mvp-user-trial profile now reads from deployment settings when available,
falling back to current defaults for backward compatibility.
WireGuard VPN:
- wireguard.enable: Toggle WireGuard GUI (default: true for backward compat)
- wireguard.enabledVms: List of VMs where WireGuard GUI is enabled
- wireguard.preConfiguredPeers: Pre-configured WireGuard peers
Identity Provider (AD/LDAP):
- identity.provider: Select auth backend (none/azure-ad/ldap/local)
- identity.azure.*: Azure AD configuration (tenantId, clientId, domain)
- identity.ldap.*: LDAP configuration (serverUri, baseDn, bindDn, etc.)
Update mvp-user-trial.nix to read wireguard-gui setting from deployment
profile, allowing per-deployment control over VPN availability.
Example usage:
ghaf.reference.deployments.profiles.tii-internal.enable = true;
# WireGuard enabled by default for tii-internal
ghaf.reference.deployments.profiles.demo.enable = true;
# WireGuard disabled for demo deployments"
Extend deployment profiles with additional deployment-specific settings:
Proxy/Allowlist Configuration:
- proxy.enable: Toggle proxy server
- proxy.bindPort: Proxy listen port (default: 3128)
- proxy.microsoftEndpointsUrl: MS 365 endpoints API
- proxy.allowlistRepoUrl: GitHub repo for allowed URLs
- proxy.allowlistRefreshInterval: Allowlist refresh schedule
GlobalProtect VPN:
- globalProtect.enable: Toggle VPN client in business-vm
- globalProtect.serverAddress: VPN server IP/hostname
- globalProtect.portalAddress: Optional portal address
Gala (Android-in-Cloud):
- gala.enable: Toggle Gala application
- gala.serverUrl: Gala instance URL
Development/SSH Access:
- development.authorizedSshKeys: Per-deployment SSH keys
- development.enableSshAccess: Toggle SSH access
- development.enableDebugTools: Include debug tools
SSH Keys:
- Move TII developer SSH keys from authorizedSshKeys.nix to tii-internal.nix
- keys.nix now reads from deployments.development.authorizedSshKeys
- authorizedSshKeys.nix provides backward compatibility by defaulting
to the deployment profile value
Admin Password:
- Add users.adminPassword and users.adminHashedPassword to deployment options
- accounts.nix now reads password from deployment profile
- Default password remains 'ghaf' for backward compatibility
- Production deployments can use hashed passwords
This allows different deployments to have:
- Different SSH key sets (TII internal vs customer vs demo)
- Different admin passwords per deployment
- Proper separation of credentials from code"
Wire up existing modules to use deployment settings:
- 3proxy-config.nix: Uses proxy.* settings for URLs and refresh interval
- business.nix: Conditionally includes Gala/VPN based on deployment,
uses deployment VPN server for firewall rules
Deployment profile updates:
- tii-internal: All features enabled with TII defaults
- demo: VPN, Gala, SSH disabled for simpler demos"
Signed-off-by: vadik likholetov <vadikas@gmail.com>
4fc84e1 to
b6b987d
Compare
|
Orin-AGX is failing in |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
…figuration
Introduce a deployment profile system that separates deployment-specific
settings (logging endpoints, security policies, networking) from use-case
profiles.
This allows the same Ghaf build to be customized for different deployment
environments without modifying core profile definitions.
New files:
business-vm, networking, security, features, and branding
Usage:
ghaf.reference.deployments.profiles.tii-internal.enable = true;
The mvp-user-trial profile now reads from deployment settings when available,
falling back to current defaults for backward compatibility.
WireGuard VPN:
Identity Provider (AD/LDAP):
Update mvp-user-trial.nix to read wireguard-gui setting from deployment
profile, allowing per-deployment control over VPN availability.
Example usage:
ghaf.reference.deployments.profiles.tii-internal.enable = true;
# WireGuard enabled by default for tii-internal
Description of Changes
Type of Change
Related Issues / Tickets
Checklist
make-checksand it passesTesting Instructions
Applicable Targets
aarch64aarch64x86_64x86_64x86_64Installation Method
nixos-rebuild ... switchTest Steps To Verify:
Nothing should change.