New base image
[discourse_docker.git] / image / discourse_bench / Dockerfile
1 FROM samsaffron/discourse_test:latest
2
3 MAINTAINER Gerhard Schlager <mail@gerhard-schlager.at>
4
5 # Install ApacheBench
6 RUN apt-get install -y apache2-utils libsqlite3-dev
7
8 # configure Git to suppress warnings
9 RUN git config --global user.email "you@example.com" &&\
10 git config --global user.name "Your Name"
11
12 RUN git pull &&\
13 sudo -u discourse bundle install --standalone
14
15 RUN gem install facter &&\
16 gem install mailcatcher
17
18 # reconfigure PostgreSQL template databases to use UTF-8
19 # otherwise rake db:create fails
20 RUN pg_dropcluster --stop 9.3 main &&\
21 pg_createcluster --start -e UTF-8 9.3 main
22
23 # create role "discourse"
24 RUN /etc/init.d/postgresql start &&\
25 sudo -u postgres createuser --superuser discourse
26
27 ADD run_bench.sh /tmp/run_bench.sh
28 RUN chmod +x /tmp/run_bench.sh
29
30 ENTRYPOINT ["/tmp/run_bench.sh"]