1. Packages
  2. Harness Provider
  3. API Docs
  4. autostopping
  5. AwsProxy
Harness v0.7.2 published on Tuesday, Apr 15, 2025 by Pulumi

harness.autostopping.AwsProxy

Explore with Pulumi AI

Resource for creating an AWS Autostopping proxy

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as harness from "@pulumi/harness";

const test = new harness.autostopping.AwsProxy("test", {
    name: "name",
    cloudConnectorId: "cloud_connector_id",
    hostName: "host_name",
    region: "region",
    vpc: "vpc",
    securityGroups: [
        "sg1",
        "sg2",
    ],
    route53HostedZoneId: "/hostedzone/zone_id",
    machineType: "t2.medium",
    apiKey: "",
    allocateStaticIp: true,
    deleteCloudResourcesOnDestroy: true,
});
Copy
import pulumi
import pulumi_harness as harness

test = harness.autostopping.AwsProxy("test",
    name="name",
    cloud_connector_id="cloud_connector_id",
    host_name="host_name",
    region="region",
    vpc="vpc",
    security_groups=[
        "sg1",
        "sg2",
    ],
    route53_hosted_zone_id="/hostedzone/zone_id",
    machine_type="t2.medium",
    api_key="",
    allocate_static_ip=True,
    delete_cloud_resources_on_destroy=True)
Copy
package main

