diff --git a/cli.html b/cli.html index 4b2f542d..b4548bfe 100644 --- a/cli.html +++ b/cli.html @@ -6,7 +6,7 @@ - +
diff --git a/django.html b/django.html index 1ece4a53..be1eb11a 100644 --- a/django.html +++ b/django.html @@ -6,7 +6,7 @@ - + diff --git a/env.html b/env.html index 088840e8..3943dd88 100644 --- a/env.html +++ b/env.html @@ -6,7 +6,7 @@ - + diff --git a/index.html b/index.html index 642dbac4..9bbb3495 100644 --- a/index.html +++ b/index.html @@ -6,7 +6,7 @@ - + @@ -82,7 +82,7 @@ $ cd figtest redisNext, we want to create a Docker image containing all of our app's dependencies. We specify how to build one using a file called Dockerfile:
FROM orchardup/python:2.7
+FROM python:2.7
ADD . /code
WORKDIR /code
RUN pip install -r requirements.txt
@@ -100,18 +100,18 @@ RUN pip install -r requirements.txt
links:
- redis
redis:
- image: orchardup/redis
+ image: redis
This defines two services:
web, which is built from Dockerfile in the current directory. It also says to run the command python app.py inside the image, forward the exposed port 5000 on the container to port 5000 on the host machine, connect up the Redis service, and mount the current directory inside the container so we can work on code without having to rebuild the image.
-redis, which uses the public image orchardup/redis.
+redis, which uses the public image redis.
Now if we run fig up, it'll pull a Redis image, build an image for our own code, and start everything up:
$ fig up
-Pulling image orchardup/redis...
+Pulling image redis...
Building web...
Starting figtest_redis_1...
Starting figtest_web_1...
diff --git a/install.html b/install.html
index a83ec9fe..8782f454 100644
--- a/install.html
+++ b/install.html
@@ -6,7 +6,7 @@
-
+
diff --git a/rails.html b/rails.html
index eb47bcdc..2d26d9a8 100644
--- a/rails.html
+++ b/rails.html
@@ -6,7 +6,7 @@
-
+
@@ -39,7 +39,7 @@ gem 'rails', '4.0.2'
Finally, fig.yml is where the magic happens. It describes what services our app comprises (a database and a web app), how to get each one's Docker image (the database just runs on a pre-made PostgreSQL image, and the web app is built from the current directory), and the configuration we need to link them together and expose the web app's port.
db:
- image: orchardup/postgresql
+ image: postgres
ports:
- "5432"
web:
@@ -69,18 +69,17 @@ Rakefile db test
Now that we've got a new Gemfile, we need to build the image again. (This, and changes to the Dockerfile itself, should be the only times you'll need to rebuild).
$ fig build
-The app is now bootable, but we're not quite there yet. By default, Rails expects a database to be running on localhost - we need to point it at the db container instead. We also need to change the username and password to align with the defaults set by orchardup/postgresql.
+The app is now bootable, but we're not quite there yet. By default, Rails expects a database to be running on localhost - we need to point it at the db container instead. We also need to change the database and username to align with the defaults set by the postgres image.
Open up your newly-generated database.yml. Replace its contents with the following:
development: &default
adapter: postgresql
encoding: unicode
- database: myapp_development
+ database: postgres
pool: 5
- username: docker
- password: docker
- host: <%= ENV.fetch('DB_1_PORT_5432_TCP_ADDR', 'localhost') %>
- port: <%= ENV.fetch('DB_1_PORT_5432_TCP_PORT', '5432') %>
+ username: postgres
+ password:
+ host: db_1
test:
<<: *default
diff --git a/wordpress.html b/wordpress.html
index 1f227bcd..fd31674d 100644
--- a/wordpress.html
+++ b/wordpress.html
@@ -6,7 +6,7 @@
-
+
diff --git a/yml.html b/yml.html
index 192567e4..8b2258e4 100644
--- a/yml.html
+++ b/yml.html
@@ -6,7 +6,7 @@
-
+