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

GEOSERVER admin password seems not be updated #39

Open
randomorder opened this issue May 2, 2022 · 4 comments
Open

GEOSERVER admin password seems not be updated #39

randomorder opened this issue May 2, 2022 · 4 comments
Assignees

Comments

@randomorder
Copy link
Member

randomorder commented May 2, 2022

Internal clone issue for the sibling in the official GeoNode fork GeoNode#209

I'll summarize here our findings and the way forward

In geonode-project we have two envionment variables in the .env that defint the username and password of the administrator user in GeoServer. There is a logic in geonode that should allow the user to override the geoserver administrator password based on the value of GEOSERVER_ADMIN_PASSWORD in the .env file but apparently is not working as expected.

What we observe is that it only works in a very specific use case, i.e. the current password is set to the default geoserver and has not been changed yet. If the current password is anything but geoserver the REST request sent to geoserver to change the password does not work (all REST calls to geoserver require authentication).

Our current understanding is that this logic (implemented in entrypoint -> geoserverfixture -> _geoserver_info_provision) is concaptually wrong because is trying to set the new password based on the content of the .env file but in order to do that it needs to know what the old password is and that is not tracked in the .env file

The goal of this task it to validate the above and create a PR to remove the fixture which is conceptually wrong

@jkariscodes
Copy link

I tried the removal of the geoserverfixture and its invocation as suggested and then recreated containers with new custom geoserver password the GeoServer still does not pick up the password from .env variable and still uses geoserver as the default password. I am further investigating a workaround to this.

@randomorder
Copy link
Member Author

Hi @jkariukidev

...still does not pick up the password from .env variable...

That is expected.

Have you locally validated our idea that (prior to the fixtire removal) the password was only changed the very first time and not from then onwards?

If so you can send a merge request to remove the fixture

@jkariscodes
Copy link

jkariscodes commented May 5, 2022

I have locally validated the idea. Pull request is here

@giohappy
Copy link

giohappy commented May 9, 2022

@jkariukidev regarding the PRs, please follow the checks inside the template that is presented when you create a new PR.
Main points:

  • an issue must exist and must be connected to the PR:
    • write "ref #xxxx" inside the description
    • connect the issue through Zenhub (I will tell you more later)
  • the title must be in the form "[Fixes #xxxx] <title of the issue>"
  • when the PR is ready for a review assign it to someone in the time. For the moment you can assign it to me (giohappy) or Alessandro (randomorder)

Please do the above steps, thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants