dnsimple.EmailForward
Explore with Pulumi AI
Provides a DNSimple email forward resource.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as dnsimple from "@pulumi/dnsimple";
const foobar = new dnsimple.EmailForward("foobar", {
domain: dnsimpleDomain.name,
aliasName: "sales",
destinationEmail: "alice.appleseed@example.com",
});
import pulumi
import pulumi_dnsimple as dnsimple
foobar = dnsimple.EmailForward("foobar",
domain=dnsimple_domain["name"],
alias_name="sales",
destination_email="alice.appleseed@example.com")
package main
import (
"github.com/pulumi/pulumi-dnsimple/sdk/v4/go/dnsimple"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := dnsimple.NewEmailForward(ctx, "foobar", &dnsimple.EmailForwardArgs{
Domain: pulumi.Any(dnsimpleDomain.Name),
AliasName: pulumi.String("sales"),
DestinationEmail: pulumi.String("alice.appleseed@example.com"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using DNSimple = Pulumi.DNSimple;
return await Deployment.RunAsync(() =>
{
var foobar = new DNSimple.EmailForward("foobar", new()
{
Domain = dnsimpleDomain.Name,
AliasName = "sales",
DestinationEmail = "alice.appleseed@example.com",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.dnsimple.EmailForward;
import com.pulumi.dnsimple.EmailForwardArgs;
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 foobar = new EmailForward("foobar", EmailForwardArgs.builder()
.domain(dnsimpleDomain.name())
.aliasName("sales")
.destinationEmail("alice.appleseed@example.com")
.build());
}
}
resources:
foobar:
type: dnsimple:EmailForward
properties:
domain: ${dnsimpleDomain.name}
aliasName: sales
destinationEmail: alice.appleseed@example.com
Create EmailForward Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new EmailForward(name: string, args: EmailForwardArgs, opts?: CustomResourceOptions);
@overload
def EmailForward(resource_name: str,
args: EmailForwardArgs,
opts: Optional[ResourceOptions] = None)
@overload
def EmailForward(resource_name: str,
opts: Optional[ResourceOptions] = None,
alias_name: Optional[str] = None,
destination_email: Optional[str] = None,
domain: Optional[str] = None)
func NewEmailForward(ctx *Context, name string, args EmailForwardArgs, opts ...ResourceOption) (*EmailForward, error)
public EmailForward(string name, EmailForwardArgs args, CustomResourceOptions? opts = null)
public EmailForward(String name, EmailForwardArgs args)
public EmailForward(String name, EmailForwardArgs args, CustomResourceOptions options)
type: dnsimple:EmailForward
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 EmailForwardArgs
- 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 EmailForwardArgs
- 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 EmailForwardArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args EmailForwardArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args EmailForwardArgs
- 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 emailForwardResource = new DNSimple.EmailForward("emailForwardResource", new()
{
AliasName = "string",
DestinationEmail = "string",
Domain = "string",
});
example, err := dnsimple.NewEmailForward(ctx, "emailForwardResource", &dnsimple.EmailForwardArgs{
AliasName: pulumi.String("string"),
DestinationEmail: pulumi.String("string"),
Domain: pulumi.String("string"),
})
var emailForwardResource = new EmailForward("emailForwardResource", EmailForwardArgs.builder()
.aliasName("string")
.destinationEmail("string")
.domain("string")
.build());
email_forward_resource = dnsimple.EmailForward("emailForwardResource",
alias_name="string",
destination_email="string",
domain="string")
const emailForwardResource = new dnsimple.EmailForward("emailForwardResource", {
aliasName: "string",
destinationEmail: "string",
domain: "string",
});
type: dnsimple:EmailForward
properties:
aliasName: string
destinationEmail: string
domain: string
EmailForward 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 EmailForward resource accepts the following input properties:
- Alias
Name string - The name part (the part before the @) of the source email address on the domain
- Destination
Email string - The destination email address
- Domain string
- The domain name to add the email forwarding rule to
- Alias
Name string - The name part (the part before the @) of the source email address on the domain
- Destination
Email string - The destination email address
- Domain string
- The domain name to add the email forwarding rule to
- alias
Name String - The name part (the part before the @) of the source email address on the domain
- destination
Email String - The destination email address
- domain String
- The domain name to add the email forwarding rule to
- alias
Name string - The name part (the part before the @) of the source email address on the domain
- destination
Email string - The destination email address
- domain string
- The domain name to add the email forwarding rule to
- alias_
name str - The name part (the part before the @) of the source email address on the domain
- destination_
email str - The destination email address
- domain str
- The domain name to add the email forwarding rule to
- alias
Name String - The name part (the part before the @) of the source email address on the domain
- destination
Email String - The destination email address
- domain String
- The domain name to add the email forwarding rule to
Outputs
All input properties are implicitly available as output properties. Additionally, the EmailForward resource produces the following output properties:
- Alias
Email string - The source email address on the domain, in full form. This is a computed attribute.
- Id string
- The provider-assigned unique ID for this managed resource.
- Alias
Email string - The source email address on the domain, in full form. This is a computed attribute.
- Id string
- The provider-assigned unique ID for this managed resource.
- alias
Email String - The source email address on the domain, in full form. This is a computed attribute.
- id String
- The provider-assigned unique ID for this managed resource.
- alias
Email string - The source email address on the domain, in full form. This is a computed attribute.
- id string
- The provider-assigned unique ID for this managed resource.
- alias_
email str - The source email address on the domain, in full form. This is a computed attribute.
- id str
- The provider-assigned unique ID for this managed resource.
- alias
Email String - The source email address on the domain, in full form. This is a computed attribute.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing EmailForward Resource
Get an existing EmailForward 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?: EmailForwardState, opts?: CustomResourceOptions): EmailForward
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
alias_email: Optional[str] = None,
alias_name: Optional[str] = None,
destination_email: Optional[str] = None,
domain: Optional[str] = None) -> EmailForward
func GetEmailForward(ctx *Context, name string, id IDInput, state *EmailForwardState, opts ...ResourceOption) (*EmailForward, error)
public static EmailForward Get(string name, Input<string> id, EmailForwardState? state, CustomResourceOptions? opts = null)
public static EmailForward get(String name, Output<String> id, EmailForwardState 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.
- Alias
Email string - The source email address on the domain, in full form. This is a computed attribute.
- Alias
Name string - The name part (the part before the @) of the source email address on the domain
- Destination
Email string - The destination email address
- Domain string
- The domain name to add the email forwarding rule to
- Alias
Email string - The source email address on the domain, in full form. This is a computed attribute.
- Alias
Name string - The name part (the part before the @) of the source email address on the domain
- Destination
Email string - The destination email address
- Domain string
- The domain name to add the email forwarding rule to
- alias
Email String - The source email address on the domain, in full form. This is a computed attribute.
- alias
Name String - The name part (the part before the @) of the source email address on the domain
- destination
Email String - The destination email address
- domain String
- The domain name to add the email forwarding rule to
- alias
Email string - The source email address on the domain, in full form. This is a computed attribute.
- alias
Name string - The name part (the part before the @) of the source email address on the domain
- destination
Email string - The destination email address
- domain string
- The domain name to add the email forwarding rule to
- alias_
email str - The source email address on the domain, in full form. This is a computed attribute.
- alias_
name str - The name part (the part before the @) of the source email address on the domain
- destination_
email str - The destination email address
- domain str
- The domain name to add the email forwarding rule to
- alias
Email String - The source email address on the domain, in full form. This is a computed attribute.
- alias
Name String - The name part (the part before the @) of the source email address on the domain
- destination
Email String - The destination email address
- domain String
- The domain name to add the email forwarding rule to
Import
DNSimple resources can be imported using the domain name and numeric email forward ID.
Importing email forward for example.com with email forward ID 1234
bash
$ pulumi import dnsimple:index/emailForward:EmailForward resource_name example.com_1234
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- DNSimple pulumi/pulumi-dnsimple
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
dnsimple
Terraform Provider.