diff options
| author | hukl <contact@smyck.org> | 2009-02-24 19:04:56 +0100 |
|---|---|---|
| committer | hukl <contact@smyck.org> | 2009-02-24 19:04:56 +0100 |
| commit | e3a6e47621f445ee8902a808f96cc2933ca06c47 (patch) | |
| tree | 2efc0e1c0ab83096dc18df349f1dff2e9d01567d | |
| parent | be35d8a741812271f8d5b34e10fd0bb2469066e1 (diff) | |
added sample database.yml files for sqlite3, postgresql, mysql
| -rw-r--r-- | config/database.yml-mysql-sample.yml | 45 | ||||
| -rw-r--r-- | config/database.yml-psql-sample.yml | 51 | ||||
| -rw-r--r-- | config/database.yml-sqlite3-sample.yml | 22 |
3 files changed, 118 insertions, 0 deletions
diff --git a/config/database.yml-mysql-sample.yml b/config/database.yml-mysql-sample.yml new file mode 100644 index 0000000..bdb5311 --- /dev/null +++ b/config/database.yml-mysql-sample.yml | |||
| @@ -0,0 +1,45 @@ | |||
| 1 | # MySQL. Versions 4.1 and 5.0 are recommended. | ||
| 2 | # | ||
| 3 | # Install the MySQL driver: | ||
| 4 | # gem install mysql | ||
| 5 | # On Mac OS X: | ||
| 6 | # sudo gem install mysql -- --with-mysql-dir=/usr/local/mysql | ||
| 7 | # On Mac OS X Leopard: | ||
| 8 | # sudo env ARCHFLAGS="-arch i386" gem install mysql -- --with-mysql-config=/usr/local/mysql/bin/mysql_config | ||
| 9 | # This sets the ARCHFLAGS environment variable to your native architecture | ||
| 10 | # On Windows: | ||
| 11 | # gem install mysql | ||
| 12 | # Choose the win32 build. | ||
| 13 | # Install MySQL and put its /bin directory on your path. | ||
| 14 | # | ||
| 15 | # And be sure to use new-style password hashing: | ||
| 16 | # http://dev.mysql.com/doc/refman/5.0/en/old-client.html | ||
| 17 | development: | ||
| 18 | adapter: mysql | ||
| 19 | encoding: utf8 | ||
| 20 | database: mysql_development | ||
| 21 | pool: 5 | ||
| 22 | username: root | ||
| 23 | password: | ||
| 24 | socket: /opt/local/var/run/mysql5/mysqld.sock | ||
| 25 | |||
| 26 | # Warning: The database defined as "test" will be erased and | ||
| 27 | # re-generated from your development database when you run "rake". | ||
| 28 | # Do not set this db to the same as development or production. | ||
| 29 | test: | ||
| 30 | adapter: mysql | ||
| 31 | encoding: utf8 | ||
| 32 | database: mysql_test | ||
| 33 | pool: 5 | ||
| 34 | username: root | ||
| 35 | password: | ||
| 36 | socket: /opt/local/var/run/mysql5/mysqld.sock | ||
| 37 | |||
| 38 | production: | ||
| 39 | adapter: mysql | ||
| 40 | encoding: utf8 | ||
| 41 | database: mysql_production | ||
| 42 | pool: 5 | ||
| 43 | username: root | ||
| 44 | password: | ||
| 45 | socket: /opt/local/var/run/mysql5/mysqld.sock | ||
diff --git a/config/database.yml-psql-sample.yml b/config/database.yml-psql-sample.yml new file mode 100644 index 0000000..db7276e --- /dev/null +++ b/config/database.yml-psql-sample.yml | |||
| @@ -0,0 +1,51 @@ | |||
| 1 | # PostgreSQL. Versions 7.4 and 8.x are supported. | ||
| 2 | # | ||
| 3 | # Install the ruby-postgres driver: | ||
| 4 | # gem install ruby-postgres | ||
| 5 | # On Mac OS X: | ||
| 6 | # gem install ruby-postgres -- --include=/usr/local/pgsql | ||
| 7 | # On Windows: | ||
| 8 | # gem install ruby-postgres | ||
| 9 | # Choose the win32 build. | ||
| 10 | # Install PostgreSQL and put its /bin directory on your path. | ||
| 11 | development: | ||
| 12 | adapter: postgresql | ||
| 13 | encoding: unicode | ||
| 14 | database: psql_development | ||
| 15 | pool: 5 | ||
| 16 | username: psql | ||
| 17 | password: | ||
| 18 | |||
| 19 | # Connect on a TCP socket. Omitted by default since the client uses a | ||
| 20 | # domain socket that doesn't need configuration. Windows does not have | ||
| 21 | # domain sockets, so uncomment these lines. | ||
| 22 | #host: localhost | ||
| 23 | #port: 5432 | ||
| 24 | |||
| 25 | # Schema search path. The server defaults to $user,public | ||
| 26 | #schema_search_path: myapp,sharedapp,public | ||
| 27 | |||
| 28 | # Minimum log levels, in increasing order: | ||
| 29 | # debug5, debug4, debug3, debug2, debug1, | ||
| 30 | # log, notice, warning, error, fatal, and panic | ||
| 31 | # The server defaults to notice. | ||
| 32 | #min_messages: warning | ||
| 33 | |||
| 34 | # Warning: The database defined as "test" will be erased and | ||
| 35 | # re-generated from your development database when you run "rake". | ||
| 36 | # Do not set this db to the same as development or production. | ||
| 37 | test: | ||
| 38 | adapter: postgresql | ||
| 39 | encoding: unicode | ||
| 40 | database: psql_test | ||
| 41 | pool: 5 | ||
| 42 | username: psql | ||
| 43 | password: | ||
| 44 | |||
| 45 | production: | ||
| 46 | adapter: postgresql | ||
| 47 | encoding: unicode | ||
| 48 | database: psql_production | ||
| 49 | pool: 5 | ||
| 50 | username: psql | ||
| 51 | password: | ||
diff --git a/config/database.yml-sqlite3-sample.yml b/config/database.yml-sqlite3-sample.yml new file mode 100644 index 0000000..025d62a --- /dev/null +++ b/config/database.yml-sqlite3-sample.yml | |||
| @@ -0,0 +1,22 @@ | |||
| 1 | # SQLite version 3.x | ||
| 2 | # gem install sqlite3-ruby (not necessary on OS X Leopard) | ||
| 3 | development: | ||
| 4 | adapter: sqlite3 | ||
| 5 | database: db/development.sqlite3 | ||
| 6 | pool: 5 | ||
| 7 | timeout: 5000 | ||
| 8 | |||
| 9 | # Warning: The database defined as "test" will be erased and | ||
| 10 | # re-generated from your development database when you run "rake". | ||
| 11 | # Do not set this db to the same as development or production. | ||
| 12 | test: | ||
| 13 | adapter: sqlite3 | ||
| 14 | database: db/test.sqlite3 | ||
| 15 | pool: 5 | ||
| 16 | timeout: 5000 | ||
| 17 | |||
| 18 | production: | ||
| 19 | adapter: sqlite3 | ||
| 20 | database: db/production.sqlite3 | ||
| 21 | pool: 5 | ||
| 22 | timeout: 5000 | ||
