Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
陈曦
sub2api
Commits
94749b12
Commit
94749b12
authored
Dec 27, 2025
by
shaw
Browse files
chore: 调整deploy说明以及取消postgres端口暴露
parent
54636781
Changes
2
Show whitespace changes
Inline
Side-by-side
deploy/README.md
View file @
94749b12
...
...
@@ -281,6 +281,30 @@ To change after installation:
sudo
systemctl restart sub2api
```
#### Gemini OAuth Configuration
If you need to use AI Studio OAuth for Gemini accounts, add the OAuth client credentials to the systemd service file:
1.
Edit the service file:
```
bash
sudo
nano /etc/systemd/system/sub2api.service
```
2.
Add your OAuth credentials in the
`[Service]`
section (after the existing
`Environment=`
lines):
```
ini
Environment
=
GEMINI_OAUTH_CLIENT_ID=your-client-id.apps.googleusercontent.com
Environment
=
GEMINI_OAUTH_CLIENT_SECRET=GOCSPX-your-client-secret
```
3.
Reload and restart:
```
bash
sudo
systemctl daemon-reload
sudo
systemctl restart sub2api
```
> **Note:** Code Assist OAuth does not require any configuration - it uses the built-in Gemini CLI client.
> See the [Gemini OAuth Configuration](#gemini-oauth-configuration) section above for detailed setup instructions.
#### Application Configuration
The main config file is at
`/etc/sub2api/config.yaml`
(created by Setup Wizard).
...
...
deploy/docker-compose.yml
View file @
94749b12
...
...
@@ -121,8 +121,8 @@ services:
timeout
:
5s
retries
:
5
start_period
:
10s
ports
:
-
5433:5432
# 注意:不暴露端口到宿主机,应用通过内部网络连接
# 如需调试,可临时添加:ports: ["127.0.0.1:
5433:5432
"]
# ===========================================================================
# Redis Cache
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment