Test simplified Dockerfile, removed internal build
This commit is contained in:
		
							
								
								
									
										38
									
								
								Dockerfile
									
									
									
									
									
								
							
							
						
						
									
										38
									
								
								Dockerfile
									
									
									
									
									
								
							| @@ -1,31 +1,27 @@ | ||||
| FROM node:18-alpine3.15 | ||||
| FROM nginx:1.23.1 | ||||
| LABEL org.opencontainers.image.source https://github.com/kevinmidboe/seasoned | ||||
|  | ||||
| RUN apk update && apk add curl && apk add nginx && apk add openrc | ||||
| # RUN mkdir -p /opt/seasoned | ||||
| # WORKDIR /opt/seasoned | ||||
|  | ||||
| RUN mkdir -p /opt/seasoned/node_modules | ||||
| WORKDIR /opt/seasoned | ||||
| # COPY src /opt/seasoned/src | ||||
| # COPY public /opt/seasoned/public | ||||
| COPY public /usr/share/nginx/html | ||||
| # COPY yarn.lock /opt/seasoned | ||||
| # COPY package.json /opt/seasoned | ||||
| # COPY server.ts /opt/seasoned | ||||
| # COPY webpack.config.js /opt/seasoned | ||||
| COPY nginx.conf /etc/nginx/conf.d/default.conf | ||||
| # COPY tsconfig**.json /opt/seasoned/ | ||||
|  | ||||
| COPY src /opt/seasoned/src | ||||
| COPY public /opt/seasoned/public | ||||
| COPY yarn.lock /opt/seasoned | ||||
| COPY package.json /opt/seasoned | ||||
| COPY server.ts /opt/seasoned | ||||
| COPY webpack.config.js /opt/seasoned | ||||
| COPY nginx.conf /etc/nginx/http.d/default.conf | ||||
| COPY tsconfig**.json /opt/seasoned/ | ||||
| # RUN chown -R node:node /opt/seasoned | ||||
|  | ||||
| RUN chown -R node:node /opt/seasoned | ||||
| # USER node | ||||
|  | ||||
| USER node | ||||
| # RUN yarn install | ||||
|  | ||||
| RUN yarn install | ||||
|  | ||||
| RUN yarn build | ||||
|  | ||||
| RUN rc-update add nginx | ||||
| RUN rc-service nginx start | ||||
| # RUN yarn build | ||||
|  | ||||
| EXPOSE 5000 | ||||
|  | ||||
| CMD ["yarn", "start"] | ||||
| # CMD ["yarn", "start"] | ||||
|   | ||||
| @@ -3,7 +3,7 @@ server { | ||||
|   listen [::]:5000 default_server; | ||||
|  | ||||
| #  server_name request.movie; | ||||
|   root /opt/seasoned/public; | ||||
|   root /usr/share/nginx/html; | ||||
|  | ||||
|   gzip on; | ||||
|   gzip_types application/javascript; | ||||
| @@ -20,7 +20,7 @@ server { | ||||
|   } | ||||
|  | ||||
|   location /api { | ||||
|     proxy_pass https://request.movie/api; | ||||
|     proxy_pass http://request.movie; | ||||
|   } | ||||
|  | ||||
|   location / { | ||||
|   | ||||
		Reference in New Issue
	
	Block a user