updating example to be a helloworld node applciation
FROM ubuntu | ||
CMD /bin/sh -c "while true; do ping 8.8.8.8; sleep 10; done" | ||
# Copyright 2014 IBM | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
FROM node | ||
MAINTAINER Robbie Minshall "[email protected]" | ||
# Install the application | ||
ADD package.json /app/package.json | ||
RUN cd /app && npm install | ||
ADD app.js /app/app.js | ||
ENV WEB_PORT 80 | ||
EXPOSE 80 | ||
# Define command to run the application when the container starts | ||
CMD ["node", "/app/app.js"] | ||
app.js
0 → 100644
package.json
0 → 100644
{ | ||
"name": "docker-hello", | ||
"private": true, | ||
"version": "0.0.1", | ||
"description": "Basic hello world application for Node.js", | ||
"author": "Robbie Minshall <[email protected]>", | ||
"dependencies": { | ||
"express": "3.4.8", | ||
"mocha": "*", | ||
"should": "*", | ||
"nconf": "*", | ||
"validator": "*", | ||
"jquery":"*", | ||
"request-json":"*" | ||
} | ||
} |
Please register or sign in to comment