// Module included in the following assemblies: // // * builds/creating-build-inputs.adoc [id="builds-source-secret-basic-auth_{context}"] = Creating a secret from source code basic authentication Basic authentication requires either a combination of `--username` and `--password`, or a `token` to authenticate against the SCM server. .Prerequisites * User name and password to access the private repository. .Procedure . Create the `secret` first before using the user name and password to access the private repository: + [source,terminal] ---- $ oc create secret generic \ --from-literal=username= \ --from-literal=password= \ --type=kubernetes.io/basic-auth ---- + . Create a basic authentication secret with a token: + [source,terminal] ---- $ oc create secret generic \ --from-literal=password= \ --type=kubernetes.io/basic-auth ----