Remove database.yml from the repo (#1162)
* Remove database.yml file from the repo, fixes #478 * Update dev.to docs * Switch to the bullet list for the database.yml docs
This commit is contained in:
parent
a9a23ca79d
commit
48dbe55d05
6 changed files with 34 additions and 11 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
|
@ -39,6 +39,7 @@ latest.dump
|
|||
/public/packs
|
||||
/public/packs-test
|
||||
/node_modules
|
||||
config/database.yml
|
||||
|
||||
# Ignore storybook static site generation
|
||||
storybook-static/
|
||||
|
|
@ -49,3 +50,4 @@ package-lock.json
|
|||
|
||||
#Jetbrains Tools
|
||||
.idea/
|
||||
|
||||
|
|
|
|||
|
|
@ -156,6 +156,9 @@ This section provides a high-level requirement & quick start guide. For detailed
|
|||
1. `gem install foreman`
|
||||
1. `bundle install`
|
||||
1. `bin/yarn`
|
||||
1. Setup your database
|
||||
- Create `config/database.yml` by copying from the provided template (i.e. `cp config/database.yml.sample config/database.yml`)
|
||||
- Update the `config/database.yml` file if needed.
|
||||
1. Set up your environment variables/secrets
|
||||
- Take a look at `Envfile`. This file lists all the `ENV` variables we use and provides a fake default for any missing keys. You'll need to get your own free [Algolia credentials](http://docs.dev.to/get-api-keys-dev-env/#algolia) to get your development environment running.
|
||||
- This [guide](http://docs.dev.to/get-api-keys-dev-env/) will show you how to get free API keys for additional services that may be required to run certain parts of the app.
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ There are two ways to install Yarn.
|
|||
### PostgreSQL
|
||||
|
||||
1. run `sudo apt update && sudo apt install postgresql postgresql-contrib libpq-dev`.
|
||||
2. To test the installation you can run `sudo -u postgres psql` which should open a PostgreSQL prompt. Exit the prompt by running `\q` then run `sudo -u postgres createuser -s $YOUR_USERNAME` where $YOUR_USERNAME is the username you are currently logged in as. Lastly, at least on Debian based systems, in the codebase under /config/database.yml you'll want to comment out the `host: localhost` to configure the database to use Unix domain sockets as outlined [here](https://stackoverflow.com/questions/23375740/pgconnectionbad-fe-sendauth-no-password-supplied).
|
||||
2. To test the installation you can run `sudo -u postgres psql` which should open a PostgreSQL prompt. Exit the prompt by running `\q` then run `sudo -u postgres createuser -s $YOUR_USERNAME` where \$YOUR_USERNAME is the username you are currently logged in as. Lastly, at least on Debian based systems, in the codebase under /config/database.yml you'll want to comment out the `host: localhost` to configure the database to use Unix domain sockets as outlined [here](https://stackoverflow.com/questions/23375740/pgconnectionbad-fe-sendauth-no-password-supplied).
|
||||
|
||||
There are more than one way to setup Postgres. For additional configuration, check out our [postgres doc](/additional-postgres-setup) or the official [PostgreSQL](https://www.postgresql.org/) site for more information.
|
||||
|
||||
|
|
@ -31,14 +31,20 @@ There are more than one way to setup Postgres. For additional configuration, che
|
|||
4. Install foreman gem with `gem install foreman`
|
||||
5. Install our ruby dependencies with `bundle install`
|
||||
6. Install our frontend dependencies with `bin/yarn`
|
||||
7. Set up your environment variables/secrets
|
||||
7. Setup your database
|
||||
|
||||
- Create `config/database.yml` by copying from the provided template (i.e. `cp config/database.yml.sample config/database.yml`)
|
||||
- Update the `config/database.yml` file if needed.
|
||||
|
||||
8. Set up your environment variables/secrets
|
||||
|
||||
- Take a look at `Envfile`. This file lists all the `ENV` variables we use and provides a fake default for any missing keys. You'll need to get your own free [Algolia credentials](http://docs.dev.to/get-api-keys-dev-env/#algolia) to get your development environment running.
|
||||
- This [guide](http://docs.dev.to/get-api-keys-dev-env/) will show you how to get free API keys for additional services that may be required to run certain parts of the app.
|
||||
- For any key that you wish to enter/replace:
|
||||
|
||||
8. Create `config/application.yml` by copying from the provided template (ie. with bash: `cp config/sample_application.yml config/application.yml`). This is a personal file that is ignored in git.
|
||||
9. Obtain the development variable and apply the key you wish to enter/replace. ie:
|
||||
9. Create `config/application.yml` by copying from the provided template (ie. with bash: `cp config/sample_application.yml config/application.yml`). This is a personal file that is ignored in git.
|
||||
10. Obtain the development variable and apply the key you wish to enter/replace. ie:
|
||||
|
||||
|
||||
```
|
||||
GITHUB_KEY: "SOME_REAL_SECURE_KEY_HERE"
|
||||
|
|
@ -48,4 +54,4 @@ There are more than one way to setup Postgres. For additional configuration, che
|
|||
- If you are missing `ENV` variables on bootup, `envied` gem will alert you with messages similar to `'error_on_missing_variables!': The following environment variables should be set: A_MISSING_KEY.`.
|
||||
- You do not need "real" keys for basic development. Some features require certain keys, so you may be able to add them as you go.
|
||||
|
||||
10. Run `bin/setup`
|
||||
11. Run `bin/setup`
|
||||
|
|
|
|||
|
|
@ -23,14 +23,20 @@ For additional configuration, [click here](/additional-postgres-setup)
|
|||
4. Install foreman gem with `gem install foreman`
|
||||
5. Install our ruby dependencies with `bundle install`
|
||||
6. Install our frontend dependencies with `bin/yarn`
|
||||
7. Set up your environment variables/secrets
|
||||
7. Setup your database
|
||||
|
||||
- Create `config/database.yml` by copying from the provided template (i.e. `cp config/database.yml.sample config/database.yml`)
|
||||
- Update the `config/database.yml` file if needed.
|
||||
|
||||
8. Set up your environment variables/secrets
|
||||
|
||||
- Take a look at `Envfile`. This file lists all the `ENV` variables we use and provides a fake default for any missing keys. You'll need to get your own free [Algolia credentials](http://docs.dev.to/get-api-keys-dev-env/#algolia) to get your development environment running.
|
||||
- This [guide](http://docs.dev.to/get-api-keys-dev-env/) will show you how to get free API keys for additional services that may be required to run certain parts of the app.
|
||||
- For any key that you wish to enter/replace:
|
||||
|
||||
8. Create `config/application.yml` by copying from the provided template (ie. with bash: `cp config/sample_application.yml config/application.yml`). This is a personal file that is ignored in git.
|
||||
9. Obtain the development variable and apply the key you wish to enter/replace. ie:
|
||||
9. Create `config/application.yml` by copying from the provided template (ie. with bash: `cp config/sample_application.yml config/application.yml`). This is a personal file that is ignored in git.
|
||||
10. Obtain the development variable and apply the key you wish to enter/replace. ie:
|
||||
|
||||
|
||||
```
|
||||
GITHUB_KEY: "SOME_REAL_SECURE_KEY_HERE"
|
||||
|
|
@ -40,7 +46,7 @@ For additional configuration, [click here](/additional-postgres-setup)
|
|||
- If you are missing `ENV` variables on bootup, `envied` gem will alert you with messages similar to `'error_on_missing_variables!': The following environment variables should be set: A_MISSING_KEY.`.
|
||||
- You do not need "real" keys for basic development. Some features require certain keys, so you may be able to add them as you go.
|
||||
|
||||
10. Run `bin/setup`
|
||||
11. Run `bin/setup`
|
||||
|
||||
#### Possible Error Messages
|
||||
|
||||
|
|
|
|||
|
|
@ -104,8 +104,14 @@ Pay attention to the username and password you setup during installation of Post
|
|||
5. Run `rbenv rehash` when foreman installation is done.
|
||||
6. Install our ruby dependencies with `bundle install`
|
||||
While installing, you might run into an error due to the pg gem requiring PostgreSQL libraries. If so, please run `sudo apt-get install libpq-dev` before retrying.
|
||||
7. Install our frontend dependencies with `bin/yarn`
|
||||
8. Set up your environment variables/secrets
|
||||
7. Setup your database
|
||||
|
||||
- Create `config/database.yml` by copying from the provided template (i.e. `cp config/database.yml.sample config/database.yml`)
|
||||
- Update the `config/database.yml` file if needed.
|
||||
|
||||
8. Install our frontend dependencies with `bin/yarn`
|
||||
|
||||
9. Set up your environment variables/secrets
|
||||
|
||||
- Take a look at `Envfile`. This file lists all the `ENV` variables we use and provides a fake default for any missing keys. You'll need to get your own free [Algolia credentials](http://docs.dev.to/get-api-keys-dev-env/#algolia) to get your development environment running.
|
||||
- This [guide](http://docs.dev.to/get-api-keys-dev-env/) will show you how to get free API keys for additional services that may be required to run certain parts of the app.
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue