diff --git a/clojure/README.md b/clojure/README.md index 2d3565976..7d98f7061 100644 --- a/clojure/README.md +++ b/clojure/README.md @@ -67,7 +67,7 @@ You can then build and run the image as above. If you have an existing Lein/Clojure project, it's fairly straightforward to compile your project into a jar from a container: - docker run -it --rm -v "$(pwd)":/usr/src/app -w /usr/src/app clojure lein uberjar + docker run -it --rm -v "$PWD":/usr/src/app -w /usr/src/app clojure lein uberjar This will build your project into a jar file located in your project's `target/uberjar` directory. diff --git a/clojure/content.md b/clojure/content.md index 34e96dfba..72c519705 100644 --- a/clojure/content.md +++ b/clojure/content.md @@ -56,7 +56,7 @@ You can then build and run the image as above. If you have an existing Lein/Clojure project, it's fairly straightforward to compile your project into a jar from a container: - docker run -it --rm -v "$(pwd)":/usr/src/app -w /usr/src/app clojure lein uberjar + docker run -it --rm -v "$PWD":/usr/src/app -w /usr/src/app clojure lein uberjar This will build your project into a jar file located in your project's `target/uberjar` directory. diff --git a/django/README.md b/django/README.md index 37a97584b..6c5af748f 100644 --- a/django/README.md +++ b/django/README.md @@ -50,14 +50,14 @@ Of course, if you don't want to take advantage of magical and convenient `ONBUILD` triggers, you can always just use `docker run` directly to avoid having to add a `Dockerfile` to your project. - docker run --name some-django-app -v "$(pwd)":/usr/src/app -w /usr/src/app -p 8000:8000 -d django bash -c "pip install -r requirements.txt && python manage.py runserver 0.0.0.0:8000" + docker run --name some-django-app -v "$PWD":/usr/src/app -w /usr/src/app -p 8000:8000 -d django bash -c "pip install -r requirements.txt && python manage.py runserver 0.0.0.0:8000" ## Bootstrap a new Django Application If you want to generate the scaffolding for a new Django project, you can do the following: - docker run -it --rm --user "$(id -u):$(id -g)" -v "$(pwd)":/usr/src/app -w /usr/src/app django django-admin.py startproject mysite + docker run -it --rm --user "$(id -u):$(id -g)" -v "$PWD":/usr/src/app -w /usr/src/app django django-admin.py startproject mysite This will create a sub-directory named `mysite` inside your current directory. diff --git a/django/content.md b/django/content.md index 37685c5b8..60095c311 100644 --- a/django/content.md +++ b/django/content.md @@ -37,13 +37,13 @@ Of course, if you don't want to take advantage of magical and convenient `ONBUILD` triggers, you can always just use `docker run` directly to avoid having to add a `Dockerfile` to your project. - docker run --name some-django-app -v "$(pwd)":/usr/src/app -w /usr/src/app -p 8000:8000 -d django bash -c "pip install -r requirements.txt && python manage.py runserver 0.0.0.0:8000" + docker run --name some-django-app -v "$PWD":/usr/src/app -w /usr/src/app -p 8000:8000 -d django bash -c "pip install -r requirements.txt && python manage.py runserver 0.0.0.0:8000" ## Bootstrap a new Django Application If you want to generate the scaffolding for a new Django project, you can do the following: - docker run -it --rm --user "$(id -u):$(id -g)" -v "$(pwd)":/usr/src/app -w /usr/src/app django django-admin.py startproject mysite + docker run -it --rm --user "$(id -u):$(id -g)" -v "$PWD":/usr/src/app -w /usr/src/app django django-admin.py startproject mysite This will create a sub-directory named `mysite` inside your current directory. diff --git a/gcc/README.md b/gcc/README.md index 2785bc09b..4ba74a588 100644 --- a/gcc/README.md +++ b/gcc/README.md @@ -48,7 +48,7 @@ There may be occasions where it is not appropriate to run your app inside a container. To compile, but not run your app inside the Docker instance, you can write something like: - docker run --rm -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp gcc:4.9 gcc -o myapp myapp.c + docker run --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp gcc:4.9 gcc -o myapp myapp.c This will add your current directory, as a volume, to the container, set the working directory to the volume, and run the command `gcc -o myapp myapp.c.` @@ -56,7 +56,7 @@ This tells gcc to compile the code in `myapp.c` and output the executable to myapp. Alternatively, if you have a `Makefile`, you can instead run the `make` command inside your container: - docker run --rm -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp gcc:4.9 make + docker run --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp gcc:4.9 make # License diff --git a/gcc/content.md b/gcc/content.md index a0a34f6a1..1397f1915 100644 --- a/gcc/content.md +++ b/gcc/content.md @@ -35,7 +35,7 @@ There may be occasions where it is not appropriate to run your app inside a container. To compile, but not run your app inside the Docker instance, you can write something like: - docker run --rm -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp gcc:4.9 gcc -o myapp myapp.c + docker run --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp gcc:4.9 gcc -o myapp myapp.c This will add your current directory, as a volume, to the container, set the working directory to the volume, and run the command `gcc -o myapp myapp.c.` @@ -43,4 +43,4 @@ This tells gcc to compile the code in `myapp.c` and output the executable to myapp. Alternatively, if you have a `Makefile`, you can instead run the `make` command inside your container: - docker run --rm -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp gcc:4.9 make + docker run --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp gcc:4.9 make diff --git a/golang/README.md b/golang/README.md index 559d91b8f..327058483 100644 --- a/golang/README.md +++ b/golang/README.md @@ -55,7 +55,7 @@ There may be occasions where it is not appropriate to run your app inside a container. To compile, but not run your app inside the Docker instance, you can write something like: - docker run --rm -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp golang:1.3 go build -v + docker run --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp golang:1.3 go build -v This will add your current directory as a volume to the container, set the working directory to the volume, and run the command `go build` which will tell @@ -63,7 +63,7 @@ go to compile the project in the working directory and output the executable to `myapp`. Alternatively, if you have a `Makefile`, you can run the `make` command inside your container. - docker run --rm -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp golang:1.3 make + docker run --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp golang:1.3 make ## Cross-compile your app inside the Docker container @@ -71,11 +71,11 @@ If you need to compile your application for a platform other than `linux/amd64` (such as `windows/386`), this can be easily accomplished with the provided `cross` tags: - docker run --rm -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp -e GOOS=windows -e GOARCH=386 golang:1.3-cross go build -v + docker run --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp -e GOOS=windows -e GOARCH=386 golang:1.3-cross go build -v Alternatively, you can build for multiple platforms at once: - docker run --rm -it -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp golang:1.3-cross bash + docker run --rm -it -v "$PWD":/usr/src/myapp -w /usr/src/myapp golang:1.3-cross bash $ for GOOS in darwin linux; do > for GOARCH in 386 amd64; do > go build -v -o myapp-$GOOS-$GOARCH diff --git a/golang/content.md b/golang/content.md index e3e1b3c98..e7281190a 100644 --- a/golang/content.md +++ b/golang/content.md @@ -38,7 +38,7 @@ There may be occasions where it is not appropriate to run your app inside a container. To compile, but not run your app inside the Docker instance, you can write something like: - docker run --rm -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp golang:1.3 go build -v + docker run --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp golang:1.3 go build -v This will add your current directory as a volume to the container, set the working directory to the volume, and run the command `go build` which will tell @@ -46,7 +46,7 @@ go to compile the project in the working directory and output the executable to `myapp`. Alternatively, if you have a `Makefile`, you can run the `make` command inside your container. - docker run --rm -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp golang:1.3 make + docker run --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp golang:1.3 make ## Cross-compile your app inside the Docker container @@ -54,11 +54,11 @@ If you need to compile your application for a platform other than `linux/amd64` (such as `windows/386`), this can be easily accomplished with the provided `cross` tags: - docker run --rm -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp -e GOOS=windows -e GOARCH=386 golang:1.3-cross go build -v + docker run --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp -e GOOS=windows -e GOARCH=386 golang:1.3-cross go build -v Alternatively, you can build for multiple platforms at once: - docker run --rm -it -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp golang:1.3-cross bash + docker run --rm -it -v "$PWD":/usr/src/myapp -w /usr/src/myapp golang:1.3-cross bash $ for GOOS in darwin linux; do > for GOARCH in 386 amd64; do > go build -v -o myapp-$GOOS-$GOARCH diff --git a/httpd/README.md b/httpd/README.md index 7ce69f247..d38887e25 100644 --- a/httpd/README.md +++ b/httpd/README.md @@ -46,7 +46,7 @@ Then, run the commands to build and run the Docker image: If you don't want to include a `Dockerfile` in your project, it is sufficient to do the following: - docker run -it --rm --name my-apache-app -v "$(pwd)":/usr/local/apache2/htdocs/ httpd:2.4 + docker run -it --rm --name my-apache-app -v "$PWD":/usr/local/apache2/htdocs/ httpd:2.4 ### Configuration diff --git a/httpd/content.md b/httpd/content.md index 94eee246b..8518caee0 100644 --- a/httpd/content.md +++ b/httpd/content.md @@ -35,7 +35,7 @@ Then, run the commands to build and run the Docker image: If you don't want to include a `Dockerfile` in your project, it is sufficient to do the following: - docker run -it --rm --name my-apache-app -v "$(pwd)":/usr/local/apache2/htdocs/ httpd:2.4 + docker run -it --rm --name my-apache-app -v "$PWD":/usr/local/apache2/htdocs/ httpd:2.4 ### Configuration diff --git a/hylang/README.md b/hylang/README.md index 2eccba0b7..ab42c1685 100644 --- a/hylang/README.md +++ b/hylang/README.md @@ -42,7 +42,7 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Hy script by using the Hy Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp hylang:0.10 hy your-daemon-or-script.hy + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp hylang:0.10 hy your-daemon-or-script.hy # License diff --git a/hylang/content.md b/hylang/content.md index 455302a57..6d199275a 100644 --- a/hylang/content.md +++ b/hylang/content.md @@ -32,4 +32,4 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Hy script by using the Hy Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp hylang:0.10 hy your-daemon-or-script.hy + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp hylang:0.10 hy your-daemon-or-script.hy diff --git a/java/README.md b/java/README.md index e5acc4a19..06306ed74 100644 --- a/java/README.md +++ b/java/README.md @@ -51,7 +51,7 @@ There may be occasions where it is not appropriate to run your app inside a container. To compile, but not run your app inside the Docker instance, you can write something like: - docker run --rm -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp java:7 javac Main.java + docker run --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp java:7 javac Main.java This will add your current directory as a volume to the container, set the working directory to the volume, and run the command `javac Main.java` which diff --git a/java/content.md b/java/content.md index 5735e7dbe..ba87e3ced 100644 --- a/java/content.md +++ b/java/content.md @@ -36,7 +36,7 @@ There may be occasions where it is not appropriate to run your app inside a container. To compile, but not run your app inside the Docker instance, you can write something like: - docker run --rm -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp java:7 javac Main.java + docker run --rm -v "$PWD":/usr/src/myapp -w /usr/src/myapp java:7 javac Main.java This will add your current directory as a volume to the container, set the working directory to the volume, and run the command `javac Main.java` which diff --git a/jruby/README.md b/jruby/README.md index c9cd89ff7..e0d00fcc4 100644 --- a/jruby/README.md +++ b/jruby/README.md @@ -57,7 +57,7 @@ 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 bundle install --system + docker run --rm -v "$PWD":/usr/src/app -w /usr/src/app jruby:1.7 bundle install --system ## Run a single Ruby script @@ -65,7 +65,7 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Ruby script by using the Ruby Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp jruby:1.7 jruby your-daemon-or-script.rb + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp jruby:1.7 jruby your-daemon-or-script.rb # License diff --git a/jruby/content.md b/jruby/content.md index 5324c963f..c430b04c9 100644 --- a/jruby/content.md +++ b/jruby/content.md @@ -42,7 +42,7 @@ 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 bundle install --system + docker run --rm -v "$PWD":/usr/src/app -w /usr/src/app jruby:1.7 bundle install --system ## Run a single Ruby script @@ -50,4 +50,4 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Ruby script by using the Ruby Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp jruby:1.7 jruby your-daemon-or-script.rb + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp jruby:1.7 jruby your-daemon-or-script.rb diff --git a/maven/README.md b/maven/README.md index 1f6fdefad..c8620f41e 100644 --- a/maven/README.md +++ b/maven/README.md @@ -49,7 +49,7 @@ For many simple projects, you may find it inconvenient to write a complete In such cases, you can run a Maven project by using the Maven Docker image directly, passing a Maven command to `docker run`: - docker run -it --rm --name my-maven-project -v "$(pwd)":/usr/src/mymaven -w /usr/src/mymaven maven:3.2-jdk-7 mvn clean install + docker run -it --rm --name my-maven-project -v "$PWD":/usr/src/mymaven -w /usr/src/mymaven maven:3.2-jdk-7 mvn clean install # License diff --git a/maven/content.md b/maven/content.md index 982c39b5a..cdb718102 100644 --- a/maven/content.md +++ b/maven/content.md @@ -34,4 +34,4 @@ For many simple projects, you may find it inconvenient to write a complete In such cases, you can run a Maven project by using the Maven Docker image directly, passing a Maven command to `docker run`: - docker run -it --rm --name my-maven-project -v "$(pwd)":/usr/src/mymaven -w /usr/src/mymaven maven:3.2-jdk-7 mvn clean install + docker run -it --rm --name my-maven-project -v "$PWD":/usr/src/mymaven -w /usr/src/mymaven maven:3.2-jdk-7 mvn clean install diff --git a/node/README.md b/node/README.md index c749defa6..ab45096c4 100644 --- a/node/README.md +++ b/node/README.md @@ -64,7 +64,7 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Node.js script by using the Node.js Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp node:0.10 node your-daemon-or-script.js + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp node:0.10 node your-daemon-or-script.js # License diff --git a/node/content.md b/node/content.md index c0177a694..96b91b61d 100644 --- a/node/content.md +++ b/node/content.md @@ -46,4 +46,4 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Node.js script by using the Node.js Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp node:0.10 node your-daemon-or-script.js + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp node:0.10 node your-daemon-or-script.js diff --git a/perl/README.md b/perl/README.md index 942203d24..2b580295a 100644 --- a/perl/README.md +++ b/perl/README.md @@ -41,7 +41,7 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Perl script by using the Perl Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp perl:5.20 perl your-daemon-or-script.pl + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp perl:5.20 perl your-daemon-or-script.pl # License diff --git a/perl/content.md b/perl/content.md index 9a0ca6a5f..63dae1e62 100644 --- a/perl/content.md +++ b/perl/content.md @@ -28,4 +28,4 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Perl script by using the Perl Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp perl:5.20 perl your-daemon-or-script.pl + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp perl:5.20 perl your-daemon-or-script.pl diff --git a/php/README.md b/php/README.md index 0d2665ea4..f518faa2f 100644 --- a/php/README.md +++ b/php/README.md @@ -54,7 +54,7 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a PHP script by using the PHP Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp php:5.6-cli php your-script.php + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp php:5.6-cli php your-script.php ## With Apache @@ -109,7 +109,7 @@ you can use the `docker-php-ext-configure` script like this example. If you don't want to include a `Dockerfile` in your project, it is sufficient to do the following: - docker run -it --rm --name my-apache-php-app -v "$(pwd)":/var/www/html php:5.6-apache + docker run -it --rm --name my-apache-php-app -v "$PWD":/var/www/html php:5.6-apache # License diff --git a/php/content.md b/php/content.md index a4947408d..10dc2ba07 100644 --- a/php/content.md +++ b/php/content.md @@ -36,7 +36,7 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a PHP script by using the PHP Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp php:5.6-cli php your-script.php + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp php:5.6-cli php your-script.php ## With Apache @@ -91,4 +91,4 @@ you can use the `docker-php-ext-configure` script like this example. If you don't want to include a `Dockerfile` in your project, it is sufficient to do the following: - docker run -it --rm --name my-apache-php-app -v "$(pwd)":/var/www/html php:5.6-apache + docker run -it --rm --name my-apache-php-app -v "$PWD":/var/www/html php:5.6-apache diff --git a/pypy/README.md b/pypy/README.md index 5f05dd59c..04c4165e3 100644 --- a/pypy/README.md +++ b/pypy/README.md @@ -55,11 +55,11 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Python script by using the Python Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp pypy:3 pypy3 your-daemon-or-script.py + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp pypy:3 pypy3 your-daemon-or-script.py or (again, if you need to use Python 2): - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp pypy:2 pypy your-daemon-or-script.py + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp pypy:2 pypy your-daemon-or-script.py # License diff --git a/pypy/content.md b/pypy/content.md index 9ccbb5074..eb2b3abbf 100644 --- a/pypy/content.md +++ b/pypy/content.md @@ -40,8 +40,8 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Python script by using the Python Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp pypy:3 pypy3 your-daemon-or-script.py + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp pypy:3 pypy3 your-daemon-or-script.py or (again, if you need to use Python 2): - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp pypy:2 pypy your-daemon-or-script.py + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp pypy:2 pypy your-daemon-or-script.py diff --git a/python/README.md b/python/README.md index 3ab8537ae..db3a125cd 100644 --- a/python/README.md +++ b/python/README.md @@ -62,11 +62,11 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Python script by using the Python Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp python:3 python your-daemon-or-script.py + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp python:3 python your-daemon-or-script.py or (again, if you need to use Python 2): - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp python:2 python your-daemon-or-script.py + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp python:2 python your-daemon-or-script.py # License diff --git a/python/content.md b/python/content.md index d25bfa0e2..9225eb6bc 100644 --- a/python/content.md +++ b/python/content.md @@ -41,8 +41,8 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Python script by using the Python Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp python:3 python your-daemon-or-script.py + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp python:3 python your-daemon-or-script.py or (again, if you need to use Python 2): - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp python:2 python your-daemon-or-script.py + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp python:2 python your-daemon-or-script.py diff --git a/r-base/README.md b/r-base/README.md index 2cf1c71ba..f2d9a6b03 100644 --- a/r-base/README.md +++ b/r-base/README.md @@ -31,7 +31,7 @@ R is a GNU project. The source code for the R software environment is written primarily in C, Fortran, and R. R is freely available under the GNU General Public License, and pre-compiled binary versions are provided for various operating systems. R uses a command line interface; however, several -graphical user interfaces are available for use with R. +graphical user interfaces are available for use with R. > [R FAQ](http://cran.r-project.org/doc/FAQ/R-FAQ.html#What-is-R_003f) > [wikipedia.org/wiki/R_(programming_language)](http://en.wikipedia.org/wiki/R_(programming_language)) @@ -52,7 +52,7 @@ Link the working directory to run R batch commands. We recommend specifying a non-root user when linking a volume to the container to avoid permission changes, as illustrated here: - docker run -ti --rm -v $(pwd):/home/docker -w /home/docker -u docker r-base R CMD check . + docker run -ti --rm -v "$PWD":/home/docker -w /home/docker -u docker r-base R CMD check . Alternatively, just run a bash session on the container first. This allows a user to run batch commands and also edit and run scripts: @@ -112,7 +112,7 @@ You are invited to contribute new features, fixes, or updates, large or small; we are always thrilled to receive pull requests, and do our best to process them as fast as we can. -Before you start to code, we recommend discussing your plans +Before you start to code, we recommend discussing your plans through a [GitHub issue](https://github.com/rocker-org/rocker/issues), especially for more ambitious contributions. This gives other contributors a chance to point you in the right direction, give you feedback on your design, and help you find out if someone diff --git a/r-base/content.md b/r-base/content.md index e433d8080..8e931fe30 100644 --- a/r-base/content.md +++ b/r-base/content.md @@ -21,7 +21,7 @@ R is a GNU project. The source code for the R software environment is written primarily in C, Fortran, and R. R is freely available under the GNU General Public License, and pre-compiled binary versions are provided for various operating systems. R uses a command line interface; however, several -graphical user interfaces are available for use with R. +graphical user interfaces are available for use with R. > [R FAQ](http://cran.r-project.org/doc/FAQ/R-FAQ.html#What-is-R_003f) > [wikipedia.org/wiki/R_(programming_language)](http://en.wikipedia.org/wiki/R_(programming_language)) @@ -42,7 +42,7 @@ Link the working directory to run R batch commands. We recommend specifying a non-root user when linking a volume to the container to avoid permission changes, as illustrated here: - docker run -ti --rm -v $(pwd):/home/docker -w /home/docker -u docker r-base R CMD check . + docker run -ti --rm -v "$PWD":/home/docker -w /home/docker -u docker r-base R CMD check . Alternatively, just run a bash session on the container first. This allows a user to run batch commands and also edit and run scripts: diff --git a/rails/README.md b/rails/README.md index d2d244e5b..22b31195d 100644 --- a/rails/README.md +++ b/rails/README.md @@ -53,14 +53,14 @@ 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 bundle install + docker run --rm -v "$PWD":/usr/src/app -w /usr/src/app ruby:2.1 bundle install ## Bootstrap a new Rails application If you want to generate the scaffolding for a new Rails project, you can do the following: - docker run -it --rm --user "$(id -u):$(id -g)" -v "$(pwd)":/usr/src/app -w /usr/src/app rails rails new webapp + docker run -it --rm --user "$(id -u):$(id -g)" -v "$PWD":/usr/src/app -w /usr/src/app rails rails new webapp This will create a sub-directory named `webapp` inside your current directory. diff --git a/rails/content.md b/rails/content.md index e9ec8e971..3536159df 100644 --- a/rails/content.md +++ b/rails/content.md @@ -42,13 +42,13 @@ 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 bundle install + docker run --rm -v "$PWD":/usr/src/app -w /usr/src/app ruby:2.1 bundle install ## Bootstrap a new Rails application If you want to generate the scaffolding for a new Rails project, you can do the following: - docker run -it --rm --user "$(id -u):$(id -g)" -v "$(pwd)":/usr/src/app -w /usr/src/app rails rails new webapp + docker run -it --rm --user "$(id -u):$(id -g)" -v "$PWD":/usr/src/app -w /usr/src/app rails rails new webapp This will create a sub-directory named `webapp` inside your current directory. diff --git a/rethinkdb/README.md b/rethinkdb/README.md index 1b20fce2c..59e7d26d5 100644 --- a/rethinkdb/README.md +++ b/rethinkdb/README.md @@ -29,7 +29,7 @@ will bind to all network interfaces available to the container (by default, RethinkDB only accepts connections from `localhost`). ```bash -docker run --name some-rethink -v "$(pwd):/data" -d rethinkdb +docker run --name some-rethink -v "$PWD:/data" -d rethinkdb ``` ## Connect the instance to an application diff --git a/rethinkdb/content.md b/rethinkdb/content.md index e98b337cb..8a9968827 100644 --- a/rethinkdb/content.md +++ b/rethinkdb/content.md @@ -16,7 +16,7 @@ will bind to all network interfaces available to the container (by default, RethinkDB only accepts connections from `localhost`). ```bash -docker run --name some-rethink -v "$(pwd):/data" -d rethinkdb +docker run --name some-rethink -v "$PWD:/data" -d rethinkdb ``` ## Connect the instance to an application diff --git a/ruby/README.md b/ruby/README.md index 141f014f9..759ac2713 100644 --- a/ruby/README.md +++ b/ruby/README.md @@ -55,7 +55,7 @@ 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 bundle install + docker run --rm -v "$PWD":/usr/src/app -w /usr/src/app ruby:2.1 bundle install ## Run a single Ruby script @@ -63,7 +63,7 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Ruby script by using the Ruby Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp ruby:2.1 ruby your-daemon-or-script.rb + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp ruby:2.1 ruby your-daemon-or-script.rb # License diff --git a/ruby/content.md b/ruby/content.md index 8f6a9d944..f3f0e2d4f 100644 --- a/ruby/content.md +++ b/ruby/content.md @@ -34,7 +34,7 @@ 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 bundle install + docker run --rm -v "$PWD":/usr/src/app -w /usr/src/app ruby:2.1 bundle install ## Run a single Ruby script @@ -42,4 +42,4 @@ For many simple, single file projects, you may find it inconvenient to write a complete `Dockerfile`. In such cases, you can run a Ruby script by using the Ruby Docker image directly: - docker run -it --rm --name my-running-script -v "$(pwd)":/usr/src/myapp -w /usr/src/myapp ruby:2.1 ruby your-daemon-or-script.rb + docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp ruby:2.1 ruby your-daemon-or-script.rb diff --git a/thrift/README.md b/thrift/README.md index 380df1f21..c910d97bc 100644 --- a/thrift/README.md +++ b/thrift/README.md @@ -24,7 +24,7 @@ This is image is intended to run as an executable. Files are provided by mounting a directory. Here's an example of compiling `service.thrift` to ruby to the current directory. - docker run -v "$(pwd):/data" thrift thrift -o /data --gen rb /data/service.thrift + docker run -v "$PWD:/data" thrift thrift -o /data --gen rb /data/service.thrift Note, that you may want to include `-u $(id -u)` to set the UID on generated files. The thrift process runs as root by default which will diff --git a/thrift/content.md b/thrift/content.md index 384fa865b..f4c957677 100644 --- a/thrift/content.md +++ b/thrift/content.md @@ -14,7 +14,7 @@ This is image is intended to run as an executable. Files are provided by mounting a directory. Here's an example of compiling `service.thrift` to ruby to the current directory. - docker run -v "$(pwd):/data" thrift thrift -o /data --gen rb /data/service.thrift + docker run -v "$PWD:/data" thrift thrift -o /data --gen rb /data/service.thrift Note, that you may want to include `-u $(id -u)` to set the UID on generated files. The thrift process runs as root by default which will