Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ~ 🞂🞂 minishift status
- Minishift: Running
- Profile: minishift
- OpenShift: Running (openshift v3.11.0+bd0bee4-337)
- DiskUsage: 19% of 19G (Mounted On: /mnt/sda1)
- CacheUsage: 1.682 GB (used by oc binary, ISO or cached images)
- ~ 🞂🞂 oc version
- oc v3.11.0+0cbc58b
- kubernetes v1.11.0+d4cacc0
- features: Basic-Auth GSSAPI Kerberos SPNEGO
- Server https://192.168.99.100:8443
- kubernetes v1.11.0+d4cacc0
- ~ 🞂🞂 oc whoami
- system:admin
- ~ 🞂🞂 oc label node localhost machinespec=high
- node/localhost labeled
- ~ 🞂🞂 oc get nodes --show-labels
- NAME STATUS ROLES AGE VERSION LABELS
- localhost Ready <none> 21m v1.11.0+d4cacc0 beta.kubernetes.io/arch=amd64,beta.kubernetes.io/os=linux,kubernetes.io/hostname=localhost,machinespec=high
- ~ 🞂🞂 cat /tmp/nginx.yaml
- apiVersion: apps/v1
- kind: Deployment
- metadata:
- labels:
- run: nginx
- name: nginx-deploy
- spec:
- replicas: 1
- selector:
- matchLabels:
- run: nginx
- template:
- metadata:
- labels:
- run: nginx
- spec:
- containers:
- - image: twalter/openshift-nginx
- name: nginx
- nodeSelector:
- machinespec: high
- ~ 🞂🞂 oc create -f /tmp/nginx.yaml
- deployment.apps/nginx-deploy created
- ~ 🞂🞂 oc get pod
- NAME READY STATUS RESTARTS AGE
- pod/nginx-deploy-c96c64d6-ld8fs 1/1 Running 0 25s
- ~ 🞂🞂 oc delete -f /tmp/nginx.yaml
- deployment.apps "nginx-deploy" deleted
- ~ 🞂🞂 oc label node localhost machinespec-
- node/localhost labeled
- ~ 🞂🞂 oc get nodes --show-labels
- NAME STATUS ROLES AGE VERSION LABELS
- localhost Ready <none> 27m v1.11.0+d4cacc0 beta.kubernetes.io/arch=amd64,beta.kubernetes.io/os=linux,kubernetes.io/hostname=localhost
- ~ 🞂🞂 oc create -f /tmp/nginx.yaml
- deployment.apps/nginx-deploy created
- ~ 🞂🞂 oc get pod
- NAME READY STATUS RESTARTS AGE
- nginx-deploy-c96c64d6-wm7pr 0/1 Pending 0 28s
- ~ 🞂🞂 oc describe pod nginx-deploy-c96c64d6-wm7pr | tail -1
- Warning FailedScheduling 8s (x21 over 3m) default-scheduler 0/1 nodes are available: 1 node(s) didn't match node selector.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement