Skip to content

Instantly share code, notes, and snippets.

@andremsantos
Forked from AkimaLunar/Dockerfile
Created March 19, 2019 15:25
Show Gist options
  • Save andremsantos/6b43435fa5e3c9b56056c1625b0d5f9f to your computer and use it in GitHub Desktop.
Save andremsantos/6b43435fa5e3c9b56056c1625b0d5f9f to your computer and use it in GitHub Desktop.
Node.js 8 and NPM 5 on Ubuntu 16.04 Xenial Dockerfile
# Use an official Ubuntu Xenial as a parent image
FROM ubuntu:16.04
# Install Node.js 8 and npm 5
RUN apt-get update
RUN apt-get -qq update
RUN apt-get install -y build-essential
RUN apt-get install -y curl
RUN curl -sL https://deb.nodesource.com/setup_8.x | bash
RUN apt-get install -y nodejs
# Set the working directory to /app
WORKDIR /app
# Copy the current directory contents into the container
ADD . /app
# Install any needed packages specified in requirements.txt
RUN npm install
# Make port 8080 available outside this container
EXPOSE 8080
# Run `npm start` when the container launches
CMD ["npm", "start"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment