Skip to content

webmakaka/MERN-Stack-Front-To-Back-v2.0

Repository files navigation

[Brad Traversy] MERN Stack Front To Back: Full Stack React, Redux & Node.js [ENG, 2019]

Original src:
https://github.com/bradtraversy/devconnector_2.0


Project UI:


Application


Application


Application


How to run the final app with docker-compose

$ docker-compose up --build

localhost:3000


How to run the final app with minikube (Possible not works after latest updates, but who care?)

Minikube, Kubectl, Docker, Skaffold should be installed.


Run app in minikube

$ {
    minikube --profile my-profile config set memory 8192
    minikube --profile my-profile config set cpus 4

    // minikube --profile my-profile config set vm-driver virtualbox
    minikube --profile my-profile config set vm-driver docker

    minikube --profile my-profile config set kubernetes-version v1.18.2
    minikube start --profile my-profile
}

// Enable ingress
$ minikube addons --profile my-profile enable ingress

$ minikube --profile my-profile ip
172.17.0.2

$ sudo vi /etc/hosts
#---------------------------------------------------------------------
# Minikube
#---------------------------------------------------------------------
172.17.0.2 mern-stack-front-to-back-v2.dev

$ kubectl create secret generic jwt-secret --from-literal=JWT_KEY=MY_JWT_SECRET

Run App in "Production mode"

$ kubectl apply -f ./k8s
// $ kubectl delete -f ./k8s/

Run App in development mode with Skaffold


Skaffold installation

$ curl -Lo skaffold https://storage.googleapis.com/skaffold/releases/latest/skaffold-linux-amd64

$ chmod +x skaffold
$ sudo mv skaffold /usr/local/bin

$ cd skaffold

$ docker login

Need update webmakaka/mern-stack-front-to-back-v2*** on your data in scripts

$ skaffold dev

Result

$ kubectl get pods
NAME                                                            READY   STATUS    RESTARTS   AGE
mern-stack-front-to-back-v2-api-deployment-6f76df5df8-2cbpk     1/1     Running   0          13m
mern-stack-front-to-back-v2-client-deployment-5dc54d6c6-7x9cc   1/1     Running   0          13m

chrome browser --> https://mern-stack-front-to-back-v2.dev/


type: thisisunsafe in the window with security warning.


Delete minikube with project

$ minikube --profile my-profile stop && minikube --profile my-profile delete







Marley

Any questions in english: Telegram Chat
Любые вопросы на русском: Телеграм чат

About

[Brad Traversy] MERN Stack Front To Back: Full Stack React, Redux & Node.js [ENG, 2019]

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages