Skip to content

Commit

Permalink
sql
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaomeng79 committed Aug 31, 2023
1 parent 098e5ab commit 9356a65
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 2 deletions.
6 changes: 5 additions & 1 deletion 02数据存取/8postgres/0目录.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,8 @@

17. [FDW的使用](17FDW的使用.md)

18. [数据库监控](18数据库监控.md)
18. [数据库监控](18数据库监控.md)

19. [插件](19%E6%8F%92%E4%BB%B6.md)
20.
21. [配置](./20%E9%85%8D%E7%BD%AE.md)
10 changes: 10 additions & 0 deletions 02数据存取/8postgres/20配置.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# 配置

- 设置只读账号

```sql
CREATE USER read_only_sdp WITH ENCRYPTED PASSWORD 'read_only_pw';
ALTER USER read_only SET default_transaction_read_only=on;
GRANT USAGE ON SCHEMA public to read_only;
GRANT SELECT ON ALL TABLES IN SCHEMA public TO read_only;
```
20 changes: 20 additions & 0 deletions 03容器和集群/1docker/1常见问题.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,24 @@ ENTRYPOINT [ /account_api ]
"debug" : true,
"experimental" : true
}
```

- docker-compose 创建一个子网
```yaml
version: '3.2'

services:
metabase:
restart: always
image: metabase/metabase:latest
container_name: metabase
networks:
- event-net

networks:
event-net:
ipam:
driver: default
config:
- subnet: "192.168.33.0/24"
```
3 changes: 2 additions & 1 deletion 06工具/开发工具.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,5 @@
- [cloudflared](https://github.com/cloudflare/cloudflared) 内网部署服务
- [sqlkiller](https://www.sqlkiller.com/) AI生成sql
- [herowand](https://editor.herowand.com/) json,yaml,toml可视化展示
- [proxydb](http://www.proxydb.net/) 免费代理
- [proxydb](http://www.proxydb.net/) 免费代理
- [ddns-go](https://github.com/jeessy2/ddns-go) 自动更新dns

0 comments on commit 9356a65

Please sign in to comment.