Skip to content

Commit

Permalink
Merge pull request #15 from synkd/update_entitlement_mode_allocations…
Browse files Browse the repository at this point in the history
…_after_creation

Disable SCA after creating allocation
  • Loading branch information
synkd authored Oct 18, 2022
2 parents eb516df + b5f2683 commit 9d4cfda
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions manifester/manifester.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,16 @@ def create_subscription_allocation(self):
f"valid versions are {self.valid_sat_versions}."
)
self.allocation_uuid = self.allocation["body"]["uuid"]
if self.simple_content_access == "disabled":
simple_retry(
requests.put,
cmd_args=[f"{self.allocations_url}/{self.allocation_uuid}"],
cmd_kwargs={
"headers": {"Authorization": f"Bearer {self.access_token}"},
"proxies": self.manifest_data.get("proxies", settings.proxies),
"json": {"simpleContentAccess": "disabled"},
},
)
logger.info(
f"Subscription allocation created with name {self.allocation_name} "
f"and UUID {self.allocation_uuid}"
Expand Down

0 comments on commit 9d4cfda

Please sign in to comment.