diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..63109ba --- /dev/null +++ b/Dockerfile @@ -0,0 +1,17 @@ +FROM node:18.6.0-buster-slim + +ENV NODE_ENV=production + +COPY package.json package-lock.json ./ +RUN npm ci && mkdir /angular && mv ./node_modules ./angular + +WORKDIR /angular +RUN npm install -g @angular/cli + +COPY . . +ADD okteto-stack.yaml okteto-stack.yaml +COPY . . + +EXPOSE 32333 + +CMD ["bash", "run.sh"] \ No newline at end of file diff --git a/Procfile b/Procfile new file mode 100644 index 0000000..f4f5dfe --- /dev/null +++ b/Procfile @@ -0,0 +1,2 @@ +heroku ps:scale web=1 +web: bash run.sh \ No newline at end of file diff --git a/heroku.yml b/heroku.yml new file mode 100644 index 0000000..9e276a3 --- /dev/null +++ b/heroku.yml @@ -0,0 +1,5 @@ +build: + docker: + web: Dockerfile +run: + web: bash run.sh \ No newline at end of file diff --git a/okteto-stack.yaml b/okteto-stack.yaml new file mode 100644 index 0000000..35718d2 --- /dev/null +++ b/okteto-stack.yaml @@ -0,0 +1,15 @@ +services: + bifm-bypass: + public: true + build: . + environment: + NODE_ENV: production + ports: + - 32333 + resources: + requests: + cpu: 500m + memory: 1000Mi + limits: + cpu: 1000m + memory: 2000Mi \ No newline at end of file diff --git a/run.sh b/run.sh new file mode 100644 index 0000000..3a48ac0 --- /dev/null +++ b/run.sh @@ -0,0 +1 @@ +npm i & npm start \ No newline at end of file