이 콘텐츠는 선택한 언어로 제공되지 않습니다.
Chapter 2. Logging in to the Argo CD server in the default mode
You can log in to the Argo CD server in the default mode using the GitOps argocd CLI and your Argo CD credentials to execute commands.
2.1. Logging in to the Argo CD server 링크 복사링크가 클립보드에 복사되었습니다!
After you install and configure the GitOps argocd CLI, you must log in to the Argo CD server to execute commands in the default mode.
Prerequisites
-
You must have the GitOps
argocdCLI tool installed and configured.
Procedure
Get the
adminaccount password for the Argo CD server:$ ADMIN_PASSWD=$(oc get secret openshift-gitops-cluster -n openshift-gitops -o jsonpath='{.data.admin\.password}' | base64 -d)Get the Argo CD server URL:
$ SERVER_URL=$(oc get routes openshift-gitops-server -n openshift-gitops -o jsonpath='{.status.ingress[0].host}')Log in to the Argo CD server by using the
adminaccount password and enclosing it in single quotes:ImportantEnclosing the password in single quotes ensures that special characters, such as
$, are not misinterpreted by the shell. Always use single quotes to enclose the literal value of the password.$ argocd login --username admin --password ${ADMIN_PASSWD} ${SERVER_URL}Example:
$ argocd login --username admin --password '<password>' openshift-gitops.openshift-gitops.apps-crc.testingAfter a successful login, the session context will be displayed as follows:
Example output:
'admin:login' logged in successfully Context '<server_url>' updatedImportantIf the login session times out, you can use the
relogincommand to log in again. When done using theargocdcommands, you can log out using thelogoutcommand.