Add example to generate Gemfile.lock for ruby bundler

This commit is contained in:
Joe Ferguson 2014-09-30 14:25:33 -06:00
parent 6f447bc30e
commit 6caef1e1eb
6 changed files with 48 additions and 0 deletions

View File

@ -42,6 +42,14 @@ You can then build and run the Ruby image:
docker build -t my-ruby-app .
docker run -it --name my-running-script my-ruby-app
### Generate a `Gemfile.lock`
The `onbuid` tag expects a `Gemfile.lock` in your app directory. This `docker
run` will help you generate one. Run it in the root of your app, next to the
`Gemfile`:
docker run --rm -v "$(pwd)":/usr/src/app -w /usr/src/app jruby:1.7.15 bundle install --system
## Run a single Ruby script
For many simple, single file projects, you may find it inconvenient to write a

View File

@ -36,6 +36,14 @@ You can then build and run the Ruby image:
docker build -t my-ruby-app .
docker run -it --name my-running-script my-ruby-app
### Generate a `Gemfile.lock`
The `onbuid` tag expects a `Gemfile.lock` in your app directory. This `docker
run` will help you generate one. Run it in the root of your app, next to the
`Gemfile`:
docker run --rm -v "$(pwd)":/usr/src/app -w /usr/src/app jruby:1.7.15 bundle install --system
## Run a single Ruby script
For many simple, single file projects, you may find it inconvenient to write a

View File

@ -41,6 +41,14 @@ need access outside the host, on port 8080:
You can then go to `http://localhost:8080` or `http://host-ip:8080` in a
browser.
### Generate a `Gemfile.lock`
The `onbuid` tag expects a `Gemfile.lock` in your app directory. This `docker
run` will help you generate one. Run it in the root of your app, next to the
`Gemfile`:
docker run --rm -v "$(pwd)":/usr/src/app -w /usr/src/app ruby:2.1.2 bundle install --system
# License
View [license information](https://github.com/rails/rails#license)

View File

@ -35,3 +35,11 @@ need access outside the host, on port 8080:
You can then go to `http://localhost:8080` or `http://host-ip:8080` in a
browser.
### Generate a `Gemfile.lock`
The `onbuid` tag expects a `Gemfile.lock` in your app directory. This `docker
run` will help you generate one. Run it in the root of your app, next to the
`Gemfile`:
docker run --rm -v "$(pwd)":/usr/src/app -w /usr/src/app ruby:2.1.2 bundle install --system

View File

@ -37,6 +37,14 @@ You can then build and run the Ruby image:
docker build -t my-ruby-app .
docker run -it --name my-running-script my-ruby-app
### Generate a `Gemfile.lock`
The `onbuid` tag expects a `Gemfile.lock` in your app directory. This `docker
run` will help you generate one. Run it in the root of your app, next to the
`Gemfile`:
docker run --rm -v "$(pwd)":/usr/src/app -w /usr/src/app ruby:2.1.2 bundle install --system
## Run a single Ruby script
For many simple, single file projects, you may find it inconvenient to write a

View File

@ -28,6 +28,14 @@ You can then build and run the Ruby image:
docker build -t my-ruby-app .
docker run -it --name my-running-script my-ruby-app
### Generate a `Gemfile.lock`
The `onbuid` tag expects a `Gemfile.lock` in your app directory. This `docker
run` will help you generate one. Run it in the root of your app, next to the
`Gemfile`:
docker run --rm -v "$(pwd)":/usr/src/app -w /usr/src/app ruby:2.1.2 bundle install --system
## Run a single Ruby script
For many simple, single file projects, you may find it inconvenient to write a