#!/bin/bash
cat << EOF >> /etc/profile
for item in \`cat /proc/1/environ |tr '\0' '\n'\`
do
  export \$item
done
EOF

service ssh start

ldconfig

echo "root:${JUPYTER_PWD:=MoPaaS_anchora}" | chpasswd

start-stop-daemon --start --background --no-close --make-pidfile --pidfile=/var/run/jupyter.pid \
--startas $(which jupyter-notebook) -- --config=/etc/jupyter/jupyter_notebook_config.py >> /dev/pts/0 2>&1

sleep infinity

