Skip to content

Commit ffafb7a

Browse files
committed
Fixed copy buttons in readmes to exclude comments.
1 parent 1e9b167 commit ffafb7a

File tree

2 files changed

+116
-7
lines changed

2 files changed

+116
-7
lines changed

DOCKER_README.md

Lines changed: 43 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# PostgreSQL MCP Server - Enhanced
22

3-
Last Updated October 13, 2025 6:13 AM EST Production/Stable v1.1.1
3+
Last Updated October 18, 2025 8:59 PM EST Production/Stable v1.1.1
44

55
<!-- mcp-name: io.github.neverinfamous/postgres-mcp-server -->
66

@@ -20,18 +20,44 @@ Last Updated October 13, 2025 6:13 AM EST Production/Stable v1.1.1
2020

2121
## 🚀 Quick Start
2222

23-
Pull and run the latest version:
23+
**Step 1: Pull the latest image**
2424

2525
```bash
2626
docker pull writenotenow/postgres-mcp-enhanced:latest
27+
```
28+
29+
**Step 2: Run with your database connection**
2730

31+
```bash
2832
docker run -i --rm \
2933
-e DATABASE_URI="postgresql://user:pass@host:5432/dbname" \
3034
writenotenow/postgres-mcp-enhanced:latest \
3135
--access-mode=restricted
3236
```
3337

