Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 15 additions & 44 deletions docs/pages/database-access/guides/cassandra-self-hosted.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ This guide will help you to:
- Connect to your database through Teleport.

<ScopedBlock scope={["oss", "enterprise"]}>
![Teleport Database Access Redis Self-Hosted](../../../img/database-access/guides/cassandra_selfhosted.png)
![Teleport Database Access Cassandra Self-Hosted](../../../img/database-access/guides/cassandra_selfhosted.png)
</ScopedBlock>
<ScopedBlock scope={["cloud"]}>
![Teleport Database Access Redis Cloud](../../../img/database-access/guides/cassandra_cloud.png)
![Teleport Database Access Cassandra Cloud](../../../img/database-access/guides/cassandra_cloud.png)
</ScopedBlock>

## Prerequisites
Expand All @@ -38,55 +38,26 @@ This guide will help you to:

(!docs/pages/includes/database-access/token.mdx!)

Install Teleport on the host where you will run the Teleport Database Service:
Install and configure Teleport where you will run the Teleport Database Service:

(!docs/pages/includes/install-linux.mdx!)

<ScopedBlock scope={["oss", "enterprise"]}>

Start the Teleport Database Service, pointing the `--auth-server` flag to the
address of your Teleport Proxy Service:

```code
$ teleport db start \
--token=/tmp/token \
--auth-server=teleport.example.com:3080 \
--name=example-cassandra \
--protocol=cassandra \
--uri=cassandra.example.com:9042 \
--labels=env=dev
```

<Admonition type="note">

The `--auth-server` flag must point to the Teleport cluster's Proxy Service
endpoint because the Database Service always connects back to the cluster over a
reverse tunnel.
<Tabs>
<TabItem label="Linux Server">

</Admonition>
(!docs/pages/includes/install-linux.mdx!)

</ScopedBlock>
<ScopedBlock scope={["cloud"]}>
(!docs/pages/includes/database-access/db-configure-start.mdx dbName="cassandra" dbProtocol="cassandra" databaseAddress="cassandra.example.com:9042" !)

Start the Teleport Database Service, pointing the `--auth-server` flag to the
address of your Teleport Cloud tenant:
</TabItem>
<TabItem label="Kubernetes Cluster">
Teleport provides Helm charts for installing the Teleport Database Service in Kubernetes Clusters.

```code
$ teleport db start \
--token=/tmp/token \
--auth-server=mytenant.teleport.sh:443 \
--name=example-cassandra \
--protocol=cassandra \
--uri=cassandra.example.com:9042 \
--labels=env=dev
```
(!docs/pages/kubernetes-access/helm/includes/helm-repo-add.mdx!)

</ScopedBlock>
(!docs/pages/includes/database-access/db-helm-install.mdx dbName="cassandra" dbProtocol="cassandra" databaseAddress="cassandra.example.com:9042" !)
</TabItem>
</Tabs>

<Admonition type="tip">
You can start the Database Service using a configuration file instead of CLI flags.
See the [YAML reference](../reference/configuration.mdx) for details.
</Admonition>
(!docs/pages/includes/database-access/multiple-instances-tip.mdx !)

## Step 2/5. Create a Teleport user

Expand Down
44 changes: 9 additions & 35 deletions docs/pages/database-access/guides/cockroachdb-self-hosted.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -39,52 +39,26 @@ This guide will help you to:

(!docs/pages/includes/database-access/token.mdx!)

Install Teleport on the host where you will run the Teleport Database Service:

(!docs/pages/includes/install-linux.mdx!)
Install and configure Teleport where you will run the Teleport Database Service:

<Tabs>
<TabItem label="Self-Hosted" scope={["enterprise","oss"]}>
Start the Teleport Database Service, pointing the `--auth-server` flag to the address of your Teleport Proxy Service:
<TabItem label="Linux Server">

```code
$ teleport db start \
--token=/tmp/token \
--auth-server=teleport.example.com:3080 \
--name=roach \
--protocol=cockroachdb \
--uri=roach.example.com:26257 \
--labels=env=dev
```
(!docs/pages/includes/install-linux.mdx!)

