Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Add docs for printing the generated admin.password #116
base: main
Are you sure you want to change the base?
Add docs for printing the generated admin.password #116
Changes from 1 commit
bac65b5
4934ca3
058e62f
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
any reason that the previous command is not combined with this one? I don't have a test environment handy, but I'm imagining something like:
docker container exec -it $(docker ps --filter "ancestor=sonatype/nexus3" | awk '{print $1}') cat /nexus-data/admin.password && echo
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@wwannemacher The main reason is if a user is running multiple containers based on the same image. But I do not mind combining the commands :)
The goal is for users to get this generated password easily.
What would be perfect: Allow users to supply a param with the
docker run
command like:docker run <> -e SHOW_ADMIN_PASSWORD=true
(naming things is hard), and the container would print the admin password in the logs. Is that something I can contribute and you think would be beneficial ?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@wwannemacher Seems reasonable. Unlikely that folks have more than one running I would assume. Though note the default output has the column headers so I suggest to use
-q
to just get the container id. Another suggestion is to just use the container name.docker container exec -it $(docker ps -q --filter "name=nexus3") cat /nexus-data/admin.password && echo
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ahmed-musallam - this is something that should happen at the operational level, not the application level. What you have here is good. Thanks for the contribution!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ahmed-musallam FWIW, I'm totally stealing your approach for printing the generated admin password and adding it to the NXRM format archetype docs. Nice!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@collinpeters and @wwannemacher updated to use the suggested command, changed name to "nexus" though; because that's the name you use at the top of this doc.