create_app_block

create_app_block(**kwargs)

Creates an app block.

App blocks are an Amazon AppStream 2.0 resource that stores the details about the virtual hard disk in an S3 bucket. It also stores the setup script with details about how to mount the virtual hard disk. The virtual hard disk includes the application binaries and other files necessary to launch your applications. Multiple applications can be assigned to a single app block.

This is only supported for Elastic fleets.

See also: AWS API Documentation

Request Syntax

response = client.create_app_block(
    Name='string',
    Description='string',
    DisplayName='string',
    SourceS3Location={
        'S3Bucket': 'string',
        'S3Key': 'string'
    },
    SetupScriptDetails={
        'ScriptS3Location': {
            'S3Bucket': 'string',
            'S3Key': 'string'
        },
        'ExecutablePath': 'string',
        'ExecutableParameters': 'string',
        'TimeoutInSeconds': 123
    },
    Tags={
        'string': 'string'
    }
)
Parameters
  • Name (string) --

    [REQUIRED]

    The name of the app block.

  • Description (string) -- The description of the app block.
  • DisplayName (string) -- The display name of the app block. This is not displayed to the user.
  • SourceS3Location (dict) --

    [REQUIRED]

    The source S3 location of the app block.

    • S3Bucket (string) -- [REQUIRED]

      The S3 bucket of the S3 object.

    • S3Key (string) -- [REQUIRED]

      The S3 key of the S3 object.

  • SetupScriptDetails (dict) --

    [REQUIRED]

    The setup script details of the app block.

    • ScriptS3Location (dict) -- [REQUIRED]

      The S3 object location for the script.

      • S3Bucket (string) -- [REQUIRED]

        The S3 bucket of the S3 object.

      • S3Key (string) -- [REQUIRED]

        The S3 key of the S3 object.

    • ExecutablePath (string) -- [REQUIRED]

      The run path for the script.

    • ExecutableParameters (string) --

      The runtime parameters passed to the run path for the script.

    • TimeoutInSeconds (integer) -- [REQUIRED]

      The run timeout, in seconds, for the script.

  • Tags (dict) --

    The tags assigned to the app block.

    • (string) --
      • (string) --
Return type

dict

Returns

Response Syntax

{
    'AppBlock': {
        'Name': 'string',
        'Arn': 'string',
        'Description': 'string',
        'DisplayName': 'string',
        'SourceS3Location': {
            'S3Bucket': 'string',
            'S3Key': 'string'
        },
        'SetupScriptDetails': {
            'ScriptS3Location': {
                'S3Bucket': 'string',
                'S3Key': 'string'
            },
            'ExecutablePath': 'string',
            'ExecutableParameters': 'string',
            'TimeoutInSeconds': 123
        },
        'CreatedTime': datetime(2015, 1, 1)
    }
}

Response Structure

  • (dict) --

    • AppBlock (dict) --

      The app block.

      • Name (string) --

        The name of the app block.

      • Arn (string) --

        The ARN of the app block.

      • Description (string) --

        The description of the app block.

      • DisplayName (string) --

        The display name of the app block.

      • SourceS3Location (dict) --

        The source S3 location of the app block.

        • S3Bucket (string) --

          The S3 bucket of the S3 object.

        • S3Key (string) --

          The S3 key of the S3 object.

      • SetupScriptDetails (dict) --

        The setup script details of the app block.

        • ScriptS3Location (dict) --

          The S3 object location for the script.

          • S3Bucket (string) --

            The S3 bucket of the S3 object.

          • S3Key (string) --

            The S3 key of the S3 object.

        • ExecutablePath (string) --

          The run path for the script.

        • ExecutableParameters (string) --

          The runtime parameters passed to the run path for the script.

        • TimeoutInSeconds (integer) --

          The run timeout, in seconds, for the script.

      • CreatedTime (datetime) --

        The created time of the app block.

Exceptions

  • AppStream.Client.exceptions.ConcurrentModificationException
  • AppStream.Client.exceptions.LimitExceededException
  • AppStream.Client.exceptions.OperationNotPermittedException
  • AppStream.Client.exceptions.ResourceAlreadyExistsException