diff --git a/dockerfile b/dockerfile index 4cbceaf..13981ce 100644 --- a/dockerfile +++ b/dockerfile @@ -1,5 +1,5 @@ # build environment -FROM node:12 as builder +FROM node:12-slim as builder WORKDIR /app COPY package*.json ./ @@ -9,7 +9,7 @@ COPY . ./ RUN npm run build # production environment -FROM node:12 +FROM node:12-slim RUN printf '\n\n- Copy application files\n' ARG APP_SUBFOLDER=network-resurrector diff --git a/private/Notes.txt b/private/Notes.txt index 58cc366..72db9b2 100644 --- a/private/Notes.txt +++ b/private/Notes.txt @@ -1,3 +1,15 @@ +####################################################################################################################################################### +Azure DevOps Repository Password: nih65lpohjpmyru3sarcsg62rc26nknsksi7fqo7bas37ssqhpna +####################################################################################################################################################### + +*********** +** INFO: ** +*********** + In gridul de retea, pe fiecare linie va fi un buton care va deschide un log. Log-ul va fi popup iar continutul lui poate fi ultima componenta de aici https://material-ui.com/components/app-bar/ -************************************************************************************************************************** \ No newline at end of file +************************************************************************************************************************** + +https://medium.com/@tacomanator/environments-with-create-react-app-7b645312c09d +https://create-react-app.dev/docs/adding-custom-environment-variables/ +https://stackoverflow.com/questions/55690143/what-is-the-difference-between-env-local-and-env-development-local \ No newline at end of file diff --git a/private/docker-notes.txt b/private/docker-notes.txt index c0ae62c..e141c27 100644 --- a/private/docker-notes.txt +++ b/private/docker-notes.txt @@ -1 +1,37 @@ -#test \ No newline at end of file +####################################################################################################################################################### +Docker commands: +***************** + +Create image: +--from solution folder: +docker image build -t "network-resurrector-frontend:1.0.0" . + +Run image: +docker run -p 5053:80 -it network-resurrector-frontend:1.0.0 + +Push image to registry: +--tag image +docker tag network-resurrector-frontend:1.0.0 cloud.canister.io:5000/tstanciu/network-resurrector:frontend-1.0.0 + +--login to registry +docker login --username=tstanciu --password="***REMOVED***" cloud.canister.io:5000 + +--push image +docker push cloud.canister.io:5000/tstanciu/network-resurrector:frontend-1.0.0 + +Pull image from registry +--login to registry with readonly rights +docker login --username=deploy+tstanciu --password=***REMOVED*** cloud.canister.io:5000 + +--pull image +docker pull cloud.canister.io:5000/tstanciu/network-resurrector:frontend-1.0.0 + +Run container in prod env +docker run --restart=always -p 5009:80 -d cloud.canister.io:5000/tstanciu/network-resurrector:frontend-1.0.0 + +Rename container +docker rename network-resurrector-frontend +####################################################################################################################################################### + +Docker container last version: 1.0.0 +####################################################################################################################################################### \ No newline at end of file