Skip to content

Docker workaround #454

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

Closed
wants to merge 2 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 21 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

## React on Rails Pro and ShakaCode Pro Support

React on Rails Pro provides Node server rendering and other performance enhancements for React on Rails.
React on Rails Pro provides Node server rendering and other performance enhancements for React on Rails.

[![2018-09-11_10-31-11](https://user-images.githubusercontent.com/1118459/45467845-5bcc7400-b6bd-11e8-91e1-e0cf806d4ea4.png)](https://blog.shakacode.com/hvmns-90-reduction-in-server-response-time-from-react-on-rails-pro-eb08226687db)

Expand All @@ -23,7 +23,7 @@ The [ShakaCode Pro Support Plan](http://www.shakacode.com/work/shakacode-pro-sup
* Best practices based on over four years of React on Rails experience.
* Using [Reason](https://reasonml.github.io/) with (or without) React on Rails.

ShakaCode can also help you with your custom software development needs. We specialize in marketplace and e-commerce applications that utilize both Rails and React. Because we own [HawaiiChee.com](https://www.hawaiichee.com), we can leverage that code for your app!
ShakaCode can also help you with your custom software development needs. We specialize in marketplace and e-commerce applications that utilize both Rails and React. Because we own [HawaiiChee.com](https://www.hawaiichee.com), we can leverage that code for your app!

The article [Why Hire ShakaCode?](https://blog.shakacode.com/can-shakacode-help-you-4a5b1e5a8a63#.jex6tg9w9) provides additional details about our projects.

Expand Down Expand Up @@ -86,6 +86,7 @@ You can see this tutorial live here: [http://reactrails.com/](http://reactrails.
+ [Demoed Functionality](#demoed-functionality)
+ [Technologies Involved](#technologies-involved)
+ [Basic Demo Setup](#basic-demo-setup)
+ [Docker Workaround for postgresql and redis server](#docker-workaround-for-postgresql-and-redis-server-through-containers)
+ [Basic Command Line](#basic-command-line)
+ [Experimenting with Hot Reloading](#experimenting-with-hot-reloading-applies-to-both-procfilehot-and-procfileexpress)
+ [Javascript Development without Rails](#javascript-development-without-rails-using-the-webpack-dev-server)
Expand Down Expand Up @@ -153,6 +154,24 @@ See package.json and Gemfile for versions
1. Open a browser tab to http://localhost:3000 for the Rails app example.
2. When you make changes, you have to refresh the browser page.

### Docker Workaround for `postgresql` and `redis-server` through containers
1. `docker container run --name some-postgres -e POSTGRES_PASSWORD=mysecretpassword -p 5432:5432 -d postgres`
1. Open file: config/database.yml
2. The final result should be like this:
```
default: &default
adapter: postgresql
host: localhost
port: 5432
username: postgres
password: 'mysecretpassword'
```
3. `rake db:setup`
2. `docker container run --name some-redis -p 6379:6379 -d redis`
3. After finishing working the project remember to stop the containers
4. `docker container stop some-postgres`
4. `docker container stop some-redis`

### Basic Command Line
1. Run all linters and tests: `rake`
1. See all npm commands: `yarn run`
Expand Down