This just adds a simple voting app for the demo script. It leverages a Node.js Express app for the frontend and a MongoDB database for the backend. It conditionally provisions and attaches to an AWS Elastic Block Store volume in the event that it's targeting an AWS cluster, and ephemeral storage otherwise.
16 lines
241 B
Docker
16 lines
241 B
Docker
FROM node:argon
|
|
|
|
# Create app directory
|
|
RUN mkdir -p /usr/src/app
|
|
WORKDIR /usr/src/app
|
|
|
|
# Install app dependencies
|
|
COPY package.json /usr/src/app/
|
|
RUN npm install
|
|
|
|
# Bundle app source
|
|
COPY . /usr/src/app
|
|
|
|
EXPOSE 8080
|
|
CMD [ "npm", "start" ]
|
|
|