+# Current version 0.2.5
FROM samsaffron/discourse_base:0.2.3
MAINTAINER Sam Saffron "https://twitter.com/samsaffron"
# Discourse specific bits
RUN useradd discourse -s /bin/bash -m -U &&\
mkdir /var/www && cd /var/www &&\
- git clone --depth 1 https://github.com/discourse/discourse.git &&\
+ git clone https://github.com/discourse/discourse.git &&\
+ cd discourse &&\
+ git remote set-branches origin tests-passed &&\
+ cd .. &&\
chown -R discourse:discourse /var/www/discourse &&\
cd /var/www/discourse &&\
sudo -u discourse RAILS4=1 bundle install --deployment \
--without test --without development &&\
cd /var/www/discourse/vendor/bundle &&\
- find . -name tmp -type d | xargs rm -rf && cd /
-
-RUN wget https://bitbucket.org/ariya/phantomjs/downloads/phantomjs-1.9.7-linux-x86_64.tar.bz2 &&\
+ find . -name tmp -type d | xargs rm -rf && cd / &&\
+ wget https://bitbucket.org/ariya/phantomjs/downloads/phantomjs-1.9.7-linux-x86_64.tar.bz2 &&\
tar -xjf phantomjs-1.9.7-linux-x86_64.tar.bz2 &&\
rm phantomjs-1.9.7-linux-x86_64.tar.bz2 &&\
cp phantomjs-1.9.7-linux-x86_64/bin/phantomjs /bin/phantomjs &&\
+# Current version 2.1.2.2
FROM samsaffron/discourse_base_21:2.1.2.1
MAINTAINER Sam Saffron "https://twitter.com/samsaffron"
-# Discourse specific bits
RUN useradd discourse -s /bin/bash -m -U &&\
mkdir /var/www && cd /var/www &&\
- git clone --depth 1 https://github.com/discourse/discourse.git &&\
+ git clone https://github.com/discourse/discourse.git &&\
+ cd discourse &&\
+ git remote set-branches origin tests-passed &&\
+ cd .. &&\
chown -R discourse:discourse /var/www/discourse &&\
cd /var/www/discourse &&\
sudo -u discourse RAILS4=1 bundle install --deployment \
--without test --without development &&\
cd /var/www/discourse/vendor/bundle &&\
- find . -name tmp -type d | xargs rm -rf && cd /
-
-
-# For a smaller but less flexible image:
-#RUN apt-get -y autoremove build-essential gcc gcc-4.7 .+-dev
-#RUN echo image size: $(du -hsx /)
-
-# RUN cd /var/www/discourse && bundle exec rake db:test:prepare && bundle exec rspec
-
-# mkdir -p /src/godeb && cd /src/godeb && curl -O https://godeb.s3.amazonaws.com/godeb-amd64.tar.gz &&\
-# cd /src/godeb && tar -xzvf godeb-amd64.tar.gz &&\
-# cd /src/godeb && ./godeb install &&\
-# cd /src && git clone https://github.com/coreos/etcd.git &&\
-# cd /src/etcd && ./build &&\
-# cp /src/etcd/etcd /usr/local/bin &&\
-# add-apt-repository ppa:chris-lea/node.js &&\
+ find . -name tmp -type d | xargs rm -rf && cd / &&\
+ wget https://bitbucket.org/ariya/phantomjs/downloads/phantomjs-1.9.7-linux-x86_64.tar.bz2 &&\
+ tar -xjf phantomjs-1.9.7-linux-x86_64.tar.bz2 &&\
+ rm phantomjs-1.9.7-linux-x86_64.tar.bz2 &&\
+ cp phantomjs-1.9.7-linux-x86_64/bin/phantomjs /bin/phantomjs &&\
+ rm -fr phantomjs-1.9.7-linux-x86_64
cidfile=cids/"$config".cid
cidbootstrap=cids/"$config"_boostrap.cid
local_discourse=local_discourse
-image=samsaffron/discourse:0.2.4
+image=samsaffron/discourse:0.2.5
docker_path=`which docker.io || which docker`
docker_ip=`/sbin/ifconfig | \