Which command creates a new service account named myserviceaccount?

Prepare for the Red Hat OpenShift Developer II DO288 Exam with our quizzes. Study with flashcards and multiple choice questions, each with hints and explanations. Get ready for your certification!

Multiple Choice

Which command creates a new service account named myserviceaccount?

Explanation:
Creating a service account in OpenShift is done with the command that uses the resource type serviceaccount. The canonical form is oc create serviceaccount <name>. This tells OpenShift to instantiate a new ServiceAccount object in the current project/namespace, which pods can use to authenticate to the API server. The other patterns don’t match the valid resource type or syntax OpenShift expects, so they aren’t recognized as commands to create a service account. If you want, you can qualify the namespace with -n or switch projects first, for example oc create serviceaccount myserviceaccount -n myproject.

Creating a service account in OpenShift is done with the command that uses the resource type serviceaccount. The canonical form is oc create serviceaccount . This tells OpenShift to instantiate a new ServiceAccount object in the current project/namespace, which pods can use to authenticate to the API server. The other patterns don’t match the valid resource type or syntax OpenShift expects, so they aren’t recognized as commands to create a service account. If you want, you can qualify the namespace with -n or switch projects first, for example oc create serviceaccount myserviceaccount -n myproject.

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy