FROM phusion/baseimage

MAINTAINER Sharry Stowell

CMD ["/sbin/my_init"]

RUN apt-get update && apt-get install -y \
    git \
    wget \
    libxml2-dev \
    python \
    build-essential \
    make \
    gcc \
    htop \
    byobu

# Install Node
RUN \
  wget -O - http://nodejs.org/dist/v0.10.29/node-v0.10.29-linux-x64.tar.gz \
  | tar xzf - --strip-components=1 --exclude="README.md" --exclude="LICENSE" \
  --exclude="ChangeLog" -C "/usr/local"

# Global NPM installs
RUN npm install --silent -g gulp mocha bower nodemon

RUN git clone https://83cbb505d46274d68f5cee34b032c89edfbc5d13:x-oauth-basic@github.com/sosocial/sosocial-website.git /home/sosocial-website

# Set the working directory
WORKDIR /home/sosocial-website

#ADD package.json /package.json
RUN npm install

RUN apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*

ENV NODE_ENV development

EXPOSE 3001

# Set the working directory
#WORKDIR /home/sosocial-website