Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/aleph/sdk/client/abstract.py
Original file line number Diff line number Diff line change
Expand Up @@ -315,6 +315,9 @@ async def create_program(
vcpus: Optional[int] = None,
timeout_seconds: Optional[float] = None,
persistent: bool = False,
allow_amend: bool = False,
internet: bool = True,
aleph_api: bool = True,
encoding: Encoding = Encoding.zip,
volumes: Optional[List[Mapping]] = None,
subscriptions: Optional[List[Mapping]] = None,
Expand All @@ -335,6 +338,9 @@ async def create_program(
:param vcpus: Number of vCPUs to allocate (Default: 1)
:param timeout_seconds: Timeout in seconds (Default: 30.0)
:param persistent: Whether the program should be persistent or not (Default: False)
:param allow_amend: Whether the deployed VM image may be changed (Default: False)
:param internet: Whether the VM should have internet connectivity. (Default: True)
:param aleph_api: Whether the VM needs access to Aleph messages API (Default: True)
:param encoding: Encoding to use (Default: Encoding.zip)
:param volumes: Volumes to mount
:param subscriptions: Patterns of aleph.im messages to forward to the program's event receiver
Expand Down
9 changes: 6 additions & 3 deletions src/aleph/sdk/client/authenticated_http.py
Original file line number Diff line number Diff line change
Expand Up @@ -401,6 +401,9 @@ async def create_program(
vcpus: Optional[int] = None,
timeout_seconds: Optional[float] = None,
persistent: bool = False,
allow_amend: bool = False,
internet: bool = True,
aleph_api: bool = True,
encoding: Encoding = Encoding.zip,
volumes: Optional[List[Mapping]] = None,
subscriptions: Optional[List[Mapping]] = None,
Expand Down Expand Up @@ -434,7 +437,7 @@ async def create_program(
content = ProgramContent(
type="vm-function",
address=address,
allow_amend=False,
allow_amend=allow_amend,
code=CodeContent(
encoding=encoding,
entrypoint=entrypoint,
Expand All @@ -444,8 +447,8 @@ async def create_program(
on=triggers,
environment=FunctionEnvironment(
reproducible=False,
internet=True,
aleph_api=True,
internet=internet,
aleph_api=aleph_api,
),
variables=environment_variables,
resources=MachineResources(
Expand Down