-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
postgres initialization scripts for dev and test
also, add config/database.yml to linked_files in deploy config
- Loading branch information
1 parent
db58c82
commit 5a759e4
Showing
8 changed files
with
31 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,16 @@ | ||
# SQLite version 3.x | ||
# gem install sqlite3 | ||
# | ||
# Ensure the SQLite 3 gem is defined in your Gemfile | ||
# gem 'sqlite3' | ||
# | ||
default: &default | ||
adapter: sqlite3 | ||
adapter: postgresql | ||
encoding: unicode | ||
# For details on connection pooling, see rails configuration guide | ||
# http://guides.rubyonrails.org/configuring.html#database-pooling | ||
pool: <%= ENV.fetch("RAILS_MAX_THREADS") { 5 } %> | ||
timeout: 5000 | ||
|
||
development: | ||
<<: *default | ||
database: db/development.sqlite3 | ||
database: preassembly | ||
username: preassembly | ||
|
||
# Warning: The database defined as "test" will be erased and | ||
# re-generated from your development database when you run "rake". | ||
# Do not set this db to the same as development or production. | ||
test: | ||
<<: *default | ||
database: db/test.sqlite3 | ||
|
||
production: | ||
<<: *default | ||
database: db/production.sqlite3 | ||
database: preassembly_test | ||
username: preassembly_test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
CREATE USER preassembly; | ||
ALTER USER preassembly CREATEDB; | ||
CREATE DATABASE preassembly; | ||
ALTER DATABASE preassembly OWNER TO preassembly; | ||
GRANT ALL PRIVILEGES ON DATABASE preassembly TO preassembly; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
CREATE USER preassembly_test; | ||
ALTER USER preassembly_test CREATEDB; | ||
CREATE DATABASE preassembly_test; | ||
ALTER DATABASE preassembly_test OWNER TO preassembly_test; | ||
GRANT ALL PRIVILEGES ON DATABASE preassembly_test TO preassembly_test; |