Creating a Bucket Policy using JSON
Describes how to create a bucket policy that is applicable to all objects present in the bucket.
About this task
You can add a bucket policy by using the Data Fabric UI.
If you are well-versed with JSON, you can directly write a policy JSON or upload the policy JSON from a file to create a bucket policy.
If you are not well-versed with JSON, you can use the policy generator that will generate the policy in JSON format. See Creating a Bucket Policy using Policy Generator.
Follow the steps given below to create a bucket policy by directly uploading a JSON file or creating a JSON file.
Procedure
- Log on to the Data Fabric UI.
- Select Fabric user from the dropdown on the Home page.
- Click the Table view icon on the Resources card.
- In the tabular list of fabrics, click the down arrow for the fabric that contains the bucket to which you wish to upload objects.
- Click the bucket name seen under Resource Name.
- Navigate to the Settings tab.
- Under Properties, click the pencil icon for Policy.
- Scroll down to view Select File under the blank text area.
- Click Select File and select a pre-defined JSON file from the path where it is stored.
- Click Upload JSON. The policy is visible in the blank text area or form visible on the Generate Policy page. Alternatively, you can also type in a JSON in the blank text area provided on the Generate Policy page.
- Click Save Policy.
Results
The bucket policy is saved and applied to the bucket resources mentioned in the bucket policy. See
Sample Bucket Policy for bucket policy JSON examples. Related maprcli CommandsTo implement the
features described on this page, the Data Fabric UI relies on the following
maprcli
command. The command is provided for general reference.
For more information, see maprcli Commands in This Guide.