U.S. Independence Day Deal! Unlock 25% OFF Today – Limited-Time Offer - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

Linux Foundation CKS Exam - Topic 1 Question 12 Discussion

a. Retrieve the content of the existing secret nameddefault-token-xxxxxin the testing namespace.Store the value of the token in the token.txtb. Create a new secret named test-db-secret in the DB namespace with the following content:username:mysqlpassword:password@123Create the Pod name test-db-pod of image nginx in the namespace db that can access test-db-secret via a volume at path /etc/mysql-credentials
A) Explanation: To add a Kubernetes cluster to your project, group, or instance: Navigate to your: Project'sOperations > Kubernetespage, for a project-level cluster. Group'sKubernetespage, for a group-level cluster. Admin Area >Kubernetespage, for an instance-level cluster. ClickAdd Kubernetes cluster. Click theAdd existing clustertab and fill in the details: Kubernetes cluster name(required) - The name you wish to give the cluster. Environment scope(required) - Theassociated environmentto this cluster. API URL(required) - It's the URL that GitLab uses to access the Kubernetes API. Kubernetes exposes several APIs, we want the ''base'' URL that is common to all of them. For example,https://kubernetes.example.comrather thanhttps://kubernetes.example.com/api/v1. Get the API URL by running this command: kubectl cluster-info | grep -E 'Kubernetes master|Kubernetes control plane' | awk '/http/ {print $NF}' CA certificate(required) - A valid Kubernetes certificate is needed to authenticate to the cluster. We use the certificate created by default. List the secrets withkubectl get secrets, and one should be named similar todefault-token-xxxxx. Copy that token name for use below. Get the certificate by running this command: kubectl get secret <secret name> -o jsonpath='{['data']['ca\.crt']}'

Linux Foundation CKS Exam - Topic 1 Question 12 Discussion

Actual exam question for Linux Foundation's CKS exam
Question #: 12
Topic #: 1
[All CKS Questions]

a. Retrieve the content of the existing secret nameddefault-token-xxxxxin the testing namespace.

Store the value of the token in the token.txt

b. Create a new secret named test-db-secret in the DB namespace with the following content:

username:mysql

password:password@123

Create the Pod name test-db-pod of image nginx in the namespace db that can access test-db-secret via a volume at path /etc/mysql-credentials

Show Suggested Answer Hide Answer
Suggested Answer: A

Contribute your Thoughts:

0/2000 characters
Minna
8 months ago
Don't forget to set the right permissions on the secret volume!
upvoted 0 times
...
Barney
8 months ago
Just make sure to use a more secure password for production!
upvoted 0 times
...
Boris
8 months ago
Wait, is it really safe to use "password@123" for a database?
upvoted 0 times
...
Mabel
8 months ago
Totally agree, that's the way to do it!
upvoted 0 times
...
Chu
8 months ago
You can get the token with `kubectl get secret default-token-xxxx -o jsonpath='{.data.token}' | base64 --decode > token.txt`.
upvoted 0 times
...
Nickole
8 months ago
For the token retrieval, I feel like we might need to specify the namespace with `-n testing`, but I can't recall if that's always necessary.
upvoted 0 times
...
Kimberely
8 months ago
I remember practicing a similar question where we had to create a secret and mount it in a pod. I think we use `kubectl create secret` for that part.
upvoted 0 times
...
Gregg
8 months ago
I think for part a, we need to use `kubectl get secret` to retrieve the token, but I'm not entirely sure about the exact command syntax.
upvoted 0 times
...
Theola
9 months ago
I believe we should also use a volume mount in the pod spec to access the secret, but I'm a bit confused about how to structure that YAML.
upvoted 0 times
...
Iluminada
9 months ago
Okay, I've got a strategy for this. I'll start by identifying the key features of transparent mode, then match that up with the configuration options to find the one that controls multicast traffic.
upvoted 0 times
...
Carmela
9 months ago
The out-of-band control plane seems like the most likely answer here. That would allow for secure management and monitoring of the datacenter infrastructure without exposing it to the main network.
upvoted 0 times
...
Dominque
9 months ago
This is a tricky one. There are a lot of technical details about Oracle Workflow that I'm not super familiar with. I'll just do my best to narrow it down based on what I do know.
upvoted 0 times
...

Save Cancel