Skip to content

Commit

Permalink
Merge pull request #631 from 0chain/feature/enterprise-blobber
Browse files Browse the repository at this point in the history
Enterprise blobber
  • Loading branch information
Jayashsatolia403 authored Aug 10, 2024
2 parents aab3abe + 31b4930 commit 33b31c4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion cmd/newallocation.go
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@ var newallocationCmd = &cobra.Command{
}

thirdPartyExtendable, _ := flags.GetBool("third_party_extendable")
isEnterprise, _ := flags.GetBool("enterprise")
force, _ := flags.GetBool("force")

// Read the file options flags
Expand Down Expand Up @@ -256,6 +257,7 @@ var newallocationCmd = &cobra.Command{
FileOptionsParams: &fileOptionParams,
ThirdPartyExtendable: thirdPartyExtendable,
Force: force,
IsEnterprise: isEnterprise,
}
allocationID, _, _, err = sdk.CreateAllocationWith(options)
if err != nil {
Expand All @@ -273,7 +275,7 @@ var newallocationCmd = &cobra.Command{
}

allocationID, _, _, err = sdk.CreateAllocationForOwner(owner, ownerPublicKey, *datashards, *parityshards,
*size, readPrice, writePrice, lock, preferred_blobbers, blobber_auth_tickets, thirdPartyExtendable, force, &fileOptionParams)
*size, readPrice, writePrice, lock, preferred_blobbers, blobber_auth_tickets, thirdPartyExtendable, isEnterprise, force, &fileOptionParams)
if err != nil {
log.Fatal("Error creating allocation: ", err)
}
Expand Down Expand Up @@ -346,6 +348,7 @@ func init() {

newallocationCmd.Flags().Bool("force", false, "(default false) force to get blobbers even if required number of blobbers are not available (should be passed true in case of restricted blobbers)")
newallocationCmd.Flags().Bool("third_party_extendable", false, "(default false) specify if the allocation can be extended by users other than the owner")
newallocationCmd.Flags().Bool("enterprise", false, "(default false) specify if the allocation is for enterprise")
newallocationCmd.Flags().Bool("forbid_upload", false, "(default false) specify if users cannot upload to this allocation")
newallocationCmd.Flags().Bool("forbid_delete", false, "(default false) specify if the users cannot delete objects from this allocation")
newallocationCmd.Flags().Bool("forbid_update", false, "(default false) specify if the users cannot update objects in this allocation")
Expand Down

0 comments on commit 33b31c4

Please sign in to comment.