Files
2026-03-24 16:34:41 +01:00

193 lines
5.0 KiB
YAML

---
# defaults/main.yml - Default variables for the NetBird Ansible role
# NetBird API connection settings
# Can also be set via environment variables: NETBIRD_API_URL, NETBIRD_API_TOKEN
netbird_api_url: ""
netbird_api_token: ""
netbird_validate_certs: true
# User management
netbird_users: []
# Example:
# netbird_users:
# - email: "user@example.com"
# name: "John Doe"
# role: "user" # admin, user, owner
# auto_groups: []
# is_service_user: false
# state: present
# Service users (for automation)
netbird_service_users: []
# Example:
# netbird_service_users:
# - name: "automation-service"
# role: "admin"
# auto_groups: []
# state: present
# Group management
netbird_groups: []
# Example:
# netbird_groups:
# - name: "developers"
# peers: []
# state: present
# - name: "production"
# peers: []
# state: present
# Setup key management
netbird_setup_keys: []
# Example:
# netbird_setup_keys:
# - name: "new-server-key"
# key_type: "one-off" # one-off, reusable
# expires_in: 86400 # 24 hours in seconds
# auto_groups: []
# ephemeral: false
# state: present
# Policy management
netbird_policies: []
# Example:
# netbird_policies:
# - name: "allow-all"
# description: "Allow all traffic between all peers"
# enabled: true
# rules:
# - name: "all-to-all"
# sources:
# - "group-id-1"
# destinations:
# - "group-id-2"
# bidirectional: true
# protocol: "all"
# action: "accept"
# state: present
# Network management (with routers and resources for full routing support)
netbird_networks: []
# Example:
# netbird_networks:
# - name: "office-network"
# description: "Main office network"
# routers:
# - peer: "gateway-peer-id" # Use either peer or peer_groups
# metric: 100 # Lower = higher priority
# masquerade: true # NAT traffic through this router
# - peer_groups: # For HA with multiple routers
# - "backup-gateways-group"
# metric: 200
# masquerade: true
# resources:
# - address: "172.16.0.0/16" # Network CIDR
# name: "internal-range"
# description: "All internal IPs"
# groups: # Who can access this resource
# - "all-users-group-id"
# - address: "192.168.0.0/16"
# name: "private-networks"
# groups:
# - "developers-group-id"
# state: present
#
# - name: "simple-network"
# description: "Network without routing (container only)"
# state: present
#
# - name: "domain-routing"
# description: "Route traffic based on domain names"
# routers:
# - peer: "dns-gateway-peer-id"
# metric: 100
# masquerade: true
# resources:
# - address: "internal.example.com" # Single domain
# name: "internal-portal"
# groups:
# - "all-users-group-id"
# - address: "*.corp.example.com" # Wildcard for all subdomains
# name: "corp-subdomains"
# groups:
# - "employees-group-id"
# state: present
# Route management (deprecated API, prefer networks with routers/resources)
netbird_routes: []
# Example:
# netbird_routes:
# - network_id: "internal-route"
# network: "172.16.0.0/16"
# description: "Route to internal network"
# peer_id: "gateway-peer-id"
# metric: 100
# masquerade: true
# enabled: true
# groups: []
# state: present
# DNS nameserver group management
netbird_dns_nameserver_groups: []
# Example:
# netbird_dns_nameserver_groups:
# - name: "corporate-dns"
# description: "Corporate DNS servers"
# nameservers:
# - ip: "10.0.0.53"
# ns_type: "udp"
# port: 53
# groups: []
# domains: []
# enabled: true
# primary: false
# state: present
# DNS settings
netbird_dns_disabled_management_groups: []
# Posture check management
netbird_posture_checks: []
# Example:
# netbird_posture_checks:
# - name: "minimum-version"
# description: "Require minimum NetBird version"
# checks:
# nb_version_check:
# min_version: "0.25.0"
# state: present
# Identity provider management
netbird_identity_providers: []
# Example:
# netbird_identity_providers:
# - name: "google-idp"
# type: "google" # entra, google, microsoft, oidc, okta, pocketid, zitadel
# issuer: "https://accounts.google.com"
# client_id: "your-client-id"
# client_secret: "your-client-secret"
# state: present
# User invite management
netbird_invites: []
# Example:
# netbird_invites:
# - email: "newuser@example.com"
# name: "New User"
# role: "user" # admin, user
# auto_groups: []
# expires_in: 604800 # 7 days in seconds
# state: present
# Account settings
netbird_account_settings: {}
# Example:
# netbird_account_settings:
# peer_login_expiration_enabled: true
# peer_login_expiration: 86400
# peer_inactivity_expiration_enabled: false
# jwt_groups_enabled: false
# dns_domain: "netbird.example.com"