Skip to content

(INF-3541) Comanage LDAP Upgrade + Fixes#30

Merged
williamnswanson merged 8 commits intoopensciencegrid:masterfrom
williamnswanson:INF-3541.COmanage-LDAP-Upgrade
Apr 13, 2026
Merged

(INF-3541) Comanage LDAP Upgrade + Fixes#30
williamnswanson merged 8 commits intoopensciencegrid:masterfrom
williamnswanson:INF-3541.COmanage-LDAP-Upgrade

Conversation

@williamnswanson
Copy link
Copy Markdown
Collaborator

Add Paged LDAP search, using a series of fallback servers configured via a config file in service of https://opensciencegrid.atlassian.net/browse/INF-3541

Most effected scripts are the mapfile generator script (osg-comanage-project-usermap.py) and project setup script (project_group_setup.py).

Both seem to have identical (or better results from my testing), the mapfiles the old and new scripts create for AP40 seem to be the same content.

I tested the script against the osgdev instance of the LDAP server, which has the same groups as the prod instance, but the groups have different group IDs, so some of the group ordering was different due to that.

Add Python Requests Library to Dockerfile requirements.txt

Update shebang headers to explicitly use python3.11, since it's not the default version for some places these scripts will need to be run.
Rearrange flags and usage for project_group_setup.py osg-comanage-project-usermap.py to reflect the changes.

Note for reviewer: the definition for the comanage_utils/py get_ldap_groups methods got misplaced during commit cleanup for the PR.
 Remove / comment old default values for LDAP stuff

Whitespace formatting

No functional changes
@williamnswanson williamnswanson self-assigned this Apr 6, 2026
@williamnswanson williamnswanson added enhancement New feature or request do-not-merge labels Apr 6, 2026
Comment thread osg-comanage-project-usermap.py Outdated
Comment thread Dockerfile Outdated
Comment thread comanage_utils.py Outdated
Comment thread comanage_utils.py
Comment thread comanage_utils.py Outdated
@brianhlin
Copy link
Copy Markdown
Member

Are there specific 3.11-isms that we're using here or could this all just work on 3.9? Or how hard would it be to make this all work with 3.9?

@williamnswanson
Copy link
Copy Markdown
Collaborator Author

I think this could work on 3.9, pending replacement of StrEnum for LDAP_CONFIG_KEYS, which I'm doing in the next set of changes.

The main reason for v3.11 was it was the oldest version of python that wasn't going to go EoL this year, but since we only care about Redhat's supportted versions, we can stay behind longer.

@williamnswanson
Copy link
Copy Markdown
Collaborator Author

Works on 3.9 after a few changes, generated mapfile for ap40 looks the same as before.

Copy link
Copy Markdown
Contributor

@mwestphall mwestphall left a comment

Choose a reason for hiding this comment

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

I was able to run the mapfile script on AP40 again following the most recent round of changes, approving.

@williamnswanson williamnswanson merged commit 74dbdae into opensciencegrid:master Apr 13, 2026
2 of 6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

do-not-merge enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants