This repository has been archived by the owner on Mar 21, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ADDED: docker file, pipeline, docker compose and docker ignore
- Loading branch information
Showing
9 changed files
with
99 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
node_modules | ||
build | ||
.dockerignore | ||
Dockerfile | ||
Dockerfile.prod |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# pull official base image | ||
FROM node:13.12.0-alpine as build | ||
|
||
# set working directory | ||
WORKDIR /app | ||
|
||
# add `/app/node_modules/.bin` to $PATH | ||
ENV PATH /app/node_modules/.bin:$PATH | ||
|
||
# install app dependencies | ||
COPY package.json ./ | ||
COPY package-lock.json ./ | ||
RUN npm install #--silent | ||
RUN npm install [email protected] -g #--silent | ||
|
||
# add app | ||
COPY . ./ | ||
|
||
# build app | ||
RUN npm run build | ||
|
||
|
||
# production environment | ||
FROM nginx:stable-alpine | ||
COPY --from=build /app/build /usr/share/nginx/html | ||
EXPOSE 80 | ||
CMD ["nginx", "-g", "daemon off;"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
--- | ||
version: "2.1" | ||
services: | ||
book-a-book-buscador: | ||
image: aleixmt/book-a-book-frontend:latest | ||
pull_policy: always | ||
ports: | ||
- "0.0.0.0:80:80" |