<Admonition type="note">
The `--auth-server` flag must point to the Teleport cluster's Proxy Service endpoint
because the Database Service always connects back to the cluster over a reverse
tunnel.
</Admonition>
(!docs/pages/includes/database-access/db-configure-start.mdx dbName="roach" "dbProtocol="cockroachdb" databaseAddress="roach.example.com:26257" !)

</TabItem>
<TabItem label="Teleport Cloud" scope={["cloud"]}>

Start the Teleport Database Service, pointing the `--auth-server` flag at the address of your Teleport Cloud tenant, e.g., `mytenant.teleport.sh`.
<TabItem label="Kubernetes Cluster">
Teleport provides Helm charts for installing the Teleport Database Service in Kubernetes Clusters.

```code
$ teleport db start \
--token=/tmp/token \
--auth-server=mytenant.teleport.sh:443 \
--name=roach \
--protocol=cockroachdb \
--uri=roach.example.com:26257 \
--labels=env=dev
```
(!docs/pages/kubernetes-access/helm/includes/helm-repo-add.mdx!)

(!docs/pages/includes/database-access/db-helm-install.mdx dbName="roach" dbProtocol="cockroachdb" databaseAddress="roach.example.com:26257" !)
</TabItem>
</Tabs>

<Admonition type="tip">
You can start the Database Service using a configuration file instead of CLI flags.
See [YAML reference](../reference/configuration.mdx).
</Admonition>
(!docs/pages/includes/database-access/multiple-instances-tip.mdx !)

## Step 2/4. Create a Teleport user

Expand Down
111 changes: 10 additions & 101 deletions docs/pages/database-access/guides/elastic.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -34,118 +34,27 @@ This guide will help you to configure secured access to an Elasticsearch databas

(!docs/pages/includes/database-access/token.mdx!)

Install Teleport on the host where you will run the Teleport Database Service. Make sure you've selected your installation type (OSS, Enterprise, Cloud):

(!docs/pages/includes/install-linux.mdx!)

Start the Teleport Database Service, pointing the `--auth-server` flag to the
address of your Teleport Proxy Service:
Install and configure Teleport where you will run the Teleport Database Service:

<Tabs>
<TabItem label="Standalone Binary">

<ScopedBlock scope={["oss", "enterprise"]}>

```code
$ teleport db start \
--token=/tmp/token \
--auth-server=teleport.example.com:3080 \
--name=myelastic \
--protocol=elasticsearch \
--uri=elasticsearch.example.com:9200 \
--labels=env=dev
```

</ScopedBlock>
<ScopedBlock scope={["cloud"]}>
<TabItem label="Linux Server">

```code
$ teleport db start \
--token=/tmp/token \
--auth-server=mytennant.teleport.sh:443 \
--name=myelastic \
--protocol=elasticsearch \
--uri=elasticsearch.example.com:9200 \
--labels=env=dev
```

</ScopedBlock>

<Admonition type="note">

The `--auth-server` flag must point to the Teleport cluster's Proxy Service
endpoint because the Database Service always connects back to the cluster over a
reverse tunnel.
(!docs/pages/includes/install-linux.mdx!)

</Admonition>
(!docs/pages/includes/database-access/db-configure-start.mdx dbName="myelastic" dbProtocol="elastic" databaseAddress="elasticsearch.example.com:9200" !)

</TabItem>
<TabItem label="Config File">
Configure `teleport.yaml` using the example below:

<ScopedBlock scope={["cloud"]}>

```yaml
version: v3
teleport:
auth_token: <insert token here>
proxy_server: mytenant.teleport.sh:443

# disable services that are on by default
ssh_service: { enabled: no }
proxy_service: { enabled: no }
auth_service: { enabled: no }

# db service config
db_service:
enabled: "yes"
resources:
- labels:
"*": "*"
databases:
- name: myelastic
protocol: elasticsearch
uri: elasticsearch.example.com:9200
static_labels:
env: dev
```
<TabItem label="Kubernetes Cluster">
Teleport provides Helm charts for installing the Teleport Database Service in Kubernetes Clusters.

</ScopedBlock>

<ScopedBlock scope={["oss", "enterprise"]}>

```yaml
version: v3
teleport:
auth_token: <insert token here>
proxy_server: teleport.example.com

# disable services that are on by default
ssh_service: { enabled: no }
proxy_service: { enabled: no }
auth_service: { enabled: no }

# db service config
db_service:
enabled: "yes"
resources:
- labels:
"*": "*"
databases:
- name: myelastic
protocol: elasticsearch
uri: elasticsearch.example.com:9200
static_labels:
env: dev
```

</ScopedBlock>

Adjust for your environment, then start or restart Teleport. See the [YAML reference](../reference/configuration.mdx) for details.
(!docs/pages/kubernetes-access/helm/includes/helm-repo-add.mdx!)

(!docs/pages/includes/database-access/db-helm-install.mdx dbName="myelastic" dbProtocol="elastic" databaseAddress="elasticsearch.example.com:9200" !)
</TabItem>
</Tabs>

(!docs/pages/includes/database-access/multiple-instances-tip.mdx !)

## Step 2/5. Create a Teleport user

(!docs/pages/includes/database-access/create-user.mdx!)
Expand Down
55 changes: 13 additions & 42 deletions docs/pages/database-access/guides/mongodb-self-hosted.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -38,50 +38,26 @@ In this guide you will:

(!docs/pages/includes/database-access/token.mdx!)

Install Teleport on the host where you will run the Teleport Database Service:
Install and configure Teleport where you will run the Teleport Database Service:

(!docs/pages/includes/install-linux.mdx!)

<ScopedBlock scope={["oss", "enterprise"]}>

Start the Teleport Database Service, pointing the `--auth-server` flag to the
address of your Teleport Proxy Service:

```code
$ teleport db start \
--token=/tmp/token \
--auth-server=teleport.example.com:3080 \
--name=example-mongo \
--protocol=mongodb \
--uri=mongo.example.com:27017 \
--labels=env=dev
```

<Admonition type="note">
<Tabs>
<TabItem label="Linux Server">

The `--auth-server` flag must point to the Teleport cluster's Proxy Service
endpoint because the Database Service always connects back to the cluster over a
reverse tunnel.
(!docs/pages/includes/install-linux.mdx!)

</Admonition>
(!docs/pages/includes/database-access/db-configure-start.mdx dbName="example-mongo" dbProtocol="mongodb" databaseAddress="mongo.example.com:27017" !)

</ScopedBlock>
<ScopedBlock scope={["cloud"]}>
</TabItem>
<TabItem label="Kubernetes Cluster">
Teleport provides Helm charts for installing the Teleport Database Service in Kubernetes Clusters.

Start the Teleport Database Service, pointing the `--auth-server` flag to the
address of your Teleport Cloud tenant:
(!docs/pages/kubernetes-access/helm/includes/helm-repo-add.mdx!)

```code
$ teleport db start \
--token=/tmp/token \
--auth-server=mytenant.teleport.sh:443 \
--name=example-mongo \
--protocol=mongodb \
--uri=mongo.example.com:27017 \
--labels=env=dev
```
(!docs/pages/includes/database-access/db-helm-install.mdx dbName="example-mongo" dbProtocol="mongodb" databaseAddress="mongo.example.com:27017" !)
</TabItem>
</Tabs>

</ScopedBlock>
(!docs/pages/includes/database-access/multiple-instances-tip.mdx !)

You can specify either a single connection address or a MongoDB
[connection string](https://docs.mongodb.com/manual/reference/connection-string/)
Expand All @@ -99,11 +75,6 @@ connection string setting:
$ --uri="mongodb://mongo1.example.com:27017,mongo2.example.com:27017/?replicaSet=rs0&readPreference=secondary"
```

<Admonition type="tip">
You can start the Database Service using a configuration file instead of CLI flags.
See the [YAML reference](../reference/configuration.mdx) for details.
</Admonition>

### Create a Teleport user

(!docs/pages/includes/database-access/create-user.mdx!)
Expand Down
Loading