Skip to content

Commit

Permalink
Updating README with docker setup
Browse files Browse the repository at this point in the history
  • Loading branch information
alaxalves committed Mar 6, 2019
1 parent 3abe8ff commit f6f0b01
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 2 deletions.
28 changes: 28 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,34 @@ in your browser to access the preview.

**Note:** The build of the site will take several minutes.

### Preview with Docker

Run the following

``` sh
docker run -it --name ruby-lang -v $PWD:/www.ruby-lang.org -w /www.ruby-lang.org --network host ruby:2.6.1 sh -c "bundle install --without production && bundle exec rake serve"
```

to generate the website and start a local web server


Open [http://localhost:9292/](http://localhost:9292/)
in your browser to access the preview.

### Preview with Docker Compose

Run the following

``` sh
docker-compose up
```

to generate the website and start a local web server


Open [http://localhost:9292/](http://localhost:9292/)
in your browser to access the preview.

### Preview on Heroku

In case a build is not possible on your local machine
Expand Down
2 changes: 0 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ services:
web:
container_name: ruby-lang
image: ruby:2.6.1
environment:
- RAILS_ENV=development
command: >
sh -c "bundle check || bundle install --without production &&
bundle exec rake build &&
Expand Down

0 comments on commit f6f0b01

Please sign in to comment.