Last active
April 4, 2021 11:25
-
-
Save gowatana/c28df7eb6d4219aa95ec922a8d222f05 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
kind: Service | |
apiVersion: v1 | |
metadata: | |
name: svc-web | |
spec: | |
type: LoadBalancer | |
selector: | |
app: httpd | |
ports: | |
- port: 80 | |
protocol: TCP | |
targetPort: 80 | |
--- | |
kind: Deployment | |
apiVersion: apps/v1 | |
metadata: | |
name: web | |
spec: | |
replicas: 1 | |
selector: | |
matchLabels: | |
app: httpd | |
template: | |
metadata: | |
labels: | |
app: httpd | |
spec: | |
containers: | |
- name: httpd | |
image: gowatana/centos7:httpd | |
ports: | |
- containerPort: 80 | |
protocol: TCP | |
command: | |
- bash | |
- -c | |
- | | |
N=$(uname -n) | |
HTML=/var/www/html/index.html | |
echo '<h1>httpd on <font color=orange>NSX-ALB(Avi)</font></h1>' > $HTML | |
echo 'Pod: ' $N >> $HTML | |
httpd -D FOREGROUND |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
下記の投稿むけ。
vSphere with Tanzu NSX-ALB(Avi)版ラボ環境構築。Part-05 Tanzu Kubernetes クラスタの作成
https://vm.gowatana.jp/entry/2021/04/04/201906