-
Notifications
You must be signed in to change notification settings - Fork 94
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add markdownlint to project and builds
- Loading branch information
Showing
6 changed files
with
150 additions
and
69 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"default": true, | ||
"no-hard-tabs": false, | ||
"MD013": {"line_length": 80}, | ||
"MD007": {"indent": 1} | ||
} |
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,69 +1,99 @@ | ||
#### Docker install (if you don't have docker and docker-compose installed) | ||
##### install Docker and Docker compose | ||
# Using docker (outdated) | ||
|
||
## Docker install (if you don't have docker and docker-compose installed) | ||
|
||
### install Docker and Docker compose | ||
|
||
You need to install Docker and Docker Compose. | ||
* *Note:* Docker and Docker Compose binaries from Docker itself are proprietary software based entirely upon | ||
free software. If you feel more comfortable, you may build them from source. | ||
|
||
* *Note 2:* For Debian, the Docker package is simply too out of date to be usable. | ||
* *Note:* Docker and Docker Compose binaries from Docker itself are proprietary | ||
software based entirely upon free software. If you feel more comfortable, | ||
you may build them from source. | ||
|
||
* *Note 2:* For Debian, the Docker package is simply too out of date to be usable. | ||
Even the version for latest Ubuntu LTS is too old. For reliability, we strongly | ||
recommend using the Docker debian feed from docker itself OR making sure you keep your | ||
own build up to date. | ||
recommend using the Docker debian feed from docker itself OR making sure you | ||
keep your own build up to date. | ||
|
||
### Add yourself to the docker group | ||
|
||
##### Add yourself to the docker group | ||
Adding yourself as a Docker group user as follows: | ||
|
||
`sudo usermod -aG docker $USER` | ||
|
||
You will likely need to logout and log back in again. | ||
|
||
#### Build your docker-container and start it up for initial set up. | ||
|
||
## Build your docker-container and start it up for initial set up | ||
|
||
We'll keep this running in the console we'll call **console 1** | ||
``` | ||
|
||
```ruby | ||
./dc build | ||
./dc up | ||
``` | ||
#### System configuration | ||
|
||
## System configuration | ||
|
||
There are a number of steps for configuring your Houdini instance for startup | ||
##### Start a new console we'll call **console 2**. | ||
|
||
##### In console 2, copy the env template to your .env file | ||
``` | ||
### Start a new console we'll call **console 2** | ||
|
||
### In console 2, copy the env template to your .env file | ||
|
||
```shell | ||
cp .env.template .env | ||
``` | ||
##### In console 2, run the following and copy the output to you .env file to set you `DEVISE_SECRET_KEY` environment variable. | ||
`./run rake secret # copy this result into your DEVISE_SECRET_KEY` | ||
|
||
##### In console 2, , run the following and copy the output to you .env file to set you `SECRET_TOKEN` environment variable. | ||
``` | ||
./run rake secret # copy this result into your SECRET_TOKEN | ||
### In console 2, run the following fill your `DEVISE_SECRET_KEY` | ||
|
||
`./run rake secret ## copy this result into your DEVISE_SECRET_KEY` | ||
|
||
Now copy the output to you .env file to set you `DEVISE_SECRET_KEY` environment variable | ||
|
||
### In console 2, run the following to fill your `SECRET_TOKEN` | ||
|
||
```ruby | ||
./run rake secret ## copy this result into your SECRET_TOKEN | ||
``` | ||
|
||
##### Set the following secrets in your .env file with your Stripe account information | ||
- `STRIPE_API_KEY` with your Stripe PRIVATE key | ||
- `STRIPE_API_PUBLIC` with your Stripe PUBLIC key | ||
Now copy the output to you .env file to set you `SECRET_TOKEN` environment variable | ||
|
||
### Set the following secrets in your .env file with your Stripe account information | ||
|
||
* `STRIPE_API_KEY` with your Stripe PRIVATE key | ||
* `STRIPE_API_PUBLIC` with your Stripe PUBLIC key | ||
|
||
### You SHOULD set your AMAZON s3 information (optional but STRONGLY recommended) | ||
|
||
##### You SHOULD set your AMAZON s3 information (optional but STRONGLY recommended) | ||
If you don't, file uploads WILL NOT WORK but it's not required. | ||
|
||
##### In console 2, install yarn | ||
### In console 2, install yarn | ||
|
||
`./run yarn` | ||
|
||
##### In console 2, fill the db | ||
`./run rake db:create db:structure:load db:seed test:prepare` | ||
### In console 2, fill the db | ||
|
||
`./run rake db:create db:structure:load db:seed test:prepare` | ||
|
||
### Set up mailer info | ||
|
||
##### Set up mailer info | ||
You can set this in `config/default_organization.yml` or better yet, make a copy with your own org name and add that to your .env file as `ORG_NAME` | ||
If you need help setting up your mailer, visit `config/environment.rb` where the settings schema is verified and documented. | ||
You can set this in `config/default_organization.yml` or better yet, make | ||
a copy with your own org name and add that to your .env file as `ORG_NAME` | ||
If you need help setting up your mailer, visit `config/environment.rb` where | ||
the settings schema is verified and documented. | ||
|
||
#### Startup | ||
##### Switch back to console 1 and run `Ctrl-c` to end the session. | ||
## Startup | ||
|
||
### Switch back to console 1 and run `Ctrl-c` to end the session | ||
|
||
### In console 1, restart the containers | ||
|
||
##### In console 1, restart the containers | ||
`./dc up` | ||
|
||
##### In console 2, run: | ||
### In console 2, run | ||
|
||
`./run yarn watch` | ||
|
||
##### You can go to http://localhost:5000 | ||
### You can go to <http://localhost:5000> | ||
|
||
To get started, register your nonprofit using the "Get Started" link. | ||
To get started, register your nonprofit using the "Get Started" link. |
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,41 +1,63 @@ | ||
# Known issues | ||
|
||
## Byebug or Pry won't start - image not found readline.bundle | ||
---------- | ||
|
||
--- | ||
|
||
Error reported. | ||
|
||
```bash | ||
pry | ||
# Sorry, you can't use byebug without Readline. To solve this, you need to | ||
# rebuild Ruby with Readline support. If using Ubuntu, try `sudo apt-get | ||
# install libreadline-dev` and then reinstall your Ruby. | ||
``` | ||
### What's the problem? | ||
Ruby installation with gems, specifically the `readline` gem already installed on a system that had a macOS upgrade. | ||
|
||
### How to solve it? | ||
If **you use `rvm` to manage your ruby versions**. You can use `rvm` to recompile ruby from source to solve the problem. | ||
### What's the problem | ||
|
||
Ruby installation with gems, specifically the `readline` gem already installed | ||
on a system that had a macOS upgrade. | ||
|
||
### How to solve it | ||
|
||
If **you use `rvm` to manage your ruby versions**. You can use `rvm` to | ||
recompile ruby from source to solve the problem. | ||
|
||
_Note:_ You'll need to rebuild `ruby` as a best practice after `macOS` upgrades. | ||
|
||
#### Steps to rebuild ruby via **RVM** | ||
Make sure you've installed the latest Xcode + tools before proceeding; check App Store for updates. Be sure to accept the Xcode License before proceeding! | ||
|
||
Make sure you've installed the latest Xcode + tools before proceeding; check | ||
App Store for updates. Be sure to accept the Xcode License before proceeding! | ||
|
||
Update Xcode and accept the license: | ||
* Update Xcode to latest via App Store, be sure to update the Xcode Tools as well. | ||
* In a terminal window, exec this command: `sudo xcodebuild -license accept` | ||
|
||
- Update Xcode to latest via App Store, be sure to update the Xcode Tools as well. | ||
- In a terminal window, exec this command: `sudo xcodebuild -license accept` | ||
|
||
Make sure you have the **readline** lib installed: | ||
|
||
* `brew --prefix readline` | ||
* if you get Error: No available formula with the name "readline", install readline: | ||
* `brew install readline` | ||
* `brew link --force readline` You'll need to use `--force` to make it work. | ||
* `vi ~/.rvm/user/db` and add the following: `ruby_configure_flags=--with-readline-dir=/usr/local/opt/readline` | ||
- `brew --prefix readline` | ||
- if you get Error: No available formula with the name "readline", install readline: | ||
- `brew install readline` | ||
- `brew link --force readline` You'll need to use `--force` to make it work. | ||
- `vi ~/.rvm/user/db` and add the following: `ruby_configure_flags=--with-readline-dir=/usr/local/opt/readline` | ||
|
||
Reinstall Ruby, with a rebuild of sources: | ||
|
||
* `rvm reinstall <your_ruby_version>` This command removes the specified version's ruby binaries and libs, and rebuilds from source code on your system, with the latest macOS headers and libs. | ||
* `rvm reinstall <your_ruby_version> --gems` This command repro's the same steps as above, but it removes the gems first as well. The next time you run bundle install the gems will be downloaded and rebuilt against your latest ruby. This can help resolve other potential issues with gems after rebuilding ruby on macOS. | ||
* Change the specified version (2.5.1 in my case) to match your needs. | ||
* **I ended up using the second syntax for a completely fresh start.** | ||
|
||
_Gotchas:_ If you're in the project directory running a terminal window when finished this process, You'll had to `cd ..` up a level and then `cd project-folder` back into the project so that RVM would reactivate your gemset. | ||
Run `gem install bundler` and then `bundle install` to re-hydrate the gems for the project. | ||
- `rvm reinstall <your_ruby_version>` This command removes the | ||
specified version's ruby binaries and libs, and rebuilds | ||
from source code on your system, with the latest macOS headers and libs. | ||
- `rvm reinstall <your_ruby_version> --gems` This command repro's the same | ||
steps as above, but it removes the gems first as well. The next time | ||
you run bundle install the gems will be downloaded and rebuilt against | ||
your latest ruby. This can help resolve other potential issues with | ||
gems after rebuilding ruby on macOS. | ||
- Change the specified version (2.5.1 in my case) to match your needs. | ||
- **I ended up using the second syntax for a completely fresh start.** | ||
|
||
_Gotchas:_ If you're in the project directory running a terminal window when | ||
finished this process, You'll had to `cd ..` up a level and then `cd project-folder` | ||
back into the project so that RVM would reactivate your gemset. | ||
Run `gem install bundler` and then `bundle install` to re-hydrate the gems | ||
for the project. |
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