mirror of
https://github.com/gravitational/teleport.git
synced 2026-11-03 16:14:19 +08:00
* Add screenshots for azure IAM setup * Update azure mysql postgres guide to explain discovery * Update db service config yaml reference * Update docs/pages/database-access/guides/azure-postgres-mysql.mdx Co-authored-by: STeve (Xin) Huang <xin.huang@goteleport.com> * Fix typo in admonition type * Redact IDs in azure screenshots * Clarify that role assignment applies to either principal type * Advise restarting db service after checking credentials * optimize images * Update docs/pages/database-access/guides/azure-postgres-mysql.mdx Co-authored-by: Alex Fornuto <alex.fornuto@goteleport.com> * Update docs/pages/database-access/guides/azure-postgres-mysql.mdx Co-authored-by: Alex Fornuto <alex.fornuto@goteleport.com> * Update docs/pages/database-access/guides/azure-postgres-mysql.mdx Co-authored-by: Alex Fornuto <alex.fornuto@goteleport.com> Co-authored-by: STeve (Xin) Huang <xin.huang@goteleport.com> Co-authored-by: alexfornuto <alex@fornuto.com> Co-authored-by: Alex Fornuto <alex.fornuto@goteleport.com>
145 lines
5.7 KiB
YAML
145 lines
5.7 KiB
YAML
db_service:
|
|
# Enables the Database Service.
|
|
enabled: "yes"
|
|
|
|
# Matchers for database resources created with "tctl create" command.
|
|
resources:
|
|
- labels:
|
|
"*": "*"
|
|
|
|
# Matchers for registering AWS-hosted databases.
|
|
aws:
|
|
# Database types. Valid options are:
|
|
# 'rds' - discovers and registers AWS RDS and Aurora databases.
|
|
# 'redshift' - discovers and registers AWS Redshift databases.
|
|
# 'elasticache' - discovers and registers AWS ElastiCache Redis databases.
|
|
# 'memorydb' - discovers and registers AWS MemoryDB Redis databases.
|
|
- types: ["rds", "redshift", "elasticache", "memorydb"]
|
|
# AWS regions to register databases from.
|
|
regions: ["us-west-1", "us-east-2"]
|
|
# AWS resource tags to match when registering databases.
|
|
tags:
|
|
"*": "*"
|
|
|
|
# Matchers for registering Azure-hosted databases.
|
|
azure:
|
|
# Database types. Valid options are:
|
|
# 'mysql' - discovers and registers Azure MySQL single-server databases.
|
|
# 'postgres' - discovers and registers Azure PostgreSQL single-server databases.
|
|
- types: ["mysql", "postgres"]
|
|
# Azure regions to register databases from. Valid options are:
|
|
# '*' - discovers databases in all regions (default).
|
|
# Any valid Azure region name. List all valid regions using the Azure "az" cli: `az account list-locations -o table`
|
|
regions: ["eastus", "westus"]
|
|
# Azure subscription IDs to register databases from. Valid options are:
|
|
# '*' - discovers databases in all subscriptions (default).
|
|
subscriptions: ["11111111-2222-3333-4444-555555555555"]
|
|
# Azure resource groups to register databases from. Valid options are:
|
|
# '*' - discovers databases in all resource groups within configured subscription(s) (default).
|
|
resource_groups: ["group1", "group2"]
|
|
# Azure resource tags to match when registering databases.
|
|
tags:
|
|
"*": "*"
|
|
|
|
# Lists statically registered databases proxied by this agent.
|
|
databases:
|
|
# Name of the database proxy instance, used to reference in CLI.
|
|
- name: "prod"
|
|
|
|
# Free-form description of the database proxy instance.
|
|
description: "Production database"
|
|
|
|
# Database protocol. Can be: "postgres", "mysql", "mongodb", "cockroachdb", "sqlserver", or "redis".
|
|
protocol: "postgres"
|
|
|
|
# Database connection endpoint. Must be reachable from Database Service.
|
|
uri: "postgres.example.com:5432"
|
|
|
|
# Optional TLS configuration.
|
|
tls:
|
|
# TLS verification mode. Valid options are:
|
|
# 'verify-full' - performs full certificate validation (default).
|
|
# 'verify-ca' - the same as `verify-full`, but skips the server name validation.
|
|
# 'insecure' - accepts any certificate provided by database (not recommended).
|
|
mode: verify-full
|
|
# Optional database DNS server name. It allows to override the DNS name on
|
|
# a client certificate when connecting to a database.
|
|
# Use only with 'verify-full' mode.
|
|
server_name: db.example.com
|
|
# Optional path to the CA used to validate the database certificate.
|
|
ca_cert_file: /path/to/pem
|
|
|
|
# MySQL only options.
|
|
mysql:
|
|
# The default MySQL server version reported by Teleport Proxy.
|
|
# When this option is set the Database Agent doesn't try to check the MySQL server version.
|
|
server_version: 8.0.28
|
|
|
|
# Optional AWS configuration for AWS hosted databases. AWS region- and
|
|
# service-specific configurations can usually be auto-detected from the
|
|
# endpoint.
|
|
aws:
|
|
# Region the database is deployed in.
|
|
region: "us-east-1"
|
|
# Redshift-specific configuration.
|
|
redshift:
|
|
# Redshift cluster identifier.
|
|
cluster_id: "redshift-cluster-1"
|
|
# RDS-specific configuration.
|
|
rds:
|
|
# RDS instance identifier.
|
|
instance_id: "rds-instance-1"
|
|
# RDS Aurora cluster identifier.
|
|
cluster_id: "aurora-cluster-1"
|
|
# ElastiCache-specific configuration.
|
|
elasticache:
|
|
# ElastiCache replication group identifier.
|
|
replication_group_id: "elasticache-replication-group-1"
|
|
# MemoryDB-specific configuration.
|
|
memorydb:
|
|
# MemoryDB cluster name.
|
|
cluster_name: "memorydb-cluster-1"
|
|
|
|
# Optional AWS Secrets Manager configuration for managing ElastiCache
|
|
# or MemoryDB users.
|
|
#
|
|
# IMPORTANT: please make sure databases sharing the same Teleport-managed
|
|
# users have the same secret_store configuration. The configuration
|
|
# should also be consistent across all Database Services in High
|
|
# Availability (HA) mode.
|
|
secret_store:
|
|
# Prefix to all secrets created by the service. Defaults to 'teleport/'.
|
|
key_prefix: "teleport/"
|
|
# KMS Key ID used for secret encryption and description. If not
|
|
# specified, Secrets Manager uses AWS managed key 'aws/secretsmanager'
|
|
# by default.
|
|
kms_key_id: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
|
|
|
|
# GCP specific configuration for Cloud SQL databases.
|
|
gcp:
|
|
# GCP project ID.
|
|
project_id: "xxx-1234"
|
|
# Cloud SQL instance ID.
|
|
instance_id: "example"
|
|
|
|
# Settings specific to Active Directory authentication e.g. for SQL Server.
|
|
ad:
|
|
# Path to Kerberos keytab file.
|
|
keytab_file: /path/to/keytab
|
|
# Active Directory domain name.
|
|
domain: EXAMPLE.COM
|
|
# Service Principal Name to obtain Kerberos tickets for.
|
|
spn: MSSQLSvc/ec2amaz-4kn05du.dbadir.teleportdemo.net:1433
|
|
# Optional path to Kerberos configuration file. Defaults to /etc/krb5.conf.
|
|
krb5_file: /etc/krb5.conf
|
|
|
|
# Static labels to assign to the database. Used in RBAC.
|
|
static_labels:
|
|
env: "prod"
|
|
|
|
# Dynamic labels ("commands"). Used in RBAC.
|
|
dynamic_labels:
|
|
- name: "hostname"
|
|
command: ["hostname"]
|
|
period: 1m0s
|