背景
我在自己的 K8S 集群中已部署 demo:
这几天大家都在讨论 React Server Components,挺热闹的😂。
它是什么,有啥用,具体大家可以看掘友的这篇文章。
- React RFC Server Components 是什么,有啥用
知乎也挺热闹的:
- 如何看待 React Server Components?
为少始终认为,不管啥技术最终都是要落地业务的。
那还等什么呢?开撸~
改造官方 Demo
官方 Demo:https://github.com/reactjs/server-components-demo
编写基本的 .drone.yml
kind: pipeline type: kubernetes name: ServerComponentsDemo steps: - name: 更新 Chart.yaml appVersion image: busybox commands: - echo $DRONE_COMMIT - '[ -n "$DRONE_COMMIT" ] && ( sed -i "s/APP_VERSION/${DRONE_COMMIT}/g" k8s-devops/helm-react-notes/react-notes/Chart.yaml; )' - cat k8s-devops/helm-react-notes/react-notes/Chart.yaml - name: 构建 Docker Image image: plugins/docker settings: debug: true dockerfile: Dockerfile.prod repo: hub.domain.com/library/react-notes tags: ${DRONE_COMMIT} registry: hub.domain.com username: from_secret: docker_user password: from_secret: docker_pass - name: 上云(HelmV3) -> K8S Cluster image: pelotech/drone-helm3 settings: helm_command: upgrade chart: ./k8s-devops/helm-react-notes/react-notes release: react-notes vaules_yaml: ./k8s-devops/helm-react-notes/values.yaml namespace: react-notes api_server: from_secret: api_server kubernetes_token: from_secret: k8s_token skip_tls_verify: true trigger: branch: - main
Happy Helming!拥抱🤗云原生!!!