如何在Docker中运行Iojs?

我有以下的Dockerfile:

FROM ubuntu:14.10 ENV HOMEDIR /usr/share/iojs RUN apt-get update && \ apt-get install software-properties-common python-software-properties -qq -y && \ apt-get upgrade -y && \ apt-get install -qq -y supervisor npm RUN cd ${HOMEDIR} && \ wget -qO- https://raw.githubusercontent.com/creationix/nvm/v0.26.1/install.sh | bash && \ . ~/.nvm/nvm.sh && \ nvm install iojs RUN supervisorctl restart iojs EXPOSE 80 CMD ["/usr/bin/supervisord", "-n"] 

/etc/supervisor/conf.d/supervisord.conf

 [supervisord] autostart=true autorestart=true nodaemon=true [program:iojs] directory=/usr/share/iojs command=/usr/bin/iojs index.js autostart=true autorestart=true 

注:脚本位于/usr/share/iojs

这是一个不同的方法,而不是说你的不工作。 为什么不从基于Debian 8的dockerhub的iojs映像开始。

Dockerfile:

 FROM iojs # ... 

supervisord conf:

 [supervisord] autostart=true autorestart=true nodaemon=true [program:iojs] directory=/usr/share/iojs command=/usr/local/bin/iojs index.js autostart=true autorestart=true