Activities Web
Activities Web is a simple React Application running a simple Release Process.
TL;DR
docker pull ghcr.io/pop-cloud/activities-web:latest
docker run --name my-react --rm -p 8080:80 ghcr.io/pop-cloud/activities-web:latest
0. Local Rest API
We can use the json-server to fake a full REST API from a simple data/db.json in less than 30 seconds
{ "activities": { "create": 24, "update": 160, "delete": 16 } }
npm install -g json-server
json-server --watch data/db.json --port 5000
1. Local Dockerizing
docker build . \
-f ops/docker/app.dockerfile \
--build-arg ENV='test' \
--build-arg BUILD="$(date "+%F %H:%M:%S")" \
--build-arg GIT_HASH="$(git rev-parse --short HEAD)" \
-t act-web
docker run -p 8082:80 --name web --network act --rm act-web:latest
2. Remote Dockerizing
Using GitHub Action
- Automatic run for each push on master
- Manual run
3. Docker Registry
Docker Registry ghcr.io/pop-cloud/activities-web
docker pull ghcr.io/pop-cloud/activities-web:latest
docker run --name my-react --rm -p 8080:80 ghcr.io/pop-cloud/activities-web:latest
4. Kubernetes
kubectl run my-react --image ghcr.io/pop-cloud/activities-web:latest
kubectl port-forward my-react 8080:80
5. Helm Chart
helm upgrade -i my-react activities-web --repo https://pop-cloud.github.io/helm-charts