You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: apps/docs/content/features/access.mdx
+9-3Lines changed: 9 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -173,6 +173,10 @@ When using Let's Encrypt certificates (recommended):
173
173
174
174
For applications requiring direct port access or non-HTTP protocols, Zerops provides flexible port configuration options.
175
175
176
+
:::important
177
+
Currently, direct public port access is only available for runtime services and PostgreSQL databases.
178
+
:::
179
+
176
180
<palign="center">
177
181
<Image
178
182
src="/img/gui/ipv6-public-port.webp"
@@ -183,8 +187,11 @@ For applications requiring direct port access or non-HTTP protocols, Zerops prov
183
187
184
188
### Port Configuration
185
189
186
-
1. Navigate to service detail page in Zerops GUI, select **Public access & internal ports** and click **Setup first access through IPv6** or activate **Unique IPv4 add-on**
190
+
1. Navigate to service detail page in Zerops GUI
191
+
- For runtime services select **Subdomain & domain & IP access**
192
+
- For PostgreSQL select **Direct access through IP address**
187
193
2. Configure your port settings:
194
+
- Either **Setup first access through IPv6** or activate **Unique IPv4 add-on** (if needed)
188
195
- Choose any port from 10-65435 (except 80 and 443)
189
196
- Select destination service and internal port
190
197
- Each public port can be mapped to any internal service port
@@ -209,5 +216,4 @@ Optionally secure your ports with firewall rules:
Copy file name to clipboardExpand all lines: apps/docs/content/postgresql/how-to/connect.mdx
+70-15Lines changed: 70 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -3,35 +3,67 @@ title: Connect to PostgreSQL in Zerops
3
3
description: Learn how to connect to your PostgreSQL database in Zerops from various environments.
4
4
---
5
5
6
-
This guide covers how to connect to your PostgreSQL database in Zerops, both from services within the same project and from your local workstation.
6
+
This guide covers how to connect to your PostgreSQL database in Zerops, both from services within the same project and from outside the Zerops environment.
7
7
8
8
## Connection Options Overview
9
9
10
-
Zerops provides two primary ways to connect to PostgreSQL:
10
+
Zerops provides several ways to connect to PostgreSQL:
11
11
12
12
1.**Internal connections** - Between services in the same Zerops project (via private network)
13
-
2.**Remote connections** - From your local machine (via Zerops VPN)
14
-
15
-
:::caution
16
-
For security reasons, Zerops doesn't allow exposing PostgreSQL services directly to the internet.
17
-
:::
13
+
2.**Remote connections**:
14
+
-**VPN access** - From your local machine via Zerops VPN
15
+
-**Direct IP access** - Enables external applications to connect using TLS encryption by opening public ports on IPv6 (available by default) or IPv4 (requires add-on activation if not already enabled)
18
16
19
17
## Connection Details
20
18
21
-
You'll find PostgreSQL connection details in two places in the Zerops GUI:
19
+
You'll find internal PostgreSQL connection details in two places in the Zerops GUI:
22
20
23
21
1. Under the **Access details** button in the project dashboard
24
22
2. In the service detail page under the **Peek access details** button
Zerops creates a system user named `zps` with full privileges for maintenance purposes. Do not delete, change the password, or remove privileges from this user, as it will disrupt Zerops' ability to maintain the database cluster.
@@ -72,6 +104,10 @@ For more details on how to use environment variables, and instructions for addin
72
104
73
105
## Connect Remotely
74
106
107
+
Zerops offers two methods for connecting to your PostgreSQL database from outside the Zerops environment:
108
+
109
+
### Method 1: Connect via Zerops VPN
110
+
75
111
You can securely connect to PostgreSQL from your local workstation via Zerops VPN:
76
112
77
113
1.[Install & set up zCLI](/references/cli)
@@ -84,4 +120,23 @@ You can securely connect to PostgreSQL from your local workstation via Zerops VP
84
120
* If your connection over VPN doesn't work, try adding `.zerops` suffix to the service hostname (e.g., `database1.zerops`). For additional help, check the [VPN troubleshooting page](/references/vpn/troubleshooting).
85
121
:::
86
122
123
+
### Method 2: Connect via Direct IP Access
124
+
125
+
Direct IP Access uses [pgBouncer](https://www.pgbouncer.org/) for connection pooling and TLS termination.
126
+
127
+
Internally, port `5432` is available without SSL. Externally, connections are secured with TLS through pgBouncer (port `6432`) before being routed to your PostgreSQL service.
128
+
129
+
#### Enable external access
130
+
131
+
1. Navigate to your PostgreSQL service in the Zerops GUI and choose the **Public Access through IP Addresses** section
132
+
2. Choose either IPv6 (available by default) or IPv4 (requires the [unique IPv4](/features/access#dedicated-ipv4-address-330-days) add-on)
133
+
3. Open one or more ports and point them to your PostgreSQL service (the system will direct them through pgBouncer)
134
+
- Choose any port from 10-65435 (except 80 and 443)
135
+
- Select destination service and internal port
136
+
- Each public port can be mapped to any internal service port
137
+
- Multiple public ports can point to the same internal port if needed
138
+
- Port configurations can be set independently for IPv4 and IPv6
139
+
4. Optionally enable firewall protection for additional security
140
+
5. Click the **Publish X IP access change(s)** button to apply your settings
141
+
87
142
For database management tools and how to manage users and databases, see [Manage PostgreSQL Users and Databases](/postgresql/how-to/manage).
0 commit comments