checkpoint.ManagementPutFile
Explore with Pulumi AI
This command resource allows you to execute Check Point Put File.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as checkpoint from "@pulumi/checkpoint";
const putFile = new checkpoint.ManagementPutFile("putFile", {
fileContent: `first line
second line
`,
fileName: "myfile.txt",
filePath: "/home/admin/",
targets: ["corporate-gateway"],
});
import pulumi
import pulumi_checkpoint as checkpoint
put_file = checkpoint.ManagementPutFile("putFile",
file_content="""first line
second line
""",
file_name="myfile.txt",
file_path="/home/admin/",
targets=["corporate-gateway"])
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/checkpoint/v2/checkpoint"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := checkpoint.NewManagementPutFile(ctx, "putFile", &checkpoint.ManagementPutFileArgs{
FileContent: pulumi.String("first line\n second line\n"),
FileName: pulumi.String("myfile.txt"),
FilePath: pulumi.String("/home/admin/"),
Targets: pulumi.StringArray{
pulumi.String("corporate-gateway"),
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Checkpoint = Pulumi.Checkpoint;
return await Deployment.RunAsync(() =>
{
var putFile = new Checkpoint.ManagementPutFile("putFile", new()
{
FileContent = @"first line
second line
",
FileName = "myfile.txt",
FilePath = "/home/admin/",
Targets = new[]
{
"corporate-gateway",
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.checkpoint.ManagementPutFile;
import com.pulumi.checkpoint.ManagementPutFileArgs;
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 putFile = new ManagementPutFile("putFile", ManagementPutFileArgs.builder()
.fileContent("""
first line
second line
""")
.fileName("myfile.txt")
.filePath("/home/admin/")
.targets("corporate-gateway")
.build());
}
}
resources:
putFile:
type: checkpoint:ManagementPutFile
properties:
fileContent: |
first line
second line
fileName: myfile.txt
filePath: /home/admin/
targets:
- corporate-gateway
How To Use
Make sure this command will be executed in the right execution order.
Create ManagementPutFile Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ManagementPutFile(name: string, args: ManagementPutFileArgs, opts?: CustomResourceOptions);
@overload
def ManagementPutFile(resource_name: str,
args: ManagementPutFileArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ManagementPutFile(resource_name: str,
opts: Optional[ResourceOptions] = None,
targets: Optional[Sequence[str]] = None,
comments: Optional[str] = None,
file_content: Optional[str] = None,
file_name: Optional[str] = None,
file_path: Optional[str] = None,
management_put_file_id: Optional[str] = None)
func NewManagementPutFile(ctx *Context, name string, args ManagementPutFileArgs, opts ...ResourceOption) (*ManagementPutFile, error)
public ManagementPutFile(string name, ManagementPutFileArgs args, CustomResourceOptions? opts = null)
public ManagementPutFile(String name, ManagementPutFileArgs args)
public ManagementPutFile(String name, ManagementPutFileArgs args, CustomResourceOptions options)
type: checkpoint:ManagementPutFile
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 ManagementPutFileArgs
- 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 ManagementPutFileArgs
- 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 ManagementPutFileArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ManagementPutFileArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ManagementPutFileArgs
- 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 managementPutFileResource = new Checkpoint.ManagementPutFile("managementPutFileResource", new()
{
Targets = new[]
{
"string",
},
Comments = "string",
FileContent = "string",
FileName = "string",
FilePath = "string",
ManagementPutFileId = "string",
});
example, err := checkpoint.NewManagementPutFile(ctx, "managementPutFileResource", &checkpoint.ManagementPutFileArgs{
Targets: pulumi.StringArray{
pulumi.String("string"),
},
Comments: pulumi.String("string"),
FileContent: pulumi.String("string"),
FileName: pulumi.String("string"),
FilePath: pulumi.String("string"),
ManagementPutFileId: pulumi.String("string"),
})
var managementPutFileResource = new ManagementPutFile("managementPutFileResource", ManagementPutFileArgs.builder()
.targets("string")
.comments("string")
.fileContent("string")
.fileName("string")
.filePath("string")
.managementPutFileId("string")
.build());
management_put_file_resource = checkpoint.ManagementPutFile("managementPutFileResource",
targets=["string"],
comments="string",
file_content="string",
file_name="string",
file_path="string",
management_put_file_id="string")
const managementPutFileResource = new checkpoint.ManagementPutFile("managementPutFileResource", {
targets: ["string"],
comments: "string",
fileContent: "string",
fileName: "string",
filePath: "string",
managementPutFileId: "string",
});
type: checkpoint:ManagementPutFile
properties:
comments: string
fileContent: string
fileName: string
filePath: string
managementPutFileId: string
targets:
- string
ManagementPutFile 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 ManagementPutFile resource accepts the following input properties:
- Targets List<string>
- On what targets to execute this command. Targets may be identified by their name, or object unique identifier.targets blocks are documented below.
- Comments string
- Comments string.
- File
Content string - Text file content.
- File
Name string - Text file name.
- File
Path string - Text file target path.
- Management
Put stringFile Id
- Targets []string
- On what targets to execute this command. Targets may be identified by their name, or object unique identifier.targets blocks are documented below.
- Comments string
- Comments string.
- File
Content string - Text file content.
- File
Name string - Text file name.
- File
Path string - Text file target path.
- Management
Put stringFile Id
- targets List<String>
- On what targets to execute this command. Targets may be identified by their name, or object unique identifier.targets blocks are documented below.
- comments String
- Comments string.
- file
Content String - Text file content.
- file
Name String - Text file name.
- file
Path String - Text file target path.
- management
Put StringFile Id
- targets string[]
- On what targets to execute this command. Targets may be identified by their name, or object unique identifier.targets blocks are documented below.
- comments string
- Comments string.
- file
Content string - Text file content.
- file
Name string - Text file name.
- file
Path string - Text file target path.
- management
Put stringFile Id
- targets Sequence[str]
- On what targets to execute this command. Targets may be identified by their name, or object unique identifier.targets blocks are documented below.
- comments str
- Comments string.
- file_
content str - Text file content.
- file_
name str - Text file name.
- file_
path str - Text file target path.
- management_
put_ strfile_ id
- targets List<String>
- On what targets to execute this command. Targets may be identified by their name, or object unique identifier.targets blocks are documented below.
- comments String
- Comments string.
- file
Content String - Text file content.
- file
Name String - Text file name.
- file
Path String - Text file target path.
- management
Put StringFile Id
Outputs
All input properties are implicitly available as output properties. Additionally, the ManagementPutFile resource produces the following output properties:
Look up Existing ManagementPutFile Resource
Get an existing ManagementPutFile 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?: ManagementPutFileState, opts?: CustomResourceOptions): ManagementPutFile
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
comments: Optional[str] = None,
file_content: Optional[str] = None,
file_name: Optional[str] = None,
file_path: Optional[str] = None,
management_put_file_id: Optional[str] = None,
targets: Optional[Sequence[str]] = None,
tasks: Optional[Sequence[str]] = None) -> ManagementPutFile
func GetManagementPutFile(ctx *Context, name string, id IDInput, state *ManagementPutFileState, opts ...ResourceOption) (*ManagementPutFile, error)
public static ManagementPutFile Get(string name, Input<string> id, ManagementPutFileState? state, CustomResourceOptions? opts = null)
public static ManagementPutFile get(String name, Output<String> id, ManagementPutFileState state, CustomResourceOptions options)
resources: _: type: checkpoint:ManagementPutFile 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.
- Comments string
- Comments string.
- File
Content string - Text file content.
- File
Name string - Text file name.
- File
Path string - Text file target path.
- Management
Put stringFile Id - Targets List<string>
- On what targets to execute this command. Targets may be identified by their name, or object unique identifier.targets blocks are documented below.
- Tasks List<string>
- Collection of asynchronous task unique identifiers.
- Comments string
- Comments string.
- File
Content string - Text file content.
- File
Name string - Text file name.
- File
Path string - Text file target path.
- Management
Put stringFile Id - Targets []string
- On what targets to execute this command. Targets may be identified by their name, or object unique identifier.targets blocks are documented below.
- Tasks []string
- Collection of asynchronous task unique identifiers.
- comments String
- Comments string.
- file
Content String - Text file content.
- file
Name String - Text file name.
- file
Path String - Text file target path.
- management
Put StringFile Id - targets List<String>
- On what targets to execute this command. Targets may be identified by their name, or object unique identifier.targets blocks are documented below.
- tasks List<String>
- Collection of asynchronous task unique identifiers.
- comments string
- Comments string.
- file
Content string - Text file content.
- file
Name string - Text file name.
- file
Path string - Text file target path.
- management
Put stringFile Id - targets string[]
- On what targets to execute this command. Targets may be identified by their name, or object unique identifier.targets blocks are documented below.
- tasks string[]
- Collection of asynchronous task unique identifiers.
- comments str
- Comments string.
- file_
content str - Text file content.
- file_
name str - Text file name.
- file_
path str - Text file target path.
- management_
put_ strfile_ id - targets Sequence[str]
- On what targets to execute this command. Targets may be identified by their name, or object unique identifier.targets blocks are documented below.
- tasks Sequence[str]
- Collection of asynchronous task unique identifiers.
- comments String
- Comments string.
- file
Content String - Text file content.
- file
Name String - Text file name.
- file
Path String - Text file target path.
- management
Put StringFile Id - targets List<String>
- On what targets to execute this command. Targets may be identified by their name, or object unique identifier.targets blocks are documented below.
- tasks List<String>
- Collection of asynchronous task unique identifiers.
Package Details
- Repository
- checkpoint checkpointsw/terraform-provider-checkpoint
- License
- Notes
- This Pulumi package is based on the
checkpoint
Terraform Provider.