remove bundler pre ... not working right
[discourse_docker.git] / image / Dockerfile
1 # DOCKER-VERSION 0.6.7
2
3 # 13.10 - 04 has a missing ppa for postgresql 9.2 at the moment (26/10/2013)
4 FROM samsaffron/discourse_base:0.1.1
5
6 MAINTAINER Sam Saffron "https://twitter.com/samsaffron"
7
8 # Discourse specific bits
9 RUN useradd discourse -s /bin/bash -m -U &&\
10 mkdir /var/www && cd /var/www &&\
11 git clone --depth 1 https://github.com/discourse/discourse.git &&\
12 chown -R discourse:discourse /var/www/discourse && cd / &&\
13 cd /var/www/discourse &&\
14 sudo -u discourse RAILS4=1 bundle install --deployment \
15 --without test --without development &&\
16 cd /var/www/discourse/vendor/bundle &&\
17 find . -name tmp -type d | xargs rm -rf && cd /
18
19
20 # For a smaller but less flexible image:
21 #RUN apt-get -y autoremove build-essential gcc gcc-4.7 .+-dev
22 #RUN echo image size: $(du -hsx /)
23
24 # RUN cd /var/www/discourse && bundle exec rake db:test:prepare && bundle exec rspec
25
26 # mkdir -p /src/godeb && cd /src/godeb && curl -O https://godeb.s3.amazonaws.com/godeb-amd64.tar.gz &&\
27 # cd /src/godeb && tar -xzvf godeb-amd64.tar.gz &&\
28 # cd /src/godeb && ./godeb install &&\
29 # cd /src && git clone https://github.com/coreos/etcd.git &&\
30 # cd /src/etcd && ./build &&\
31 # cp /src/etcd/etcd /usr/local/bin &&\
32 # add-apt-repository ppa:chris-lea/node.js &&\