NAME READY STATUS RESTARTS AGE pod/cakephp-mysql-example-1-build 0/1 Completed 04m pod/cakephp-mysql-example-1-gz65l 1/1 Running 01m pod/mysql-1-nkhqn 1/1 Running 04m
NAME DESIRED CURRENT READY AGE replicationcontroller/cakephp-mysql-example-11111m replicationcontroller/mysql-11114m
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE service/cakephp-mysql-example ClusterIP 172.30.234.135 <none> 8080/TCP 4m service/mysql ClusterIP 172.30.13.195 <none> 3306/TCP 4m
NAME REVISION DESIRED CURRENT TRIGGERED BY deploymentconfig.apps.openshift.io/cakephp-mysql-example 111 config,image(cakephp-mysql-example:latest) deploymentconfig.apps.openshift.io/mysql 111 config,image(mysql:5.7)
NAME TYPE FROM LATEST buildconfig.build.openshift.io/cakephp-mysql-example Source Git 1
NAME TYPE FROM STATUS STARTED DURATION build.build.openshift.io/cakephp-mysql-example-1 Source Git@47a951e Complete 4 minutes ago 2m27s
NAME DOCKER REPO TAGS UPDATED imagestream.image.openshift.io/cakephp-mysql-example docker-registry.default.svc:5000/example/cakephp-mysql-example latest About aminute ago
NAME HOST/PORT PATH SERVICES PORT TERMINATION WILDCARD route.route.openshift.io/cakephp-mysql-example cakephp-mysql-example-example.2886795271-80-rhsummit1.environments.katacoda.com cakephp-mysql-example <all> None
这样做的好处是你可以删除 Pod,观察复制控制器如何重新创建它们,缩放 Pod 等等。你可以使用模板并将其更改为其他应用程序(这是我第一次启动时所做的)。
4、Visual Studio Code
我把我最喜欢的放在最后。我的大部分工作都使用 vi,但我从来没有为 Kubernetes 找到一个好的语法高亮器和代码补完插件(如果有的话,请告诉我)。相反,我发现微软的 VS Code 有一套杀手级的插件,可以完成 Kubernetes 资源的创建并提供样板。