1. Packages
  2. AWS Classic
  3. API Docs
  4. devicefarm
  5. Upload

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.41.0 published on Tuesday, Jun 18, 2024 by Pulumi

aws.devicefarm.Upload

Explore with Pulumi AI

aws logo

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.41.0 published on Tuesday, Jun 18, 2024 by Pulumi

    Provides a resource to manage AWS Device Farm Uploads.

    NOTE: AWS currently has limited regional support for Device Farm (e.g., us-west-2). See AWS Device Farm endpoints and quotas for information on supported regions.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const example = new aws.devicefarm.Project("example", {name: "example"});
    const exampleUpload = new aws.devicefarm.Upload("example", {
        name: "example",
        projectArn: example.arn,
        type: "APPIUM_JAVA_TESTNG_TEST_SPEC",
    });
    
    import pulumi
    import pulumi_aws as aws
    
    example = aws.devicefarm.Project("example", name="example")
    example_upload = aws.devicefarm.Upload("example",
        name="example",
        project_arn=example.arn,
        type="APPIUM_JAVA_TESTNG_TEST_SPEC")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/devicefarm"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := devicefarm.NewProject(ctx, "example", &devicefarm.ProjectArgs{
    			Name: pulumi.String("example"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = devicefarm.NewUpload(ctx, "example", &devicefarm.UploadArgs{
    			Name:       pulumi.String("example"),
    			ProjectArn: example.Arn,
    			Type:       pulumi.String("APPIUM_JAVA_TESTNG_TEST_SPEC"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Aws.DeviceFarm.Project("example", new()
        {
            Name = "example",
        });
    
        var exampleUpload = new Aws.DeviceFarm.Upload("example", new()
        {
            Name = "example",
            ProjectArn = example.Arn,
            Type = "APPIUM_JAVA_TESTNG_TEST_SPEC",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.devicefarm.Project;
    import com.pulumi.aws.devicefarm.ProjectArgs;
    import com.pulumi.aws.devicefarm.Upload;
    import com.pulumi.aws.devicefarm.UploadArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var example = new Project("example", ProjectArgs.builder()
                .name("example")
                .build());
    
            var exampleUpload = new Upload("exampleUpload", UploadArgs.builder()
                .name("example")
                .projectArn(example.arn())
                .type("APPIUM_JAVA_TESTNG_TEST_SPEC")
                .build());
    
        }
    }
    
    resources:
      example:
        type: aws:devicefarm:Project
        properties:
          name: example
      exampleUpload:
        type: aws:devicefarm:Upload
        name: example
        properties:
          name: example
          projectArn: ${example.arn}
          type: APPIUM_JAVA_TESTNG_TEST_SPEC
    

    Create Upload Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Upload(name: string, args: UploadArgs, opts?: CustomResourceOptions);
    @overload
    def Upload(resource_name: str,
               args: UploadArgs,
               opts: Optional[ResourceOptions] = None)
    
    @overload
    def Upload(resource_name: str,
               opts: Optional[ResourceOptions] = None,
               project_arn: Optional[str] = None,
               type: Optional[str] = None,
               content_type: Optional[str] = None,
               name: Optional[str] = None)
    func NewUpload(ctx *Context, name string, args UploadArgs, opts ...ResourceOption) (*Upload, error)
    public Upload(string name, UploadArgs args, CustomResourceOptions? opts = null)
    public Upload(String name, UploadArgs args)
    public Upload(String name, UploadArgs args, CustomResourceOptions options)
    
    type: aws:devicefarm:Upload
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args UploadArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args UploadArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args UploadArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args UploadArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args UploadArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

    The following reference example uses placeholder values for all input properties.

    var uploadResource = new Aws.DeviceFarm.Upload("uploadResource", new()
    {
        ProjectArn = "string",
        Type = "string",
        ContentType = "string",
        Name = "string",
    });
    
    example, err := devicefarm.NewUpload(ctx, "uploadResource", &devicefarm.UploadArgs{
    	ProjectArn:  pulumi.String("string"),
    	Type:        pulumi.String("string"),
    	ContentType: pulumi.String("string"),
    	Name:        pulumi.String("string"),
    })
    
    var uploadResource = new Upload("uploadResource", UploadArgs.builder()
        .projectArn("string")
        .type("string")
        .contentType("string")
        .name("string")
        .build());
    
    upload_resource = aws.devicefarm.Upload("uploadResource",
        project_arn="string",
        type="string",
        content_type="string",
        name="string")
    
    const uploadResource = new aws.devicefarm.Upload("uploadResource", {
        projectArn: "string",
        type: "string",
        contentType: "string",
        name: "string",
    });
    
    type: aws:devicefarm:Upload
    properties:
        contentType: string
        name: string
        projectArn: string
        type: string
    

    Upload Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The Upload resource accepts the following input properties:

    ProjectArn string
    The ARN of the project for the upload.
    Type string
    The upload's upload type. See AWS Docs for valid list of values.
    ContentType string
    The upload's content type (for example, application/octet-stream).
    Name string
    The upload's file name. The name should not contain any forward slashes (/). If you are uploading an iOS app, the file name must end with the .ipa extension. If you are uploading an Android app, the file name must end with the .apk extension. For all others, the file name must end with the .zip file extension.
    ProjectArn string
    The ARN of the project for the upload.
    Type string
    The upload's upload type. See AWS Docs for valid list of values.
    ContentType string
    The upload's content type (for example, application/octet-stream).
    Name string
    The upload's file name. The name should not contain any forward slashes (/). If you are uploading an iOS app, the file name must end with the .ipa extension. If you are uploading an Android app, the file name must end with the .apk extension. For all others, the file name must end with the .zip file extension.
    projectArn String
    The ARN of the project for the upload.
    type String
    The upload's upload type. See AWS Docs for valid list of values.
    contentType String
    The upload's content type (for example, application/octet-stream).
    name String
    The upload's file name. The name should not contain any forward slashes (/). If you are uploading an iOS app, the file name must end with the .ipa extension. If you are uploading an Android app, the file name must end with the .apk extension. For all others, the file name must end with the .zip file extension.
    projectArn string
    The ARN of the project for the upload.
    type string
    The upload's upload type. See AWS Docs for valid list of values.
    contentType string
    The upload's content type (for example, application/octet-stream).
    name string
    The upload's file name. The name should not contain any forward slashes (/). If you are uploading an iOS app, the file name must end with the .ipa extension. If you are uploading an Android app, the file name must end with the .apk extension. For all others, the file name must end with the .zip file extension.
    project_arn str
    The ARN of the project for the upload.
    type str
    The upload's upload type. See AWS Docs for valid list of values.
    content_type str
    The upload's content type (for example, application/octet-stream).
    name str
    The upload's file name. The name should not contain any forward slashes (/). If you are uploading an iOS app, the file name must end with the .ipa extension. If you are uploading an Android app, the file name must end with the .apk extension. For all others, the file name must end with the .zip file extension.
    projectArn String
    The ARN of the project for the upload.
    type String
    The upload's upload type. See AWS Docs for valid list of values.
    contentType String
    The upload's content type (for example, application/octet-stream).
    name String
    The upload's file name. The name should not contain any forward slashes (/). If you are uploading an iOS app, the file name must end with the .ipa extension. If you are uploading an Android app, the file name must end with the .apk extension. For all others, the file name must end with the .zip file extension.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Upload resource produces the following output properties:

    Arn string
    The Amazon Resource Name of this upload.
    Category string
    The upload's category.
    Id string
    The provider-assigned unique ID for this managed resource.
    Metadata string
    The upload's metadata. For example, for Android, this contains information that is parsed from the manifest and is displayed in the AWS Device Farm console after the associated app is uploaded.
    Url string
    The presigned Amazon S3 URL that was used to store a file using a PUT request.
    Arn string
    The Amazon Resource Name of this upload.
    Category string
    The upload's category.
    Id string
    The provider-assigned unique ID for this managed resource.
    Metadata string
    The upload's metadata. For example, for Android, this contains information that is parsed from the manifest and is displayed in the AWS Device Farm console after the associated app is uploaded.
    Url string
    The presigned Amazon S3 URL that was used to store a file using a PUT request.
    arn String
    The Amazon Resource Name of this upload.
    category String
    The upload's category.
    id String
    The provider-assigned unique ID for this managed resource.
    metadata String
    The upload's metadata. For example, for Android, this contains information that is parsed from the manifest and is displayed in the AWS Device Farm console after the associated app is uploaded.
    url String
    The presigned Amazon S3 URL that was used to store a file using a PUT request.
    arn string
    The Amazon Resource Name of this upload.
    category string
    The upload's category.
    id string
    The provider-assigned unique ID for this managed resource.
    metadata string
    The upload's metadata. For example, for Android, this contains information that is parsed from the manifest and is displayed in the AWS Device Farm console after the associated app is uploaded.
    url string
    The presigned Amazon S3 URL that was used to store a file using a PUT request.
    arn str
    The Amazon Resource Name of this upload.
    category str
    The upload's category.
    id str
    The provider-assigned unique ID for this managed resource.
    metadata str
    The upload's metadata. For example, for Android, this contains information that is parsed from the manifest and is displayed in the AWS Device Farm console after the associated app is uploaded.
    url str
    The presigned Amazon S3 URL that was used to store a file using a PUT request.
    arn String
    The Amazon Resource Name of this upload.
    category String
    The upload's category.
    id String
    The provider-assigned unique ID for this managed resource.
    metadata String
    The upload's metadata. For example, for Android, this contains information that is parsed from the manifest and is displayed in the AWS Device Farm console after the associated app is uploaded.
    url String
    The presigned Amazon S3 URL that was used to store a file using a PUT request.

    Look up Existing Upload Resource

    Get an existing Upload resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: UploadState, opts?: CustomResourceOptions): Upload
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            arn: Optional[str] = None,
            category: Optional[str] = None,
            content_type: Optional[str] = None,
            metadata: Optional[str] = None,
            name: Optional[str] = None,
            project_arn: Optional[str] = None,
            type: Optional[str] = None,
            url: Optional[str] = None) -> Upload
    func GetUpload(ctx *Context, name string, id IDInput, state *UploadState, opts ...ResourceOption) (*Upload, error)
    public static Upload Get(string name, Input<string> id, UploadState? state, CustomResourceOptions? opts = null)
    public static Upload get(String name, Output<String> id, UploadState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Arn string
    The Amazon Resource Name of this upload.
    Category string
    The upload's category.
    ContentType string
    The upload's content type (for example, application/octet-stream).
    Metadata string
    The upload's metadata. For example, for Android, this contains information that is parsed from the manifest and is displayed in the AWS Device Farm console after the associated app is uploaded.
    Name string
    The upload's file name. The name should not contain any forward slashes (/). If you are uploading an iOS app, the file name must end with the .ipa extension. If you are uploading an Android app, the file name must end with the .apk extension. For all others, the file name must end with the .zip file extension.
    ProjectArn string
    The ARN of the project for the upload.
    Type string
    The upload's upload type. See AWS Docs for valid list of values.
    Url string
    The presigned Amazon S3 URL that was used to store a file using a PUT request.
    Arn string
    The Amazon Resource Name of this upload.
    Category string
    The upload's category.
    ContentType string
    The upload's content type (for example, application/octet-stream).
    Metadata string
    The upload's metadata. For example, for Android, this contains information that is parsed from the manifest and is displayed in the AWS Device Farm console after the associated app is uploaded.
    Name string
    The upload's file name. The name should not contain any forward slashes (/). If you are uploading an iOS app, the file name must end with the .ipa extension. If you are uploading an Android app, the file name must end with the .apk extension. For all others, the file name must end with the .zip file extension.
    ProjectArn string
    The ARN of the project for the upload.
    Type string
    The upload's upload type. See AWS Docs for valid list of values.
    Url string
    The presigned Amazon S3 URL that was used to store a file using a PUT request.
    arn String
    The Amazon Resource Name of this upload.
    category String
    The upload's category.
    contentType String
    The upload's content type (for example, application/octet-stream).
    metadata String
    The upload's metadata. For example, for Android, this contains information that is parsed from the manifest and is displayed in the AWS Device Farm console after the associated app is uploaded.
    name String
    The upload's file name. The name should not contain any forward slashes (/). If you are uploading an iOS app, the file name must end with the .ipa extension. If you are uploading an Android app, the file name must end with the .apk extension. For all others, the file name must end with the .zip file extension.
    projectArn String
    The ARN of the project for the upload.
    type String
    The upload's upload type. See AWS Docs for valid list of values.
    url String
    The presigned Amazon S3 URL that was used to store a file using a PUT request.
    arn string
    The Amazon Resource Name of this upload.
    category string
    The upload's category.
    contentType string
    The upload's content type (for example, application/octet-stream).
    metadata string
    The upload's metadata. For example, for Android, this contains information that is parsed from the manifest and is displayed in the AWS Device Farm console after the associated app is uploaded.
    name string
    The upload's file name. The name should not contain any forward slashes (/). If you are uploading an iOS app, the file name must end with the .ipa extension. If you are uploading an Android app, the file name must end with the .apk extension. For all others, the file name must end with the .zip file extension.
    projectArn string
    The ARN of the project for the upload.
    type string
    The upload's upload type. See AWS Docs for valid list of values.
    url string
    The presigned Amazon S3 URL that was used to store a file using a PUT request.
    arn str
    The Amazon Resource Name of this upload.
    category str
    The upload's category.
    content_type str
    The upload's content type (for example, application/octet-stream).
    metadata str
    The upload's metadata. For example, for Android, this contains information that is parsed from the manifest and is displayed in the AWS Device Farm console after the associated app is uploaded.
    name str
    The upload's file name. The name should not contain any forward slashes (/). If you are uploading an iOS app, the file name must end with the .ipa extension. If you are uploading an Android app, the file name must end with the .apk extension. For all others, the file name must end with the .zip file extension.
    project_arn str
    The ARN of the project for the upload.
    type str
    The upload's upload type. See AWS Docs for valid list of values.
    url str
    The presigned Amazon S3 URL that was used to store a file using a PUT request.
    arn String
    The Amazon Resource Name of this upload.
    category String
    The upload's category.
    contentType String
    The upload's content type (for example, application/octet-stream).
    metadata String
    The upload's metadata. For example, for Android, this contains information that is parsed from the manifest and is displayed in the AWS Device Farm console after the associated app is uploaded.
    name String
    The upload's file name. The name should not contain any forward slashes (/). If you are uploading an iOS app, the file name must end with the .ipa extension. If you are uploading an Android app, the file name must end with the .apk extension. For all others, the file name must end with the .zip file extension.
    projectArn String
    The ARN of the project for the upload.
    type String
    The upload's upload type. See AWS Docs for valid list of values.
    url String
    The presigned Amazon S3 URL that was used to store a file using a PUT request.

    Import

    Using pulumi import, import DeviceFarm Uploads using their ARN. For example:

    $ pulumi import aws:devicefarm/upload:Upload example arn:aws:devicefarm:us-west-2:123456789012:upload:4fa784c7-ccb4-4dbf-ba4f-02198320daa1
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    AWS Classic pulumi/pulumi-aws
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the aws Terraform Provider.
    aws logo

    Try AWS Native preview for resources not in the classic version.

    AWS Classic v6.41.0 published on Tuesday, Jun 18, 2024 by Pulumi