diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 00000000..0520c167 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,82 @@ +# Created by https://www.gitignore.io/api/node + +### Node ### +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* + +# Runtime data +pids +*.pid +*.seed +*.pid.lock + +#Ignore the git folder +.git + +# Directory for instrumented libs generated by jscoverage/JSCover +lib-cov + +# Coverage directory used by tools like istanbul +coverage + +# nyc test coverage +.nyc_output + +# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files) +.grunt + +# Bower dependency directory (https://bower.io/) +bower_components + +# node-waf configuration +.lock-wscript + +# Compiled binary addons (https://nodejs.org/api/addons.html) +build/Release + +# Dependency directories +node_modules/ +jspm_packages/ + +# TypeScript v1 declaration files +typings/ + +# Optional npm cache directory +.npm + +# Optional eslint cache +.eslintcache + +# Optional REPL history +.node_repl_history + +# Output of 'npm pack' +*.tgz + +# Yarn Integrity file +.yarn-integrity + +# dotenv environment variables file +# .env + +# parcel-bundler cache (https://parceljs.org/) +.cache + +# next.js build output +.next + +# nuxt.js build output +.nuxt + +# vuepress build output +.vuepress/dist + +# Serverless directories +.serverless + + +# End of https://www.gitignore.io/api/node \ No newline at end of file diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 00000000..d8ac9e39 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,14 @@ +FROM node:alpine + +WORKDIR /app + +RUN apk add --no-cache git + +COPY package.json /app +RUN npm install +COPY . /app + +CMD npm run docker:serve + +#Node Application Port +EXPOSE 8080 \ No newline at end of file diff --git a/package.json b/package.json index 9942fbac..351bf5dc 100644 --- a/package.json +++ b/package.json @@ -6,6 +6,7 @@ "license": "MIT", "scripts": { "dev": "vue-cli-service serve", + "docker:serve": "vue-cli-service serve --port 8080", "build:prod": "vue-cli-service build", "build:stage": "vue-cli-service build --mode staging", "preview": "node build/index.js --preview", diff --git a/vue.config.js b/vue.config.js index 7b8f3a5d..6396e4a3 100644 --- a/vue.config.js +++ b/vue.config.js @@ -32,6 +32,7 @@ module.exports = { devServer: { port: port, open: true, + disableHostCheck: true, overlay: { warnings: false, errors: true