tencentcloud.CssLiveTranscodeRuleAttachment
Explore with Pulumi AI
Provides a resource to create a css live_transcode_rule_attachment
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const task = new tencentcloud.CssPullStreamTask("task", {
sourceType: "%s",
sourceUrls: ["%s"],
domainName: "%s",
appName: "%s",
streamName: "%s",
startTime: "%s",
endTime: "%s",
operator: "%s",
comment: "This is a demo.",
});
const temp = new tencentcloud.CssLiveTranscodeTemplate("temp", {
templateName: "xxx",
acodec: "aac",
videoBitrate: 100,
vcodec: "origin",
description: "This_is_a_tf_test_temp.",
needVideo: 1,
needAudio: 1,
});
const liveTranscodeRuleAttachment = new tencentcloud.CssLiveTranscodeRuleAttachment("liveTranscodeRuleAttachment", {
domainName: task.domainName,
appName: task.appName,
streamName: task.streamName,
templateId: temp.cssLiveTranscodeTemplateId,
});
import pulumi
import pulumi_tencentcloud as tencentcloud
task = tencentcloud.CssPullStreamTask("task",
source_type="%s",
source_urls=["%s"],
domain_name="%s",
app_name="%s",
stream_name="%s",
start_time="%s",
end_time="%s",
operator="%s",
comment="This is a demo.")
temp = tencentcloud.CssLiveTranscodeTemplate("temp",
template_name="xxx",
acodec="aac",
video_bitrate=100,
vcodec="origin",
description="This_is_a_tf_test_temp.",
need_video=1,
need_audio=1)
live_transcode_rule_attachment = tencentcloud.CssLiveTranscodeRuleAttachment("liveTranscodeRuleAttachment",
domain_name=task.domain_name,
app_name=task.app_name,
stream_name=task.stream_name,
template_id=temp.css_live_transcode_template_id)
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
task, err := tencentcloud.NewCssPullStreamTask(ctx, "task", &tencentcloud.CssPullStreamTaskArgs{
SourceType: pulumi.String("%s"),
SourceUrls: pulumi.StringArray{
pulumi.String("%s"),
},
DomainName: pulumi.String("%s"),
AppName: pulumi.String("%s"),
StreamName: pulumi.String("%s"),
StartTime: pulumi.String("%s"),
EndTime: pulumi.String("%s"),
Operator: pulumi.String("%s"),
Comment: pulumi.String("This is a demo."),
})
if err != nil {
return err
}
temp, err := tencentcloud.NewCssLiveTranscodeTemplate(ctx, "temp", &tencentcloud.CssLiveTranscodeTemplateArgs{
TemplateName: pulumi.String("xxx"),
Acodec: pulumi.String("aac"),
VideoBitrate: pulumi.Float64(100),
Vcodec: pulumi.String("origin"),
Description: pulumi.String("This_is_a_tf_test_temp."),
NeedVideo: pulumi.Float64(1),
NeedAudio: pulumi.Float64(1),
})
if err != nil {
return err
}
_, err = tencentcloud.NewCssLiveTranscodeRuleAttachment(ctx, "liveTranscodeRuleAttachment", &tencentcloud.CssLiveTranscodeRuleAttachmentArgs{
DomainName: task.DomainName,
AppName: task.AppName,
StreamName: task.StreamName,
TemplateId: temp.CssLiveTranscodeTemplateId,
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Tencentcloud = Pulumi.Tencentcloud;
return await Deployment.RunAsync(() =>
{
var task = new Tencentcloud.CssPullStreamTask("task", new()
{
SourceType = "%s",
SourceUrls = new[]
{
"%s",
},
DomainName = "%s",
AppName = "%s",
StreamName = "%s",
StartTime = "%s",
EndTime = "%s",
Operator = "%s",
Comment = "This is a demo.",
});
var temp = new Tencentcloud.CssLiveTranscodeTemplate("temp", new()
{
TemplateName = "xxx",
Acodec = "aac",
VideoBitrate = 100,
Vcodec = "origin",
Description = "This_is_a_tf_test_temp.",
NeedVideo = 1,
NeedAudio = 1,
});
var liveTranscodeRuleAttachment = new Tencentcloud.CssLiveTranscodeRuleAttachment("liveTranscodeRuleAttachment", new()
{
DomainName = task.DomainName,
AppName = task.AppName,
StreamName = task.StreamName,
TemplateId = temp.CssLiveTranscodeTemplateId,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.CssPullStreamTask;
import com.pulumi.tencentcloud.CssPullStreamTaskArgs;
import com.pulumi.tencentcloud.CssLiveTranscodeTemplate;
import com.pulumi.tencentcloud.CssLiveTranscodeTemplateArgs;
import com.pulumi.tencentcloud.CssLiveTranscodeRuleAttachment;
import com.pulumi.tencentcloud.CssLiveTranscodeRuleAttachmentArgs;
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 task = new CssPullStreamTask("task", CssPullStreamTaskArgs.builder()
.sourceType("%s")
.sourceUrls("%s")
.domainName("%s")
.appName("%s")
.streamName("%s")
.startTime("%s")
.endTime("%s")
.operator("%s")
.comment("This is a demo.")
.build());
var temp = new CssLiveTranscodeTemplate("temp", CssLiveTranscodeTemplateArgs.builder()
.templateName("xxx")
.acodec("aac")
.videoBitrate(100)
.vcodec("origin")
.description("This_is_a_tf_test_temp.")
.needVideo(1)
.needAudio(1)
.build());
var liveTranscodeRuleAttachment = new CssLiveTranscodeRuleAttachment("liveTranscodeRuleAttachment", CssLiveTranscodeRuleAttachmentArgs.builder()
.domainName(task.domainName())
.appName(task.appName())
.streamName(task.streamName())
.templateId(temp.cssLiveTranscodeTemplateId())
.build());
}
}
resources:
task:
type: tencentcloud:CssPullStreamTask
properties:
sourceType: '%s'
sourceUrls:
- '%s'
domainName: '%s'
appName: '%s'
streamName: '%s'
startTime: '%s'
endTime: '%s'
operator: '%s'
comment: This is a demo.
temp:
type: tencentcloud:CssLiveTranscodeTemplate
properties:
templateName: xxx
acodec: aac
videoBitrate: 100
vcodec: origin
description: This_is_a_tf_test_temp.
needVideo: 1
needAudio: 1
liveTranscodeRuleAttachment:
type: tencentcloud:CssLiveTranscodeRuleAttachment
properties:
domainName: ${task.domainName}
appName: ${task.appName}
streamName: ${task.streamName}
templateId: ${temp.cssLiveTranscodeTemplateId}
Create CssLiveTranscodeRuleAttachment Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new CssLiveTranscodeRuleAttachment(name: string, args: CssLiveTranscodeRuleAttachmentArgs, opts?: CustomResourceOptions);
@overload
def CssLiveTranscodeRuleAttachment(resource_name: str,
args: CssLiveTranscodeRuleAttachmentArgs,
opts: Optional[ResourceOptions] = None)
@overload
def CssLiveTranscodeRuleAttachment(resource_name: str,
opts: Optional[ResourceOptions] = None,
app_name: Optional[str] = None,
domain_name: Optional[str] = None,
stream_name: Optional[str] = None,
template_id: Optional[float] = None,
css_live_transcode_rule_attachment_id: Optional[str] = None)
func NewCssLiveTranscodeRuleAttachment(ctx *Context, name string, args CssLiveTranscodeRuleAttachmentArgs, opts ...ResourceOption) (*CssLiveTranscodeRuleAttachment, error)
public CssLiveTranscodeRuleAttachment(string name, CssLiveTranscodeRuleAttachmentArgs args, CustomResourceOptions? opts = null)
public CssLiveTranscodeRuleAttachment(String name, CssLiveTranscodeRuleAttachmentArgs args)
public CssLiveTranscodeRuleAttachment(String name, CssLiveTranscodeRuleAttachmentArgs args, CustomResourceOptions options)
type: tencentcloud:CssLiveTranscodeRuleAttachment
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 CssLiveTranscodeRuleAttachmentArgs
- 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 CssLiveTranscodeRuleAttachmentArgs
- 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 CssLiveTranscodeRuleAttachmentArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args CssLiveTranscodeRuleAttachmentArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args CssLiveTranscodeRuleAttachmentArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
CssLiveTranscodeRuleAttachment 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 CssLiveTranscodeRuleAttachment resource accepts the following input properties:
- App
Name string - app name which you want to bind, can be empty string if not binding specific app name.
- Domain
Name string - domain name hich you want to bind the transcode template.
- Stream
Name string - stream name which you want to bind, can be empty string if not binding specific stream.
- Template
Id double - template created by css_live_transcode_template.
- Css
Live stringTranscode Rule Attachment Id - ID of the resource.
- App
Name string - app name which you want to bind, can be empty string if not binding specific app name.
- Domain
Name string - domain name hich you want to bind the transcode template.
- Stream
Name string - stream name which you want to bind, can be empty string if not binding specific stream.
- Template
Id float64 - template created by css_live_transcode_template.
- Css
Live stringTranscode Rule Attachment Id - ID of the resource.
- app
Name String - app name which you want to bind, can be empty string if not binding specific app name.
- domain
Name String - domain name hich you want to bind the transcode template.
- stream
Name String - stream name which you want to bind, can be empty string if not binding specific stream.
- template
Id Double - template created by css_live_transcode_template.
- css
Live StringTranscode Rule Attachment Id - ID of the resource.
- app
Name string - app name which you want to bind, can be empty string if not binding specific app name.
- domain
Name string - domain name hich you want to bind the transcode template.
- stream
Name string - stream name which you want to bind, can be empty string if not binding specific stream.
- template
Id number - template created by css_live_transcode_template.
- css
Live stringTranscode Rule Attachment Id - ID of the resource.
- app_
name str - app name which you want to bind, can be empty string if not binding specific app name.
- domain_
name str - domain name hich you want to bind the transcode template.
- stream_
name str - stream name which you want to bind, can be empty string if not binding specific stream.
- template_
id float - template created by css_live_transcode_template.
- css_
live_ strtranscode_ rule_ attachment_ id - ID of the resource.
- app
Name String - app name which you want to bind, can be empty string if not binding specific app name.
- domain
Name String - domain name hich you want to bind the transcode template.
- stream
Name String - stream name which you want to bind, can be empty string if not binding specific stream.
- template
Id Number - template created by css_live_transcode_template.
- css
Live StringTranscode Rule Attachment Id - ID of the resource.
Outputs
All input properties are implicitly available as output properties. Additionally, the CssLiveTranscodeRuleAttachment resource produces the following output properties:
- Create
Time string - create time.
- Id string
- The provider-assigned unique ID for this managed resource.
- Update
Time string - update time.
- Create
Time string - create time.
- Id string
- The provider-assigned unique ID for this managed resource.
- Update
Time string - update time.
- create
Time String - create time.
- id String
- The provider-assigned unique ID for this managed resource.
- update
Time String - update time.
- create
Time string - create time.
- id string
- The provider-assigned unique ID for this managed resource.
- update
Time string - update time.
- create_
time str - create time.
- id str
- The provider-assigned unique ID for this managed resource.
- update_
time str - update time.
- create
Time String - create time.
- id String
- The provider-assigned unique ID for this managed resource.
- update
Time String - update time.
Look up Existing CssLiveTranscodeRuleAttachment Resource
Get an existing CssLiveTranscodeRuleAttachment 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?: CssLiveTranscodeRuleAttachmentState, opts?: CustomResourceOptions): CssLiveTranscodeRuleAttachment
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
app_name: Optional[str] = None,
create_time: Optional[str] = None,
css_live_transcode_rule_attachment_id: Optional[str] = None,
domain_name: Optional[str] = None,
stream_name: Optional[str] = None,
template_id: Optional[float] = None,
update_time: Optional[str] = None) -> CssLiveTranscodeRuleAttachment
func GetCssLiveTranscodeRuleAttachment(ctx *Context, name string, id IDInput, state *CssLiveTranscodeRuleAttachmentState, opts ...ResourceOption) (*CssLiveTranscodeRuleAttachment, error)
public static CssLiveTranscodeRuleAttachment Get(string name, Input<string> id, CssLiveTranscodeRuleAttachmentState? state, CustomResourceOptions? opts = null)
public static CssLiveTranscodeRuleAttachment get(String name, Output<String> id, CssLiveTranscodeRuleAttachmentState state, CustomResourceOptions options)
resources: _: type: tencentcloud:CssLiveTranscodeRuleAttachment get: id: ${id}
- 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.
- App
Name string - app name which you want to bind, can be empty string if not binding specific app name.
- Create
Time string - create time.
- Css
Live stringTranscode Rule Attachment Id - ID of the resource.
- Domain
Name string - domain name hich you want to bind the transcode template.
- Stream
Name string - stream name which you want to bind, can be empty string if not binding specific stream.
- Template
Id double - template created by css_live_transcode_template.
- Update
Time string - update time.
- App
Name string - app name which you want to bind, can be empty string if not binding specific app name.
- Create
Time string - create time.
- Css
Live stringTranscode Rule Attachment Id - ID of the resource.
- Domain
Name string - domain name hich you want to bind the transcode template.
- Stream
Name string - stream name which you want to bind, can be empty string if not binding specific stream.
- Template
Id float64 - template created by css_live_transcode_template.
- Update
Time string - update time.
- app
Name String - app name which you want to bind, can be empty string if not binding specific app name.
- create
Time String - create time.
- css
Live StringTranscode Rule Attachment Id - ID of the resource.
- domain
Name String - domain name hich you want to bind the transcode template.
- stream
Name String - stream name which you want to bind, can be empty string if not binding specific stream.
- template
Id Double - template created by css_live_transcode_template.
- update
Time String - update time.
- app
Name string - app name which you want to bind, can be empty string if not binding specific app name.
- create
Time string - create time.
- css
Live stringTranscode Rule Attachment Id - ID of the resource.
- domain
Name string - domain name hich you want to bind the transcode template.
- stream
Name string - stream name which you want to bind, can be empty string if not binding specific stream.
- template
Id number - template created by css_live_transcode_template.
- update
Time string - update time.
- app_
name str - app name which you want to bind, can be empty string if not binding specific app name.
- create_
time str - create time.
- css_
live_ strtranscode_ rule_ attachment_ id - ID of the resource.
- domain_
name str - domain name hich you want to bind the transcode template.
- stream_
name str - stream name which you want to bind, can be empty string if not binding specific stream.
- template_
id float - template created by css_live_transcode_template.
- update_
time str - update time.
- app
Name String - app name which you want to bind, can be empty string if not binding specific app name.
- create
Time String - create time.
- css
Live StringTranscode Rule Attachment Id - ID of the resource.
- domain
Name String - domain name hich you want to bind the transcode template.
- stream
Name String - stream name which you want to bind, can be empty string if not binding specific stream.
- template
Id Number - template created by css_live_transcode_template.
- update
Time String - update time.
Import
css live_transcode_rule_attachment can be imported using the id, e.g.
$ pulumi import tencentcloud:index/cssLiveTranscodeRuleAttachment:CssLiveTranscodeRuleAttachment live_transcode_rule_attachment liveTranscodeRuleAttachment_id
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- tencentcloud tencentcloudstack/terraform-provider-tencentcloud
- License
- Notes
- This Pulumi package is based on the
tencentcloud
Terraform Provider.