-
Notifications
You must be signed in to change notification settings - Fork 21
update mac install directions #280
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
dbp
wants to merge
2
commits into
CodeGrade:master
Choose a base branch
from
dbp:mac-docs
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 |
---|---|---|
|
@@ -11,36 +11,54 @@ Bottlenose is built expecting the following environment: | |
* PostgreSQL | ||
* Ruby + Bundler | ||
* Homebrew | ||
* Beanstalk | ||
|
||
### Homebrew | ||
|
||
``` | ||
# Install Homebrew | ||
$/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" | ||
|
||
# Install postgres, Ruby, and npm | ||
brew install postgresql node | ||
# Install postgres, npm, beanstalk, iproute | ||
brew install postgresql node beanstalk iproute2mac | ||
``` | ||
|
||
### Postgres | ||
|
||
Start postgres: | ||
|
||
```sh | ||
brew services start postgresql | ||
``` | ||
|
||
Start beanstalk: | ||
|
||
```sh | ||
# Switch to the postgres user to create the new bottlenose role. | ||
sudo su - postgres | ||
brew services start beanstalk | ||
``` | ||
|
||
|
||
Create a user | ||
|
||
```sh | ||
# Create the bottlenose role for postgres. | ||
createuser -d bottlenose | ||
|
||
# Exit back to the vagrant user. | ||
exit | ||
``` | ||
|
||
If you run into authentication trouble later, you may need to modify | ||
the pg_hba.conf in /etc/postgres/.../ to allow local ident auth. | ||
|
||
### Ruby | ||
|
||
Best practice for Ruby in development is to use a version manager like rvm or rbenv. Once you have the correct version [installed] (https://github.com/rbenv/rbenv#homebrew-on-macos) | ||
Best practice for Ruby in development is to use a version manager like rvm or rbenv. Once you have the correct version [installed] (https://github.com/rbenv/rbenv#homebrew-on-macos), e.g., by doing something like this: | ||
|
||
``` | ||
brew install rbenv ruby-build | ||
rbenv init # follow instructions to make this persistent | ||
rbenv install | ||
``` | ||
|
||
|
||
``` | ||
# Install Ruby's package manager "Bundler". | ||
gem install bundler | ||
|
@@ -49,32 +67,11 @@ gem install bundler | |
# (from the bottlenose directory checked out from git) | ||
bundle install | ||
``` | ||
### Capybara-webkit | ||
|
||
**Prerequisite: Xcode (between 9.4 - 10.1).** Newer versions of Xcode will not work and you will have to downgrade! To do this follow these [instructions] (https://medium.com/@tseboho/how-to-downgrade-xcode-4359df5158d5) | ||
|
||
**NOTE:** | ||
|
||
Qt 5.5 is the last version of Qt that capybara-webkit will support. The Qt project has dropped the WebKit bindings from binary releases in 5.6. Make sure that you have Xcode installed (between 9.4 - 10.1). Under Xcode preferences locations, make sure there is a version set. Qt 5.5 was removed from homebrew in newer commits. The previous/parent commit was **9ba3d6e**. So, to be able to install Qt 5.5 with homebrew checkout the old commit first: | ||
### Javascript | ||
|
||
``` | ||
brew update | ||
cd $( brew --prefix )/Homebrew/Library/Taps/homebrew/homebrew-core | ||
git checkout 9ba3d6ef8891e5c15dbdc9333f857b13711d4e97 Formula/[email protected] | ||
brew install [email protected] | ||
``` | ||
**NOTE:** | ||
|
||
- If you get Error fatal: reference is not a tree: 9ba3d6ef8891e5c15dbdc9333f857b13711d4e97, use git fetch --unshallow to complete git history. | ||
- If you get Error: [email protected]: unknown version :mountain_lion or :mojave, comment out line #25 in Formula/[email protected] | ||
|
||
The Homebrew formula for [email protected] is keg only which means binaries like qmake will not be symlinked into your /usr/local/bin directory and therefore will not be available for capybara-webkit. | ||
``` | ||
# Then add to your shell configuration file: | ||
echo 'export PATH="$(brew --prefix [email protected])/bin:$PATH"' >> ~/.bashrc | ||
|
||
# Now you can install capybara-webkit | ||
gem install capybara-webkit | ||
npm install | ||
``` | ||
|
||
### Running Bottlenose | ||
|
@@ -85,14 +82,14 @@ Currently the bigest weirdness is the use of delayed job. | |
|
||
```sh | ||
# Get a fresh database | ||
rails db:create | ||
rails db:migrate | ||
bundle exec rails db:create | ||
bundle exec rails db:migrate | ||
|
||
# Start background job worker | ||
rake backburner:work | ||
bundle exec rake backburner:work | ||
|
||
# Start the server | ||
rails s | ||
bundle exec rails s | ||
|
||
#If it returns an error saying it cannot find rails use | ||
script/rails s | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.