CKA Services & Networking • Complete Question Bank
Complete CKA Services & Networking question bank — all 0 questions with answers and detailed explanations.
Refer to the exhibit. ``` $ kubectl describe svc my-service Name: my-service Namespace: default Labels: <none> Annotations: <none> Selector: app=my-app Type: ClusterIP IP Family Policy: SingleStack IP Families: IPv4 IP: 10.96.100.10 IPs: 10.96.100.10 Port: http 80/TCP TargetPort: 8080/TCP Endpoints: <none> ```
Refer to the exhibit.
```
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: deny-all
namespace: default
spec:
podSelector: {}
policyTypes:
- Ingress
- Egress
```A Kubernetes cluster uses a NetworkPolicy to restrict traffic to a set of pods labeled 'app: db'. Which TWO statements about the following NetworkPolicy are correct?
apiVersion: networking.k8s.io/v1 kind: NetworkPolicy metadata: name: db-policy spec: podSelector: matchLabels: app: db policyTypes: - Ingress ingress: - from: - podSelector: matchLabels: app: api ports: - port: 5432
Refer to the exhibit.
$ kubectl get svc my-service -o yaml
apiVersion: v1
kind: Service
metadata:
name: my-service
spec:
clusterIP: 10.96.0.1
ports:
- name: http
port: 80
protocol: TCP
targetPort: 8080
selector:
app: my-app
type: ClusterIP
status:
loadBalancer: {}
$ kubectl get endpoints my-service
NAME ENDPOINTS AGE
my-service 192.168.1.10:8080 5mDrag steps to the numbered slots on the right, or tap a step then tap a slot.
Drag steps to the numbered slots on the right, or tap a step then tap a slot.
Drag a concept onto its matching description — or click a concept then click the description.
Controls incoming traffic to Pods
Controls outgoing traffic from Pods
Selects Pods to which the policy applies
Specifies whether rules apply to Ingress, Egress, or both
Isolates all Pods in a namespace by default
Drag a concept onto its matching description — or click a concept then click the description.
Request for storage by a user
Describes storage provisioner and parameters
Mounts a file or directory from the host Node
Temporary storage that shares a Pod's lifecycle
Standard interface for storage plugins