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
feat: Add cli for simple gateway registration #11195
feat: Add cli for simple gateway registration #11195
Conversation
Thanks for opening a PR! 💯 A couple initial guidelines
Howto
More infoPlease take a moment to read through the Magma project's
If this is your first Magma PR, also consider reading
|
Oops! Looks like you failed the Howto
♻️ Updated: ✅ The check is passing the DCO check after the last commit. |
Oops! Looks like you failed the Howto
♻️ Updated: ✅ The check is passing the Python Format Check after the last commit. |
86b10e3
to
18a5a5d
Compare
18a5a5d
to
b61322e
Compare
0dc08d2
to
8403f87
Compare
f2158bd
to
9fb1e1d
Compare
9fb1e1d
to
cc58f43
Compare
cc58f43
to
ecca9f9
Compare
1a1f771
to
c0b4922
Compare
08fe066
to
91b5f74
Compare
91b5f74
to
b87f344
Compare
af8a169
to
02a07dd
Compare
02a07dd
to
3fee3c3
Compare
3fee3c3
to
5b3393e
Compare
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.
lgtm
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.
Looking good! Couple small things
Returns: | ||
grpc channel | ||
""" | ||
rootca_path = ROOTCA_PATH if not rootca_path else rootca_path |
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.
So if no rootca path is passed in, we want to use the default system credentials. I think that means you don't have to pass any ssl creds, but not sure how it works. But if you want, we can leave it like this for now, and I'll test it when I get around to making the Orc8r<>Let'sEncrypt work e2e
8a5cacb
to
b0f7101
Compare
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.
Lgtm!
if res.HasField("error"): | ||
raise Exception(res.error) | ||
|
||
msg = textwrap.dedent( |
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.
Nit: I'd prob put this printed msg in the main func, to keep this func as "stateless" as possible
if __name__ == "__main__": | ||
main() | ||
print("> Running checkin_cli") | ||
checkin_cli.main() |
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.
Oh dang does this work? Nice good to know
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.
Yeah looks a bit sketch but it does 🤷🏻♀️
b0f7101
to
b91d25b
Compare
813b111
to
34c74be
Compare
Signed-off-by: Christine Wang <christinewang@fb.com>
34c74be
to
6ff4ea8
Compare
Summary
register CLI for gateways
Testing
manually tested by running CLIs
Note: this PR is dependent on #11169 & #11692