-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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 tool to upgrade ACLs #5016
Add tool to upgrade ACLs #5016
Conversation
a8bf7cb
to
f79436f
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.
Reviewed 2 of 2 files at r1.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @mangalaman93)
contrib/aclupgrade/upgrade.go, line 1 at r1 (raw file):
package main
Add license.
Also, move it to a Dgraph subcommand called 'upgrade'. And inside the main, just have a flag for acl upgrade for now.
dgraph upgrade --acls -a "localhost:8080"
contrib/aclupgrade/upgrade.go, line 42 at r1 (raw file):
userName := flag.String("u", "", "Username to login to Dgraph cluster") password := flag.String("p", "", "Password to login to Dgraph cluster") deleteOld := flag.Bool("d", false, "Delete the older ACL predicates")
Maybe we should delete by default. Otherwise, a re-run of this script would end up duplicating the rules. Do the deletion only after successful mutation.
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.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @manishrjain)
contrib/aclupgrade/upgrade.go, line 1 at r1 (raw file):
Previously, manishrjain (Manish R Jain) wrote…
Add license.
Also, move it to a Dgraph subcommand called 'upgrade'. And inside the main, just have a flag for acl upgrade for now.
dgraph upgrade --acls -a "localhost:8080"
Done.
contrib/aclupgrade/upgrade.go, line 42 at r1 (raw file):
Previously, manishrjain (Manish R Jain) wrote…
Maybe we should delete by default. Otherwise, a re-run of this script would end up duplicating the rules. Do the deletion only after successful mutation.
Done.
b16ff2b
to
2d67a64
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.
Reviewed 3 of 4 files at r2, 1 of 1 files at r3.
Reviewable status: all files reviewed, 2 unresolved discussions (waiting on @danielmai, @mangalaman93, @manishrjain, and @MichaelJCompton)
Add dgraph upgrade tool to upgrade the ACL data format. Co-authored-by: Animesh Chandra Pathak <[email protected]> Co-authored-by: Aman Mangal <[email protected]>
TODO
This change is
Docs Preview: