diff --git a/DOCKER/Dockerfile b/DOCKER/Dockerfile
index 8553dcdda076500d01296205c53e5c46e87bb55d..62467f4c5c40718087fe92c8efda22f55947fec1 100644
--- a/DOCKER/Dockerfile
+++ b/DOCKER/Dockerfile
@@ -6,7 +6,7 @@ MAINTAINER Eris Industries <support@erisindustries.com>
 # dependencies
 RUN apt-get update && \
   apt-get install -y --no-install-recommends \
-    libgmp3-dev && \
+    libgmp3-dev jq && \
   rm -rf /var/lib/apt/lists/*
 
 #-----------------------------------------------------------------------------
@@ -67,6 +67,8 @@ ENV ECM_PATH /usr/local/lib/ecm/
 RUN mkdir -p $ECM_PATH
 COPY DOCKER/chain_* $ECM_PATH
 COPY DOCKER/config.toml $ECM_PATH
+RUN chown -R eris $ECM_PATH
+
 
 #-----------------------------------------------------------------------------
 # root dir
diff --git a/DOCKER/chain_new.sh b/DOCKER/chain_new.sh
index 1e6160b4227e62d448b040770316455add33d60a..7761ceee9e2caf5bbb831db7a33f0fc506535960 100755
--- a/DOCKER/chain_new.sh
+++ b/DOCKER/chain_new.sh
@@ -1,12 +1,23 @@
 #! /bin/bash
 
-echo "new chain: $CHAIN_ID"
+echo "your new chain, kind marmot: $CHAIN_ID"
 
 if [ "$GENERATE_GENESIS" = "true" ]; then
-	mintgen random --dir="/home/eris/.eris/blockchains/$CHAIN_ID" 1 $CHAIN_ID
-	ifExit "Error creating genesis file"
+	if [ "$CSV" = "" ]; then
+		mintgen random --dir="$CHAIN_DIR" 1 $CHAIN_ID
+		ifExit "Error creating random genesis file"
+	else
+		mintgen known --csv="$CSV" $CHAIN_ID > $CHAIN_DIR/genesis.json
+		ifExit "Error creating genesis file from csv"
+	fi
+else
+	# apparently just outputing to $CHAIN_DIR/genesis.json doesn't work so we copy
+	cat $CHAIN_DIR/genesis.json | jq .chain_id=\"$CHAIN_ID\" > genesis.json
+	cp genesis.json $CHAIN_DIR/genesis.json
 fi
 
+mintconfig $CONFIG_OPTS > $CHAIN_DIR/config.toml
+
 if [ "$RUN" = "true" ]; then
 	tendermint node
 	ifExit "Error starting tendermint"