mirror of
https://github.com/openshift/openshift-docs.git
synced 2026-02-05 12:46:18 +01:00
44 lines
1.0 KiB
Plaintext
44 lines
1.0 KiB
Plaintext
// Module included in the following assemblies:
|
|
//
|
|
// * list assemblies
|
|
|
|
:_mod-docs-content-type: PROCEDURE
|
|
[id="loki-create-object-storage-secret-cli_{context}"]
|
|
= Creating a secret for Loki object storage by using the CLI
|
|
|
|
To configure Loki object storage, you must create a secret. You can do this by using the {oc-first}.
|
|
|
|
.Prerequisites
|
|
|
|
* You have administrator permissions.
|
|
* You installed the {loki-op}.
|
|
* You installed the {oc-first}.
|
|
|
|
.Procedure
|
|
|
|
* Create a secret in the directory that contains your certificate and key files by running the following command:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc create secret generic -n openshift-logging <your_secret_name> \
|
|
--from-file=tls.key=<your_key_file>
|
|
--from-file=tls.crt=<your_crt_file>
|
|
--from-file=ca-bundle.crt=<your_bundle_file>
|
|
--from-literal=username=<your_username>
|
|
--from-literal=password=<your_password>
|
|
----
|
|
|
|
[NOTE]
|
|
====
|
|
Use generic or opaque secrets for best results.
|
|
====
|
|
|
|
.Verification
|
|
|
|
* Verify that a secret was created by running the following command:
|
|
+
|
|
[source,terminal]
|
|
----
|
|
$ oc get secrets
|
|
----
|