34-
**That's it!** The server is now running and ready to connect via MCP.
38+
The server is now running and ready to connect via MCP.
39+
40+
---
41+
42+
## **Install to Cursor IDE**
43+
44+
### **One-Click Installation**
45+
46+
Click the button below to install directly into Cursor:
47+
48+
[![Install to Cursor](https://img.shields.io/badge/Install%20to%20Cursor-Click%20Here-blue?style=for-the-badge)](cursor://anysphere.cursor-deeplink/mcp/install?name=PostgreSQL%20Enterprise%20MCP%20Server&config=eyJkb2NrZXIuaW8vd3JpdGVub3Rlbm93L3Bvc3RncmVzLW1jcC1lbmhhbmNlZDp2MS4xLjEiOnsidHJhbnNwb3J0Ijp7InR5cGUiOiJzdGRpbyJ9fX0=)
49+
50+
Or copy this deep link:
51+
```
52+
cursor://anysphere.cursor-deeplink/mcp/install?name=PostgreSQL%20Enterprise%20MCP%20Server&config=eyJkb2NrZXIuaW8vd3JpdGVub3Rlbm93L3Bvc3RncmVzLW1jcC1lbmhhbmNlZDp2MS4xLjEiOnsidHJhbnNwb3J0Ijp7InR5cGUiOiJzdGRpbyJ9fX0=
53+
```
54+
55+
### **Setup Requirements**
56+
- ✅ Docker installed and running
57+
- ✅ PostgreSQL database (version 13-18)
58+
-`DATABASE_URI` environment variable configured
59+
60+
**📖 [See Full Installation Guide →](https://github.com/neverinfamous/postgres-mcp/wiki/Installation-and-Configuration)**
3561

3662
---
3763

@@ -60,6 +86,7 @@ We provide multiple tags for different use cases:
6086
| `master-YYYYMMDD-HHMMSS-sha` | Timestamped | Audit trail |
6187

6288
**Pull a specific version:**
89+
6390
```bash
6491
docker pull writenotenow/postgres-mcp-enhanced:v1.1.1
6592
```
@@ -78,6 +105,7 @@ docker pull writenotenow/postgres-mcp-enhanced:v1.1.1
78105
### Example Configurations
79106

80107
**Production (Restricted Mode):**
108+
81109
```bash
82110
docker run -i --rm \
83111
-e DATABASE_URI="postgresql://readonly_user:pass@db.example.com:5432/production" \
@@ -86,6 +114,7 @@ docker run -i --rm \
86114
```
87115

88116
**Development (Unrestricted Mode):**
117+
89118
```bash
90119
docker run -i --rm \
91120
-e DATABASE_URI="postgresql://admin:pass@localhost:5432/dev_db" \
@@ -94,6 +123,7 @@ docker run -i --rm \
94123
```
95124

96125
**With Docker Compose:**
126+
97127
```yaml
98128
version: '3.8'
99129
services:
@@ -162,6 +192,9 @@ Guided workflows for complex operations:
162192
## 🔌 MCP Client Configuration
163193

164194
### Claude Desktop
195+
196+
Add this to your Claude Desktop configuration file:
197+
165198
```json
166199
{
167200
"mcpServers": {
@@ -181,6 +214,9 @@ Guided workflows for complex operations:
181214
```
182215

183216
### Cursor IDE
217+
218+
Add this to your Cursor IDE MCP configuration file:
219+
184220
```json
185221
{
186222
"mcpServers": {
@@ -206,13 +242,15 @@ Guided workflows for complex operations:
206242
The server works with standard PostgreSQL installations. For enhanced functionality, install these extensions:
207243

208244
**Required for all features:**
245+
209246
```sql
210247
CREATE EXTENSION IF NOT EXISTS pg_stat_statements;
211248
CREATE EXTENSION IF NOT EXISTS pg_trgm;
212249
CREATE EXTENSION IF NOT EXISTS fuzzystrmatch;
213250
```
214251

215252
**Optional but recommended:**
253+
216254
```sql
217255
CREATE EXTENSION IF NOT EXISTS hypopg;
218256
CREATE EXTENSION IF NOT EXISTS pgvector;
@@ -228,11 +266,13 @@ The server gracefully handles missing extensions - features requiring them will
228266
Verify the image works correctly.
229267

230268
**Check server version:**
269+
231270
```bash
232271
docker run --rm writenotenow/postgres-mcp-enhanced:latest --version
233272
```
234273

235274
**Test database connection:**
275+
236276
```bash
237277
docker run -i --rm \
238278
-e DATABASE_URI="postgresql://user:pass@localhost:5432/dbname" \

README.md

Lines changed: 73 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# PostgreSQL MCP Server - Version 1.1.1
22

3-
Last Updated October 13, 2025 6:13 AM EST - Production/Stable v1.1.1
3+
Last Updated October 18, 2025 8:59 PM EST - Production/Stable v1.1.1
44

55
<!-- mcp-name: io.github.neverinfamous/postgres-mcp-server -->
66

@@ -102,25 +102,48 @@ Enhanced with **pg_stat_statements**, **hypopg**, **pgvector**, and **PostGIS**
102102
## 🚀 **Quick Start**
103103

104104
### **Docker (Recommended)**
105+
106+
**Step 1: Pull the image**
107+
105108
```bash
106109
docker pull writenotenow/postgres-mcp-enhanced:latest
110+
```
107111

112+
**Step 2: Run with your database connection**
113+
114+
```bash
108115
docker run -i --rm \
109116
-e DATABASE_URI="postgresql://user:pass@localhost:5432/db" \
110117
writenotenow/postgres-mcp-enhanced:latest \
111118
--access-mode=restricted
112119
```
113120

114121
### **Python Installation**
122+
123+
**Step 1: Install the package**
124+
115125
```bash
116126
pip install postgres-mcp-enhanced
127+
```
128+
129+
**Step 2: Run the server**
130+
131+
```bash
117132
postgres-mcp --access-mode=restricted
118133
```
119134

120135
### **From Source**
136+
137+
**Step 1: Clone the repository**
138+
121139
```bash
122140
git clone https://github.com/neverinfamous/postgres-mcp.git
123141
cd postgres-mcp
142+
```
143+
144+
**Step 2: Install dependencies and run tests**
145+
146+
```bash
124147
uv sync
125148
uv run pytest -v
126149
```
@@ -129,6 +152,42 @@ uv run pytest -v
129152

130153
---
131154

155+
## **Install to Cursor IDE**
156+
157+
### **One-Click Installation**
158+
159+
Click the button below to install directly into Cursor:
160+
161+
[![Install to Cursor](https://img.shields.io/badge/Install%20to%20Cursor-Click%20Here-blue?style=for-the-badge)](cursor://anysphere.cursor-deeplink/mcp/install?name=PostgreSQL%20Enterprise%20MCP%20Server&config=eyJkb2NrZXIuaW8vd3JpdGVub3Rlbm93L3Bvc3RncmVzLW1jcC1lbmhhbmNlZDp2MS4xLjEiOnsidHJhbnNwb3J0Ijp7InR5cGUiOiJzdGRpbyJ9fX0=)
162+
163+
Or copy this deep link:
164+
```
165+
cursor://anysphere.cursor-deeplink/mcp/install?name=PostgreSQL%20Enterprise%20MCP%20Server&config=eyJkb2NrZXIuaW8vd3JpdGVub3Rlbm93L3Bvc3RncmVzLW1jcC1lbmhhbmNlZDp2MS4xLjEiOnsidHJhbnNwb3J0Ijp7InR5cGUiOiJzdGRpbyJ9fX0=
166+
```
167+
168+
### **Prerequisites**
169+
- ✅ Docker installed and running
170+
- ✅ PostgreSQL database (version 13-18)
171+
-`DATABASE_URI` environment variable configured
172+
173+
### **Configuration**
174+
175+
After installation, Cursor will use this Docker-based configuration. If you prefer manual setup, add this to your MCP client configuration:
176+
177+
```json
178+
{
179+
"docker.io/writenotenow/postgres-mcp-enhanced:v1.1.1": {
180+
"transport": {
181+
"type": "stdio"
182+
}
183+
}
184+
}
185+
```
186+
187+
**📖 [See Full Installation Guide →](https://github.com/neverinfamous/postgres-mcp/wiki/Installation-and-Configuration)**
188+
189+
---
190+
132191
## 🛡️ **Security-First Design**
133192

134193
**Zero known vulnerabilities** - Comprehensive security audit passed:
@@ -242,6 +301,9 @@ Required extensions for full functionality:
242301
- **PostGIS** (optional) - Geospatial operations
243302

244303
**Quick Setup:**
304+
305+
Run these commands in your PostgreSQL database:
306+
245307
```sql
246308
CREATE EXTENSION IF NOT EXISTS pg_stat_statements;
247309
CREATE EXTENSION IF NOT EXISTS pg_trgm;
@@ -349,14 +411,21 @@ CREATE EXTENSION IF NOT EXISTS fuzzystrmatch;
349411

350412
## 🧪 **Testing**
351413

414+
**Run all tests:**
415+
352416
```bash
353-
# Run all tests
354417
uv run pytest -v
418+
```
355419

356-
# Security tests
420+
**Security tests:**
421+
422+
```bash
357423
python security/run_security_test.py
424+
```
358425

359-
# With coverage
426+
**With coverage:**
427+
428+
```bash
360429
uv run pytest --cov=src tests/
361430
```
362431

0 commit comments

Comments
 (0)