Skip to content

Add --user-account option#20

Merged
ajGingrich merged 7 commits intoRedislabs-Solution-Architects:mainfrom
frivoire:user-account
Aug 21, 2025
Merged

Add --user-account option#20
ajGingrich merged 7 commits intoRedislabs-Solution-Architects:mainfrom
frivoire:user-account

Conversation

@frivoire
Copy link
Copy Markdown
Contributor

@frivoire frivoire commented Aug 5, 2025

Why ?

When a local GCP account (usually a user-account) already has access to the Memorystore instances of one/several GCP projects, it's much simpler to use that user-account than creating/getting the keys of one/several service-account(s).
Fixing #3

Proposed fix

Patch the script so that we can run it without any service-account files provided, example:

python3 msstats.py --user-account --project-id my-great-project

And of course: no change to the default behavior (=> it will continue using the provided service-account)

NB: the real diff are small, cf the "hide whitespace option", it's mostly reindent ;)

Copy link
Copy Markdown
Contributor

@ajGingrich ajGingrich left a comment

Choose a reason for hiding this comment

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

Overall I like it. Can you run the formatting with black .?

Comment thread msstats.py
Comment thread README.md Outdated
frivoire and others added 3 commits August 6, 2025 17:38
Co-authored-by: Andrew Gingrich <gandrew320@gmail.com>
@frivoire frivoire requested a review from ajGingrich August 6, 2025 15:41
Copy link
Copy Markdown
Contributor

@ajGingrich ajGingrich left a comment

Choose a reason for hiding this comment

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

lgtm!

@ajGingrich
Copy link
Copy Markdown
Contributor

@frivoire are waiting on anything or should we be good to go ahead and merge these in?

@frivoire
Copy link
Copy Markdown
Contributor Author

@frivoire are waiting on anything or should we be good to go ahead and merge these in?

I'm not waiting on anything : the patch works when I tested it, so ok for me.
It's up to you to merge now 👍

@ajGingrich
Copy link
Copy Markdown
Contributor

@frivoire Sounds good, I wasn't sure if you didn't have permissions to merge. I'm merging now!

@ajGingrich ajGingrich merged commit 10263bc into Redislabs-Solution-Architects:main Aug 21, 2025
6 checks passed
@frivoire
Copy link
Copy Markdown
Contributor Author

@frivoire Sounds good, I wasn't sure if you didn't have permissions to merge. I'm merging now!

No, I don't have permission to merge here, I'm just a random guy, not a Redis employee.

@ajGingrich
Copy link
Copy Markdown
Contributor

@frivoire I see that now, I forgot these were open but makes sense. Thanks for contribution!

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants