-
Notifications
You must be signed in to change notification settings - Fork 80
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
NSFS | NC | Add a Flag to Change the Value of allow_bucket_creation
#7827
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
romayalon
reviewed
Feb 18, 2024
romayalon
reviewed
Feb 26, 2024
shirady
force-pushed
the
allow-bucket-creation
branch
2 times, most recently
from
February 28, 2024 11:10
7c7ad9b
to
743d83d
Compare
shirady
changed the title
NSFS | NC | Add a Flag to Change the Value Of
NSFS | NC | Add a Flag to Change the Value of Feb 28, 2024
allow_bucket_creation
allow_bucket_creation
shirady
force-pushed
the
allow-bucket-creation
branch
2 times, most recently
from
February 28, 2024 12:38
65fde15
to
77ff879
Compare
shirady
force-pushed
the
allow-bucket-creation
branch
from
February 29, 2024 11:45
c3a7380
to
84dd91b
Compare
2 tasks
shirady
force-pushed
the
allow-bucket-creation
branch
2 times, most recently
from
March 3, 2024 12:49
72aa470
to
9674b59
Compare
naveenpaul1
reviewed
Mar 4, 2024
shirady
force-pushed
the
allow-bucket-creation
branch
5 times, most recently
from
March 4, 2024 15:50
d24e69b
to
2a3d0a9
Compare
shirady
force-pushed
the
allow-bucket-creation
branch
3 times, most recently
from
March 5, 2024 06:57
5f8393c
to
f986bf9
Compare
…licitly 1. Add a flag to change the value of allow_bucket_creation. 2. Edit details message when BucketCreationNotAllowed is thrown. 3. Add the option for boolean flags to pass 'true' and 'false' (wide, show_secrets, regenerate). 4. Add a new error InvalidBooleanValue. 5. Reduce the number of spaces in the help menu. Signed-off-by: shirady <57721533+shirady@users.noreply.github.com>
shirady
force-pushed
the
allow-bucket-creation
branch
from
March 5, 2024 10:33
824cf0d
to
57474ee
Compare
romayalon
approved these changes
Mar 5, 2024
2 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Explain the changes
allow_bucket_creation
.BucketCreationNotAllowed
is thrown.wide
,show_secrets
,regenerate
).InvalidBooleanValue
.Issues: Fixed BZ 2262992 #7786
allow_bucket_creation
value is inferred from thenew_buckets_path
: if the user passes a value tonew_buckets_path
then it is true, otherwise, it is false.from_file
flag, after this PR is merged we need to merge also PR NSFS | NC | Use--from_file
Option in Account Create #7779 as a fix.wide
not part of the fetch data or extract and remove it before writing the config file (opened issue NSFS | NC |wide
Property Should Be Removed fromfetch_bucket_data
Andfetch_account_data
#7871).Testing Instructions:
Manual Tests:
bucket_creation
and see the value ofallow_bucket_creation
changes, for example:FS_ROOT
and a directory for a bucket:mkdir -p /tmp/nsfs_root1/my-bucket
and give permissionschmod 777 /tmp/nsfs_root1/
chmod 777 /tmp/nsfs_root1/my-bucket
.This will be the argument for:
new_buckets_path
flag/tmp/nsfs_root1
(that we will use in the account commands)path
in the buckets commands/tmp/nsfs_root1/my-bucket
(that we will use in bucket commands).new_buckets_path
(allow_bucket_creation
inferred to be true):sudo node src/cmd/manage_nsfs account add --name <account-name> --new_buckets_path /tmp/nsfs_root1 --uid <uid> --gid <gid>
allow_bucket_creation
will be false):sudo node src/cmd/manage_nsfs account update --name <account-name> --allow_bucket_creation false
.sudo node src/cmd/manage_nsfs account status --name <account-name> --show_secrets=true
Unit Tests:
please run:
sudo node ./node_modules/.bin/_mocha src/test/unit_tests/test_nc_nsfs_cli.js
.sudo npx jest test_nc_nsfs_account_cli.test.js
.Doc added/updated
Tests added