Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: fixed cli admin dashboard cmd #16430

Merged
merged 2 commits into from
Nov 27, 2023

Conversation

gdsoumya
Copy link
Member

@gdsoumya gdsoumya commented Nov 22, 2023

Fixes #16379
Fixes #16323

Logs:

go run cmd/main.go admin dashboard -n argocd --address=127.0.0.2 --port 8888

Argo CD UI is available at http://127.0.0.2:8888

Issues resolved :

  1. Argocd server is able to start up when using argocd admin dashboard cmd
  2. The dashboard cmd is now able to parse both argocd specific flags like --address, --port etc. and also k8s flags like -n

Checklist:

  • Either (a) I've created an enhancement proposal and discussed it with the community, (b) this is a bug fix, or (c) this does not need to be in the release notes.
  • The title of the PR states what changed and the related issues number (used for the release note).
  • The title of the PR conforms to the Toolchain Guide
  • I've included "Closes [ISSUE #]" or "Fixes [ISSUE #]" in the description to automatically close the associated issue.
  • I've updated both the CLI and UI to expose my feature, or I plan to submit a second PR with them.
  • Does this PR require documentation updates?
  • I've updated documentation as required by this PR.
  • Optional. My organization is added to USERS.md.
  • I have signed off all my commits as required by DCO
  • I have written unit and/or e2e tests for my change. PRs without these are unlikely to be merged.
  • My build is green (troubleshooting builds).
  • My new feature complies with the feature status guidelines.
  • I have added a brief description of why this PR is necessary and/or what this PR solves.

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>
@gdsoumya gdsoumya requested a review from a team as a code owner November 22, 2023 20:37
Copy link

codecov bot commented Nov 22, 2023

Codecov Report

Attention: 6 lines in your changes are missing coverage. Please review.

Comparison is base (1600c03) 49.53% compared to head (3c97a6a) 49.53%.

Files Patch % Lines
cmd/argocd/commands/admin/dashboard.go 0.00% 5 Missing ⚠️
cmd/argocd/commands/admin/admin.go 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master   #16430      +/-   ##
==========================================
- Coverage   49.53%   49.53%   -0.01%     
==========================================
  Files         269      269              
  Lines       47222    47224       +2     
==========================================
  Hits        23392    23392              
- Misses      21530    21532       +2     
  Partials     2300     2300              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@ishitasequeira ishitasequeira left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@gdsoumya , the generated code seems to be a mismatch. Can you take a look?

@@ -42,7 +46,7 @@ $ argocd admin dashboard --port 8080 --address 127.0.0.1
$ argocd admin dashboard --redis-compress gzip
`,
}
initialize.InitCommand(cmd)
clientConfig = cli.AddKubectlFlagsToSet(cmd.Flags())
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without passing the clientConfig directly from the cmd I was not able to use kubectl like flags to configure the cliebntConfig for eg. -n/--namespace was not working before this change. A similar issue was noticed by another user

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>
@gdsoumya gdsoumya requested a review from a team as a code owner November 23, 2023 06:06
@gdsoumya
Copy link
Member Author

@ishitasequeira updated docs

Copy link
Collaborator

@alexmt alexmt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome! Thank you @gdsoumya !

@alexmt
Copy link
Collaborator

alexmt commented Nov 26, 2023

Double-checked that most recent v2.8 is not affected, so cherry-picking only into 2.9

@alexmt alexmt enabled auto-merge (squash) November 26, 2023 21:14
@alexmt alexmt merged commit 2f2958a into argoproj:master Nov 27, 2023
27 checks passed
@alexmt
Copy link
Collaborator

alexmt commented Nov 27, 2023

/cherry-pick release-2.9

Copy link

Cherry-pick failed with Merge error 2f2958a0f42068552de67370caccb84522267c65 into temp-cherry-pick-ea997a-release-2.9

alexmt pushed a commit to alexmt/argo-cd that referenced this pull request Nov 27, 2023
* fix: fixed cli admin dashboard cmd

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>

* feat: update docs

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>

---------

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>
alexmt added a commit that referenced this pull request Nov 27, 2023
* chore(cli): clarify core mode code (#15800)

* chore(cli): clarify core mode code

Signed-off-by: Michael Crenshaw <[email protected]>

* rename function

Signed-off-by: Michael Crenshaw <[email protected]>

---------

Signed-off-by: Michael Crenshaw <[email protected]>

* fix: fixed cli admin dashboard cmd (#16430)

* fix: fixed cli admin dashboard cmd

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>

* feat: update docs

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>

---------

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>

* chore(ui): Change testEnvironment from node to jsdom (#16287)

Signed-off-by: Rafal Pelczar <[email protected]>

---------

Signed-off-by: Michael Crenshaw <[email protected]>
Signed-off-by: Soumya Ghosh Dastidar <[email protected]>
Signed-off-by: Rafal Pelczar <[email protected]>
Co-authored-by: Michael Crenshaw <[email protected]>
Co-authored-by: Soumya Ghosh Dastidar <[email protected]>
Co-authored-by: Rafal <[email protected]>
vladfr pushed a commit to vladfr/argo-cd that referenced this pull request Dec 13, 2023
* fix: fixed cli admin dashboard cmd

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>

* feat: update docs

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>

---------

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>
tesla59 pushed a commit to tesla59/argo-cd that referenced this pull request Dec 16, 2023
* fix: fixed cli admin dashboard cmd

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>

* feat: update docs

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>

---------

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>
lyda pushed a commit to lyda/argo-cd that referenced this pull request Mar 28, 2024
* fix: fixed cli admin dashboard cmd

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>

* feat: update docs

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>

---------

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>
Signed-off-by: Kevin Lyda <[email protected]>
Hariharasuthan99 pushed a commit to AmadeusITGroup/argo-cd that referenced this pull request Jun 16, 2024
* fix: fixed cli admin dashboard cmd

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>

* feat: update docs

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>

---------

Signed-off-by: Soumya Ghosh Dastidar <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants