diff --git a/Dockerfile b/Dockerfile index 618454c978..1bcc66313e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -28,11 +28,13 @@ RUN npm install -g gulp grunt-cli bower # Clone Habitica repo and install dependencies WORKDIR /habitrpg RUN git clone https://github.com/HabitRPG/habitrpg.git /habitrpg +#RUN test -e /habitrpg || git clone https://github.com/HabitRPG/habitrpg.git /habitrpg RUN npm install RUN bower install --allow-root # Create environment config file and build directory RUN cp config.json.example config.json +#RUN test -e config.json || cp config.json.example config.json RUN mkdir -p ./website/build # Start Habitica diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml new file mode 100644 index 0000000000..33216b0184 --- /dev/null +++ b/docker-compose.dev.yml @@ -0,0 +1,3 @@ +web: + volumes: + - '.:/habitrpg' diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000000..898000def7 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,13 @@ +web: + build: . + ports: + - "3000:3000" + links: + - mongo + environment: + - NODE_DB_URI=mongodb://mongo/habitrpg + +mongo: + image: mongo + ports: + - "27017:27017"