Browse Source

README

tags/v1.3.0
Simon Vieille 2 years ago
parent
commit
841211a63a
2 changed files with 42 additions and 3 deletions
  1. 42
    2
      README.md
  2. 0
    1
      propel-dist.yaml

+ 42
- 2
README.md View File

@@ -40,9 +40,49 @@ Installation
40 40
 	$ git clone https://gitnet.fr/deblan/gist
41 41
 	$ cd gist
42 42
 	$ make
43
+
44
+### Database
45
+
43 46
 	$ mv propel-dist.yaml propel.yaml
44
-	$ # EDIT propel.yaml (dsn)
45
-	$ make propel
47
+	
48
+Edit `propel.yaml`. **Use spaces instead of tabulations**.
49
+
50
+**MySQL**
51
+
52
+    propel:
53
+        database:
54
+            connections:
55
+                default:
56
+                    adapter: mysql
57
+                    # http://www.php.net/manual/en/ref.pdo-mysql.connection.php
58
+                    dsn: "mysql:host=DATABASE_SERVER;dbname=DATABASE_NAME"
59
+                    user: DATEBASE_USER
60
+                    password: DATEBASE_PASSWORD
61
+                    settings:
62
+                        charset: utf8
63
+                        queries:
64
+                            utf8: "SET NAMES utf8 COLLATE utf8_unicode_ci, COLLATION_CONNECTION = utf8_unicode_ci, COLLATION_DATABASE = utf8_unicode_ci, COLLATION_SERVER = utf8_unicode_ci"
65
+    
66
+    [...]
67
+
68
+Then `$ make propel`.
69
+
70
+
71
+**SQLITE**
72
+
73
+    propel:
74
+        database:
75
+            connections:
76
+                default:
77
+                    adapter: sqlite
78
+                    # http://www.php.net/manual/en/ref.pdo-sqlite.connection.php
79
+                    dsn: "sqlite:/PATH/TO/gist.sqlite"
80
+                    user: ~
81
+                    password: ~
82
+    
83
+    [...]
84
+	
85
+Then `$ make propel`.
46 86
 
47 87
 Edit `app/bootstrap.php.d/70-security.php` and modify the value of `$app['token']` with a strong secret phrase.
48 88
 	

+ 0
- 1
propel-dist.yaml View File

@@ -7,7 +7,6 @@ propel:
7 7
                 dsn: "mysql:host=localhost;dbname=gist"
8 8
                 user: root
9 9
                 password: root
10
-                attributes:
11 10
                 settings:
12 11
                     charset: utf8
13 12
                     queries:

Loading…
Cancel
Save