-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile
45 lines (36 loc) · 939 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
user=fcat
project=dotrb2013
# cache images
ubuntu_universe=${user}/ubuntu-universe
ubuntu_universe_tagged=${ubuntu_universe}:12.04
rails_base=${user}/${project}-rails-base
postgresql=${user}/postgresql
# final images
postgresql_with_db=${user}/${project}-postgresql
rails=${user}/${project}-rails
all:
build:
docker build -t ${ubuntu_universe_tagged} ubuntu-universe
docker build -t ${rails_base} rails-base
docker build -t ${rails} rails
docker build -t ${postgresql} postgresql
list:
docker images ${ubuntu_universe}
docker images ${rails_base}
docker images ${rails}
docker images ${postgresql}
docker images ${postgresql_with_db}
pull:
docker pull ${rails}
docker pull ${postgresql_with_db}
push:
docker push ${ubuntu_universe}
docker push ${rails_base}
docker push ${rails}
docker push ${postgresql}
docker push ${postgresql_with_db}
run:
docker run ${rails}
docker run ${postgresql_with_db}
ps:
docker ps