@@ -14,7 +14,7 @@
### VS Code 配置文件
-## [Spring 开发环境](SPRING.md)
+## [Spring 开发环境](spring/)
## [Local 开发环境](LOCAL.md)
@@ -10,6 +10,18 @@
ssh -i YOUR_KEY YOUR_ID@YOUR_ID.spring.wikipali.org
```
+## 数据库设置
+
+
+```bash
+cd /workspace/shared/db-TIMASTAMP/
+psql -q -h 127.0.0.1 -p 5432 -U YOUR_ID YOUR_ID_mint < schema.sql
+pg_restore -Fc -h 127.0.0.1 -p 5432 -U YOUR_ID -d YOUR_ID_mint < data.dump
+```
+
## PHP 开发(以用户 xxx 为例)
- `~/www/htdocs/info.php` => `https://YOUR_ID.spring.wikipali.org/info.php`
@@ -9,9 +9,8 @@ then
fi
psql << EOF
-CREATE DATABASE $1_mint WITH ENCODING = 'UTF8';
CREATE USER $1 WITH PASSWORD '$2';
-GRANT ALL PRIVILEGES ON DATABASE $1_mint TO $1;
+CREATE DATABASE $1_mint WITH ENCODING = 'UTF8' OWNER $1;
EOF
echo "done($1)."
@@ -10,8 +10,7 @@ fi
DROP DATABASE $1_mint;