import (
	"github.com/pulumi/pulumi-harness/sdk/go/harness/autostopping"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := autostopping.NewAwsProxy(ctx, "test", &autostopping.AwsProxyArgs{
			Name:             pulumi.String("name"),
			CloudConnectorId: pulumi.String("cloud_connector_id"),
			HostName:         pulumi.String("host_name"),
			Region:           pulumi.String("region"),
			Vpc:              pulumi.String("vpc"),
			SecurityGroups: pulumi.StringArray{
				pulumi.String("sg1"),
				pulumi.String("sg2"),
			},
			Route53HostedZoneId:           pulumi.String("/hostedzone/zone_id"),
			MachineType:                   pulumi.String("t2.medium"),
			ApiKey:                        pulumi.String(""),
			AllocateStaticIp:              pulumi.Bool(true),
			DeleteCloudResourcesOnDestroy: pulumi.Bool(true),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Harness = Pulumi.Harness;

return await Deployment.RunAsync(() => 
{
    var test = new Harness.Autostopping.AwsProxy("test", new()
    {
        Name = "name",
        CloudConnectorId = "cloud_connector_id",
        HostName = "host_name",
        Region = "region",
        Vpc = "vpc",
        SecurityGroups = new[]
        {
            "sg1",
            "sg2",
        },
        Route53HostedZoneId = "/hostedzone/zone_id",
        MachineType = "t2.medium",
        ApiKey = "",
        AllocateStaticIp = true,
        DeleteCloudResourcesOnDestroy = true,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.harness.autostopping.AwsProxy;
import com.pulumi.harness.autostopping.AwsProxyArgs;
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 test = new AwsProxy("test", AwsProxyArgs.builder()
            .name("name")
            .cloudConnectorId("cloud_connector_id")
            .hostName("host_name")
            .region("region")
            .vpc("vpc")
            .securityGroups(            
                "sg1",
                "sg2")
            .route53HostedZoneId("/hostedzone/zone_id")
            .machineType("t2.medium")
            .apiKey("")
            .allocateStaticIp(true)
            .deleteCloudResourcesOnDestroy(true)
            .build());

    }
}
Copy
resources:
  test:
    type: harness:autostopping:AwsProxy
    properties:
      name: name
      cloudConnectorId: cloud_connector_id
      hostName: host_name
      region: region
      vpc: vpc
      securityGroups:
        - sg1
        - sg2
      route53HostedZoneId: /hostedzone/zone_id
      machineType: t2.medium
      apiKey: ""
      allocateStaticIp: true
      deleteCloudResourcesOnDestroy: true
Copy

Create AwsProxy Resource

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

Constructor syntax

new AwsProxy(name: string, args: AwsProxyArgs, opts?: CustomResourceOptions);
@overload
def AwsProxy(resource_name: str,
             args: AwsProxyArgs,
             opts: Optional[ResourceOptions] = None)

@overload
def AwsProxy(resource_name: str,
             opts: Optional[ResourceOptions] = None,
             region: Optional[str] = None,
             api_key: Optional[str] = None,
             cloud_connector_id: Optional[str] = None,
             delete_cloud_resources_on_destroy: Optional[bool] = None,
             host_name: Optional[str] = None,
             machine_type: Optional[str] = None,
             vpc: Optional[str] = None,
             certificates: Optional[AwsProxyCertificatesArgs] = None,
             keypair: Optional[str] = None,
             name: Optional[str] = None,
             allocate_static_ip: Optional[bool] = None,
             route53_hosted_zone_id: Optional[str] = None,
             security_groups: Optional[Sequence[str]] = None)
func NewAwsProxy(ctx *Context, name string, args AwsProxyArgs, opts ...ResourceOption) (*AwsProxy, error)
public AwsProxy(string name, AwsProxyArgs args, CustomResourceOptions? opts = null)
public AwsProxy(String name, AwsProxyArgs args)
public AwsProxy(String name, AwsProxyArgs args, CustomResourceOptions options)
type: harness:autostopping:AwsProxy
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

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

Constructor example

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

var awsProxyResource = new Harness.Autostopping.AwsProxy("awsProxyResource", new()
{
    Region = "string",
    ApiKey = "string",
    CloudConnectorId = "string",
    DeleteCloudResourcesOnDestroy = false,
    HostName = "string",
    MachineType = "string",
    Vpc = "string",
    Certificates = new Harness.Autostopping.Inputs.AwsProxyCertificatesArgs
    {
        CertSecretId = "string",
        KeySecretId = "string",
    },
    Keypair = "string",
    Name = "string",
    AllocateStaticIp = false,
    Route53HostedZoneId = "string",
    SecurityGroups = new[]
    {
        "string",
    },
});
Copy
example, err := autostopping.NewAwsProxy(ctx, "awsProxyResource", &autostopping.AwsProxyArgs{
	Region:                        pulumi.String("string"),
	ApiKey:                        pulumi.String("string"),
	CloudConnectorId:              pulumi.String("string"),
	DeleteCloudResourcesOnDestroy: pulumi.Bool(false),
	HostName:                      pulumi.String("string"),
	MachineType:                   pulumi.String("string"),
	Vpc:                           pulumi.String("string"),
	Certificates: &autostopping.AwsProxyCertificatesArgs{
		CertSecretId: pulumi.String("string"),
		KeySecretId:  pulumi.String("string"),
	},
	Keypair:             pulumi.String("string"),
	Name:                pulumi.String("string"),
	AllocateStaticIp:    pulumi.Bool(false),
	Route53HostedZoneId: pulumi.String("string"),
	SecurityGroups: pulumi.StringArray{
		pulumi.String("string"),
	},
})
Copy
var awsProxyResource = new AwsProxy("awsProxyResource", AwsProxyArgs.builder()
    .region("string")
    .apiKey("string")
    .cloudConnectorId("string")
    .deleteCloudResourcesOnDestroy(false)
    .hostName("string")
    .machineType("string")
    .vpc("string")
    .certificates(AwsProxyCertificatesArgs.builder()
        .certSecretId("string")
        .keySecretId("string")
        .build())
    .keypair("string")
    .name("string")
    .allocateStaticIp(false)
    .route53HostedZoneId("string")
    .securityGroups("string")
    .build());
Copy
aws_proxy_resource = harness.autostopping.AwsProxy("awsProxyResource",
    region="string",
    api_key="string",
    cloud_connector_id="string",
    delete_cloud_resources_on_destroy=False,
    host_name="string",
    machine_type="string",
    vpc="string",
    certificates={
        "cert_secret_id": "string",
        "key_secret_id": "string",
    },
    keypair="string",
    name="string",
    allocate_static_ip=False,
    route53_hosted_zone_id="string",
    security_groups=["string"])
Copy
const awsProxyResource = new harness.autostopping.AwsProxy("awsProxyResource", {
    region: "string",
    apiKey: "string",
    cloudConnectorId: "string",
    deleteCloudResourcesOnDestroy: false,
    hostName: "string",
    machineType: "string",
    vpc: "string",
    certificates: {
        certSecretId: "string",
        keySecretId: "string",
    },
    keypair: "string",
    name: "string",
    allocateStaticIp: false,
    route53HostedZoneId: "string",
    securityGroups: ["string"],
});
Copy
type: harness:autostopping:AwsProxy
properties:
    allocateStaticIp: false
    apiKey: string
    certificates:
        certSecretId: string
        keySecretId: string
    cloudConnectorId: string
    deleteCloudResourcesOnDestroy: false
    hostName: string
    keypair: string
    machineType: string
    name: string
    region: string
    route53HostedZoneId: string
    securityGroups:
        - string
    vpc: string
Copy

AwsProxy Resource Properties

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

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The AwsProxy resource accepts the following input properties:

ApiKey This property is required. string
Harness NG API key
CloudConnectorId This property is required. string
Id of the cloud connector
DeleteCloudResourcesOnDestroy This property is required. bool
HostName This property is required. string
Hostname for the proxy
MachineType This property is required. string
Machine instance type
Region This property is required. string
Region in which cloud resources are hosted
Vpc This property is required. string
VPC in which cloud resources are hosted
AllocateStaticIp bool
Boolean value to indicate if proxy vm needs to have static IP
Certificates AwsProxyCertificates
Keypair string
Name string
Name of the proxy
Route53HostedZoneId string
Route 53 hosted zone id
SecurityGroups List<string>
Security Group to define the security rules that determine the inbound and outbound traffic
ApiKey This property is required. string
Harness NG API key
CloudConnectorId This property is required. string
Id of the cloud connector
DeleteCloudResourcesOnDestroy This property is required. bool
HostName This property is required. string
Hostname for the proxy
MachineType This property is required. string
Machine instance type
Region This property is required. string
Region in which cloud resources are hosted
Vpc This property is required. string
VPC in which cloud resources are hosted
AllocateStaticIp bool
Boolean value to indicate if proxy vm needs to have static IP
Certificates AwsProxyCertificatesArgs
Keypair string
Name string
Name of the proxy
Route53HostedZoneId string
Route 53 hosted zone id
SecurityGroups []string
Security Group to define the security rules that determine the inbound and outbound traffic
apiKey This property is required. String
Harness NG API key
cloudConnectorId This property is required. String
Id of the cloud connector
deleteCloudResourcesOnDestroy This property is required. Boolean
hostName This property is required. String
Hostname for the proxy
machineType This property is required. String
Machine instance type
region This property is required. String
Region in which cloud resources are hosted
vpc This property is required. String
VPC in which cloud resources are hosted
allocateStaticIp Boolean
Boolean value to indicate if proxy vm needs to have static IP
certificates AwsProxyCertificates
keypair String
name String
Name of the proxy
route53HostedZoneId String
Route 53 hosted zone id
securityGroups List<String>
Security Group to define the security rules that determine the inbound and outbound traffic
apiKey This property is required. string
Harness NG API key
cloudConnectorId This property is required. string
Id of the cloud connector
deleteCloudResourcesOnDestroy This property is required. boolean
hostName This property is required. string
Hostname for the proxy
machineType This property is required. string
Machine instance type
region This property is required. string
Region in which cloud resources are hosted
vpc This property is required. string
VPC in which cloud resources are hosted
allocateStaticIp boolean
Boolean value to indicate if proxy vm needs to have static IP
certificates AwsProxyCertificates
keypair string
name string
Name of the proxy
route53HostedZoneId string
Route 53 hosted zone id
securityGroups string[]
Security Group to define the security rules that determine the inbound and outbound traffic
api_key This property is required. str
Harness NG API key
cloud_connector_id This property is required. str
Id of the cloud connector
delete_cloud_resources_on_destroy This property is required. bool
host_name This property is required. str
Hostname for the proxy
machine_type This property is required. str
Machine instance type
region This property is required. str
Region in which cloud resources are hosted
vpc This property is required. str
VPC in which cloud resources are hosted
allocate_static_ip bool
Boolean value to indicate if proxy vm needs to have static IP
certificates AwsProxyCertificatesArgs
keypair str
name str
Name of the proxy
route53_hosted_zone_id str
Route 53 hosted zone id
security_groups Sequence[str]
Security Group to define the security rules that determine the inbound and outbound traffic
apiKey This property is required. String
Harness NG API key
cloudConnectorId This property is required. String
Id of the cloud connector
deleteCloudResourcesOnDestroy This property is required. Boolean
hostName This property is required. String
Hostname for the proxy
machineType This property is required. String
Machine instance type
region This property is required. String
Region in which cloud resources are hosted
vpc This property is required. String
VPC in which cloud resources are hosted
allocateStaticIp Boolean
Boolean value to indicate if proxy vm needs to have static IP
certificates Property Map
keypair String
name String
Name of the proxy
route53HostedZoneId String
Route 53 hosted zone id
securityGroups List<String>
Security Group to define the security rules that determine the inbound and outbound traffic

Outputs

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

Id string
The provider-assigned unique ID for this managed resource.
Identifier string
Unique identifier of the resource
Id string
The provider-assigned unique ID for this managed resource.
Identifier string
Unique identifier of the resource
id String
The provider-assigned unique ID for this managed resource.
identifier String
Unique identifier of the resource
id string
The provider-assigned unique ID for this managed resource.
identifier string
Unique identifier of the resource
id str
The provider-assigned unique ID for this managed resource.
identifier str
Unique identifier of the resource
id String
The provider-assigned unique ID for this managed resource.
identifier String
Unique identifier of the resource

Look up Existing AwsProxy Resource

Get an existing AwsProxy 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?: AwsProxyState, opts?: CustomResourceOptions): AwsProxy
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        allocate_static_ip: Optional[bool] = None,
        api_key: Optional[str] = None,
        certificates: Optional[AwsProxyCertificatesArgs] = None,
        cloud_connector_id: Optional[str] = None,
        delete_cloud_resources_on_destroy: Optional[bool] = None,
        host_name: Optional[str] = None,
        identifier: Optional[str] = None,
        keypair: Optional[str] = None,
        machine_type: Optional[str] = None,
        name: Optional[str] = None,
        region: Optional[str] = None,
        route53_hosted_zone_id: Optional[str] = None,
        security_groups: Optional[Sequence[str]] = None,
        vpc: Optional[str] = None) -> AwsProxy
func GetAwsProxy(ctx *Context, name string, id IDInput, state *AwsProxyState, opts ...ResourceOption) (*AwsProxy, error)
public static AwsProxy Get(string name, Input<string> id, AwsProxyState? state, CustomResourceOptions? opts = null)
public static AwsProxy get(String name, Output<String> id, AwsProxyState state, CustomResourceOptions options)
resources:  _:    type: harness:autostopping:AwsProxy    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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:
AllocateStaticIp bool
Boolean value to indicate if proxy vm needs to have static IP
ApiKey string
Harness NG API key
Certificates AwsProxyCertificates
CloudConnectorId string
Id of the cloud connector
DeleteCloudResourcesOnDestroy bool
HostName string
Hostname for the proxy
Identifier string
Unique identifier of the resource
Keypair string
MachineType string
Machine instance type
Name string
Name of the proxy
Region string
Region in which cloud resources are hosted
Route53HostedZoneId string
Route 53 hosted zone id
SecurityGroups List<string>
Security Group to define the security rules that determine the inbound and outbound traffic
Vpc string
VPC in which cloud resources are hosted
AllocateStaticIp bool
Boolean value to indicate if proxy vm needs to have static IP
ApiKey string
Harness NG API key
Certificates AwsProxyCertificatesArgs
CloudConnectorId string
Id of the cloud connector
DeleteCloudResourcesOnDestroy bool
HostName string
Hostname for the proxy
Identifier string
Unique identifier of the resource
Keypair string
MachineType string
Machine instance type
Name string
Name of the proxy
Region string
Region in which cloud resources are hosted
Route53HostedZoneId string
Route 53 hosted zone id
SecurityGroups []string
Security Group to define the security rules that determine the inbound and outbound traffic
Vpc string
VPC in which cloud resources are hosted
allocateStaticIp Boolean
Boolean value to indicate if proxy vm needs to have static IP
apiKey String
Harness NG API key
certificates AwsProxyCertificates
cloudConnectorId String
Id of the cloud connector
deleteCloudResourcesOnDestroy Boolean
hostName String
Hostname for the proxy
identifier String
Unique identifier of the resource
keypair String
machineType String
Machine instance type
name String
Name of the proxy
region String
Region in which cloud resources are hosted
route53HostedZoneId String
Route 53 hosted zone id
securityGroups List<String>
Security Group to define the security rules that determine the inbound and outbound traffic
vpc String
VPC in which cloud resources are hosted
allocateStaticIp boolean
Boolean value to indicate if proxy vm needs to have static IP
apiKey string
Harness NG API key
certificates AwsProxyCertificates
cloudConnectorId string
Id of the cloud connector
deleteCloudResourcesOnDestroy boolean
hostName string
Hostname for the proxy
identifier string
Unique identifier of the resource
keypair string
machineType string
Machine instance type
name string
Name of the proxy
region string
Region in which cloud resources are hosted
route53HostedZoneId string
Route 53 hosted zone id
securityGroups string[]
Security Group to define the security rules that determine the inbound and outbound traffic
vpc string
VPC in which cloud resources are hosted
allocate_static_ip bool
Boolean value to indicate if proxy vm needs to have static IP
api_key str
Harness NG API key
certificates AwsProxyCertificatesArgs
cloud_connector_id str
Id of the cloud connector
delete_cloud_resources_on_destroy bool
host_name str
Hostname for the proxy
identifier str
Unique identifier of the resource
keypair str
machine_type str
Machine instance type
name str
Name of the proxy
region str
Region in which cloud resources are hosted
route53_hosted_zone_id str
Route 53 hosted zone id
security_groups Sequence[str]
Security Group to define the security rules that determine the inbound and outbound traffic
vpc str
VPC in which cloud resources are hosted
allocateStaticIp Boolean
Boolean value to indicate if proxy vm needs to have static IP
apiKey String
Harness NG API key
certificates Property Map
cloudConnectorId String
Id of the cloud connector
deleteCloudResourcesOnDestroy Boolean
hostName String
Hostname for the proxy
identifier String
Unique identifier of the resource
keypair String
machineType String
Machine instance type
name String
Name of the proxy
region String
Region in which cloud resources are hosted
route53HostedZoneId String
Route 53 hosted zone id
securityGroups List<String>
Security Group to define the security rules that determine the inbound and outbound traffic
vpc String
VPC in which cloud resources are hosted

Supporting Types

AwsProxyCertificates
, AwsProxyCertificatesArgs

CertSecretId This property is required. string
Certificate secret ID
KeySecretId This property is required. string
Private key secret ID
CertSecretId This property is required. string
Certificate secret ID
KeySecretId This property is required. string
Private key secret ID
certSecretId This property is required. String
Certificate secret ID
keySecretId This property is required. String
Private key secret ID
certSecretId This property is required. string
Certificate secret ID
keySecretId This property is required. string
Private key secret ID
cert_secret_id This property is required. str
Certificate secret ID
key_secret_id This property is required. str
Private key secret ID
certSecretId This property is required. String
Certificate secret ID
keySecretId This property is required. String
Private key secret ID

Package Details

Repository
harness pulumi/pulumi-harness
License
Apache-2.0
Notes
This Pulumi package is based on the harness Terraform Provider.