-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Dockerfile for development environment
- Loading branch information
Showing
6 changed files
with
69 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
FROM phusion/baseimage:0.9.16 | ||
MAINTAINER Simon Elsbrock <simon@iodev.org> | ||
|
||
ENV LANG en_US.UTF-8 | ||
|
||
RUN /etc/my_init.d/00_regen_ssh_host_keys.sh | ||
CMD ["/sbin/my_init"] | ||
|
||
RUN echo 'Acquire::http::Proxy "http://10.42.23.55:3142";' > /etc/apt/apt.conf.d/90-apt-cacher.conf | ||
|
||
RUN \ | ||
echo "APT::Install-Recommends \"true\";\nAPT::Install-Suggests \"false\";" > /etc/apt/apt.conf ;\ | ||
echo "Europe/Berlin" > /etc/timezone && DEBIAN_FRONTEND=noninteractive dpkg-reconfigure tzdata ;\ | ||
locale-gen en_US.UTF-8 en_DK.UTF-8 de_DE.UTF-8 ;\ | ||
apt-get -q -y update ;\ | ||
apt-get install -y git nodejs npm ruby ruby-dev make gcc ;\ | ||
apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* ;\ | ||
update-alternatives --install /usr/bin/node node /usr/bin/nodejs 10 ;\ | ||
gem install jekyll --no-rdoc --no-ri ;\ | ||
mkdir -p /etc/my_init.d | ||
|
||
RUN \ | ||
adduser --disabled-password --gecos "" dev | ||
|
||
ADD install-deps.sh /etc/my_init.d/install-deps.sh | ||
|
||
EXPOSE 8000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
This docker container aims to minimize the efforts to get a development | ||
environment running. The idea is that you simply run this container and start | ||
hacking. The container mounts the repository root as volume and does not store | ||
any data within itself. | ||
|
||
The container comes preinstalled with all static dependencies. In addition, it | ||
takes care of the following: | ||
* installing npm dependencies | ||
* installing bower dependencies | ||
* running `grunt serve` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#!/bin/bash | ||
|
||
cd /home/dev | ||
|
||
grep -sq 'github.com/raumzeitlabor/rzl-homepage' .git/config || { \ | ||
echo -e "\nDid you mount the rzl-homepage repository root?\n"; exit 1; \ | ||
} | ||
|
||
sudo -u dev -s -- <<EOF | ||
npm install | ||
export PATH=./node_modules/.bin:$PATH | ||
bower install | ||
grunt serve | ||
EOF |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#!/bin/bash | ||
|
||
sudo -u app npm install | ||
sudo -u app PATH=./node_modules/.bin:$PATH bower install | ||
sudo -u app grunt serve |