1. Packages
  2. Routeros Provider
  3. API Docs
  4. SystemUserSshkeys
routeros 1.83.1 published on Monday, Apr 28, 2025 by terraform-routeros

routeros.SystemUserSshkeys

Explore with Pulumi AI

routeros logo
routeros 1.83.1 published on Monday, Apr 28, 2025 by terraform-routeros

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as routeros from "@pulumi/routeros";
    
    const test = new routeros.SystemUserSshkeys("test", {
        comment: "Test User",
        key: "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCyJ1EvW98veNVzR3VamNgmu0xOd/JK9YNvP/pa4WC5eT90UbX4TN7dKEK/x2FCwnnG9u0FQhzG2qa/Cg8meUvlfydn6uxc0/WCeXTKSu6sT63noPO6m4fHY7gu3Zt+fOc/WYGch9sBeWjZlCS1mA2lajkWhM3J8TFWCFm2Zk4/S3s5mt6VLbwpQnH2LhE41+azzDEVhcR6i3FfdgOF/J+j2fYYHJsBEKoQA5zUac2zWmz7X4Rv/g11ZBRqdMpHSD58o5F9lBb13antu5GcEs5RXpXp08OyXuRV9qhFpDBC8DOMALSOgT3vnu8uJLgo8QIulERofj/cRXbLCsmvMbpioBuGFXWx3ha4Ntd6z07kUh2KVbaIQLd/629UHNvgIhoBLlREJ8E5vllsX+jh8hRITHcCiEwXcDO+gG3hvJt0+jm8S8SObE/IHk8VuwWdhIsSku5vd+wVlxm8VeJzjc0cjdIiytvsq8VpLudKEUiqR0f2tHcoq8H+xcJv3Ycu1i8=",
        user: "test-user-1",
    });
    
    import pulumi
    import pulumi_routeros as routeros
    
    test = routeros.SystemUserSshkeys("test",
        comment="Test User",
        key="ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCyJ1EvW98veNVzR3VamNgmu0xOd/JK9YNvP/pa4WC5eT90UbX4TN7dKEK/x2FCwnnG9u0FQhzG2qa/Cg8meUvlfydn6uxc0/WCeXTKSu6sT63noPO6m4fHY7gu3Zt+fOc/WYGch9sBeWjZlCS1mA2lajkWhM3J8TFWCFm2Zk4/S3s5mt6VLbwpQnH2LhE41+azzDEVhcR6i3FfdgOF/J+j2fYYHJsBEKoQA5zUac2zWmz7X4Rv/g11ZBRqdMpHSD58o5F9lBb13antu5GcEs5RXpXp08OyXuRV9qhFpDBC8DOMALSOgT3vnu8uJLgo8QIulERofj/cRXbLCsmvMbpioBuGFXWx3ha4Ntd6z07kUh2KVbaIQLd/629UHNvgIhoBLlREJ8E5vllsX+jh8hRITHcCiEwXcDO+gG3hvJt0+jm8S8SObE/IHk8VuwWdhIsSku5vd+wVlxm8VeJzjc0cjdIiytvsq8VpLudKEUiqR0f2tHcoq8H+xcJv3Ycu1i8=",
        user="test-user-1")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/routeros/routeros"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := routeros.NewSystemUserSshkeys(ctx, "test", &routeros.SystemUserSshkeysArgs{
    			Comment: pulumi.String("Test User"),
    			Key:     pulumi.String("ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCyJ1EvW98veNVzR3VamNgmu0xOd/JK9YNvP/pa4WC5eT90UbX4TN7dKEK/x2FCwnnG9u0FQhzG2qa/Cg8meUvlfydn6uxc0/WCeXTKSu6sT63noPO6m4fHY7gu3Zt+fOc/WYGch9sBeWjZlCS1mA2lajkWhM3J8TFWCFm2Zk4/S3s5mt6VLbwpQnH2LhE41+azzDEVhcR6i3FfdgOF/J+j2fYYHJsBEKoQA5zUac2zWmz7X4Rv/g11ZBRqdMpHSD58o5F9lBb13antu5GcEs5RXpXp08OyXuRV9qhFpDBC8DOMALSOgT3vnu8uJLgo8QIulERofj/cRXbLCsmvMbpioBuGFXWx3ha4Ntd6z07kUh2KVbaIQLd/629UHNvgIhoBLlREJ8E5vllsX+jh8hRITHcCiEwXcDO+gG3hvJt0+jm8S8SObE/IHk8VuwWdhIsSku5vd+wVlxm8VeJzjc0cjdIiytvsq8VpLudKEUiqR0f2tHcoq8H+xcJv3Ycu1i8="),
    			User:    pulumi.String("test-user-1"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Routeros = Pulumi.Routeros;
    
    return await Deployment.RunAsync(() => 
    {
        var test = new Routeros.SystemUserSshkeys("test", new()
        {
            Comment = "Test User",
            Key = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCyJ1EvW98veNVzR3VamNgmu0xOd/JK9YNvP/pa4WC5eT90UbX4TN7dKEK/x2FCwnnG9u0FQhzG2qa/Cg8meUvlfydn6uxc0/WCeXTKSu6sT63noPO6m4fHY7gu3Zt+fOc/WYGch9sBeWjZlCS1mA2lajkWhM3J8TFWCFm2Zk4/S3s5mt6VLbwpQnH2LhE41+azzDEVhcR6i3FfdgOF/J+j2fYYHJsBEKoQA5zUac2zWmz7X4Rv/g11ZBRqdMpHSD58o5F9lBb13antu5GcEs5RXpXp08OyXuRV9qhFpDBC8DOMALSOgT3vnu8uJLgo8QIulERofj/cRXbLCsmvMbpioBuGFXWx3ha4Ntd6z07kUh2KVbaIQLd/629UHNvgIhoBLlREJ8E5vllsX+jh8hRITHcCiEwXcDO+gG3hvJt0+jm8S8SObE/IHk8VuwWdhIsSku5vd+wVlxm8VeJzjc0cjdIiytvsq8VpLudKEUiqR0f2tHcoq8H+xcJv3Ycu1i8=",
            User = "test-user-1",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.routeros.SystemUserSshkeys;
    import com.pulumi.routeros.SystemUserSshkeysArgs;
    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 SystemUserSshkeys("test", SystemUserSshkeysArgs.builder()
                .comment("Test User")
                .key("ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCyJ1EvW98veNVzR3VamNgmu0xOd/JK9YNvP/pa4WC5eT90UbX4TN7dKEK/x2FCwnnG9u0FQhzG2qa/Cg8meUvlfydn6uxc0/WCeXTKSu6sT63noPO6m4fHY7gu3Zt+fOc/WYGch9sBeWjZlCS1mA2lajkWhM3J8TFWCFm2Zk4/S3s5mt6VLbwpQnH2LhE41+azzDEVhcR6i3FfdgOF/J+j2fYYHJsBEKoQA5zUac2zWmz7X4Rv/g11ZBRqdMpHSD58o5F9lBb13antu5GcEs5RXpXp08OyXuRV9qhFpDBC8DOMALSOgT3vnu8uJLgo8QIulERofj/cRXbLCsmvMbpioBuGFXWx3ha4Ntd6z07kUh2KVbaIQLd/629UHNvgIhoBLlREJ8E5vllsX+jh8hRITHcCiEwXcDO+gG3hvJt0+jm8S8SObE/IHk8VuwWdhIsSku5vd+wVlxm8VeJzjc0cjdIiytvsq8VpLudKEUiqR0f2tHcoq8H+xcJv3Ycu1i8=")
                .user("test-user-1")
                .build());
    
        }
    }
    
    resources:
      test:
        type: routeros:SystemUserSshkeys
        properties:
          comment: Test User
          key: ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCyJ1EvW98veNVzR3VamNgmu0xOd/JK9YNvP/pa4WC5eT90UbX4TN7dKEK/x2FCwnnG9u0FQhzG2qa/Cg8meUvlfydn6uxc0/WCeXTKSu6sT63noPO6m4fHY7gu3Zt+fOc/WYGch9sBeWjZlCS1mA2lajkWhM3J8TFWCFm2Zk4/S3s5mt6VLbwpQnH2LhE41+azzDEVhcR6i3FfdgOF/J+j2fYYHJsBEKoQA5zUac2zWmz7X4Rv/g11ZBRqdMpHSD58o5F9lBb13antu5GcEs5RXpXp08OyXuRV9qhFpDBC8DOMALSOgT3vnu8uJLgo8QIulERofj/cRXbLCsmvMbpioBuGFXWx3ha4Ntd6z07kUh2KVbaIQLd/629UHNvgIhoBLlREJ8E5vllsX+jh8hRITHcCiEwXcDO+gG3hvJt0+jm8S8SObE/IHk8VuwWdhIsSku5vd+wVlxm8VeJzjc0cjdIiytvsq8VpLudKEUiqR0f2tHcoq8H+xcJv3Ycu1i8=
          user: test-user-1
    

    Create SystemUserSshkeys Resource

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

    Constructor syntax

    new SystemUserSshkeys(name: string, args: SystemUserSshkeysArgs, opts?: CustomResourceOptions);
    @overload
    def SystemUserSshkeys(resource_name: str,
                          args: SystemUserSshkeysArgs,
                          opts: Optional[ResourceOptions] = None)
    
    @overload
    def SystemUserSshkeys(resource_name: str,
                          opts: Optional[ResourceOptions] = None,
                          key: Optional[str] = None,
                          user: Optional[str] = None,
                          ___id_: Optional[float] = None,
                          ___path_: Optional[str] = None,
                          ___ts_: Optional[str] = None,
                          comment: Optional[str] = None,
                          system_user_sshkeys_id: Optional[str] = None)
    func NewSystemUserSshkeys(ctx *Context, name string, args SystemUserSshkeysArgs, opts ...ResourceOption) (*SystemUserSshkeys, error)
    public SystemUserSshkeys(string name, SystemUserSshkeysArgs args, CustomResourceOptions? opts = null)
    public SystemUserSshkeys(String name, SystemUserSshkeysArgs args)
    public SystemUserSshkeys(String name, SystemUserSshkeysArgs args, CustomResourceOptions options)
    
    type: routeros:SystemUserSshkeys
    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 SystemUserSshkeysArgs
    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 SystemUserSshkeysArgs
    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 SystemUserSshkeysArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args SystemUserSshkeysArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args SystemUserSshkeysArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    SystemUserSshkeys 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 SystemUserSshkeys resource accepts the following input properties:

    Key string
    key
    User string
    username to which the SSH key is assigned.
    Comment string
    SystemUserSshkeysId string
    The ID of this resource.
    ___id_ double
    Resource ID type (.id / name). This is an internal service field, setting a value is not required.
    ___path_ string
    Resource path for CRUD operations. This is an internal service field, setting a value is not required.
    ___ts_ string
    A set of transformations for field names. This is an internal service field, setting a value is not required.
    Key string
    key
    User string
    username to which the SSH key is assigned.
    Comment string
    SystemUserSshkeysId string
    The ID of this resource.
    ___id_ float64
    Resource ID type (.id / name). This is an internal service field, setting a value is not required.
    ___path_ string
    Resource path for CRUD operations. This is an internal service field, setting a value is not required.
    ___ts_ string
    A set of transformations for field names. This is an internal service field, setting a value is not required.
    key String
    key
    user String
    username to which the SSH key is assigned.
    ___id_ Double
    Resource ID type (.id / name). This is an internal service field, setting a value is not required.
    ___path_ String
    Resource path for CRUD operations. This is an internal service field, setting a value is not required.
    ___ts_ String
    A set of transformations for field names. This is an internal service field, setting a value is not required.
    comment String
    systemUserSshkeysId String
    The ID of this resource.
    key string
    key
    user string
    username to which the SSH key is assigned.
    ___id_ number
    Resource ID type (.id / name). This is an internal service field, setting a value is not required.
    ___path_ string
    Resource path for CRUD operations. This is an internal service field, setting a value is not required.
    ___ts_ string
    A set of transformations for field names. This is an internal service field, setting a value is not required.
    comment string
    systemUserSshkeysId string
    The ID of this resource.
    key str
    key
    user str
    username to which the SSH key is assigned.
    ___id_ float
    Resource ID type (.id / name). This is an internal service field, setting a value is not required.
    ___path_ str
    Resource path for CRUD operations. This is an internal service field, setting a value is not required.
    ___ts_ str
    A set of transformations for field names. This is an internal service field, setting a value is not required.
    comment str
    system_user_sshkeys_id str
    The ID of this resource.
    key String
    key
    user String
    username to which the SSH key is assigned.
    ___id_ Number
    Resource ID type (.id / name). This is an internal service field, setting a value is not required.
    ___path_ String
    Resource path for CRUD operations. This is an internal service field, setting a value is not required.
    ___ts_ String
    A set of transformations for field names. This is an internal service field, setting a value is not required.
    comment String
    systemUserSshkeysId String
    The ID of this resource.

    Outputs

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

    Bits double
    key length
    Id string
    The provider-assigned unique ID for this managed resource.
    KeyOwner string
    SSH key owner
    KeyType string
    key type
    Rsa bool
    key type is rsa
    Bits float64
    key length
    Id string
    The provider-assigned unique ID for this managed resource.
    KeyOwner string
    SSH key owner
    KeyType string
    key type
    Rsa bool
    key type is rsa
    bits Double
    key length
    id String
    The provider-assigned unique ID for this managed resource.
    keyOwner String
    SSH key owner
    keyType String
    key type
    rsa Boolean
    key type is rsa
    bits number
    key length
    id string
    The provider-assigned unique ID for this managed resource.
    keyOwner string
    SSH key owner
    keyType string
    key type
    rsa boolean
    key type is rsa
    bits float
    key length
    id str
    The provider-assigned unique ID for this managed resource.
    key_owner str
    SSH key owner
    key_type str
    key type
    rsa bool
    key type is rsa
    bits Number
    key length
    id String
    The provider-assigned unique ID for this managed resource.
    keyOwner String
    SSH key owner
    keyType String
    key type
    rsa Boolean
    key type is rsa

    Look up Existing SystemUserSshkeys Resource

    Get an existing SystemUserSshkeys 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?: SystemUserSshkeysState, opts?: CustomResourceOptions): SystemUserSshkeys
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            ___id_: Optional[float] = None,
            ___path_: Optional[str] = None,
            ___ts_: Optional[str] = None,
            bits: Optional[float] = None,
            comment: Optional[str] = None,
            key: Optional[str] = None,
            key_owner: Optional[str] = None,
            key_type: Optional[str] = None,
            rsa: Optional[bool] = None,
            system_user_sshkeys_id: Optional[str] = None,
            user: Optional[str] = None) -> SystemUserSshkeys
    func GetSystemUserSshkeys(ctx *Context, name string, id IDInput, state *SystemUserSshkeysState, opts ...ResourceOption) (*SystemUserSshkeys, error)
    public static SystemUserSshkeys Get(string name, Input<string> id, SystemUserSshkeysState? state, CustomResourceOptions? opts = null)
    public static SystemUserSshkeys get(String name, Output<String> id, SystemUserSshkeysState state, CustomResourceOptions options)
    resources:  _:    type: routeros:SystemUserSshkeys    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.
    The following state arguments are supported:
    Bits double
    key length
    Comment string
    Key string
    key
    KeyOwner string
    SSH key owner
    KeyType string
    key type
    Rsa bool
    key type is rsa
    SystemUserSshkeysId string
    The ID of this resource.
    User string
    username to which the SSH key is assigned.
    ___id_ double
    Resource ID type (.id / name). This is an internal service field, setting a value is not required.
    ___path_ string
    Resource path for CRUD operations. This is an internal service field, setting a value is not required.
    ___ts_ string
    A set of transformations for field names. This is an internal service field, setting a value is not required.
    Bits float64
    key length
    Comment string
    Key string
    key
    KeyOwner string
    SSH key owner
    KeyType string
    key type
    Rsa bool
    key type is rsa
    SystemUserSshkeysId string
    The ID of this resource.
    User string
    username to which the SSH key is assigned.
    ___id_ float64
    Resource ID type (.id / name). This is an internal service field, setting a value is not required.
    ___path_ string
    Resource path for CRUD operations. This is an internal service field, setting a value is not required.
    ___ts_ string
    A set of transformations for field names. This is an internal service field, setting a value is not required.
    ___id_ Double
    Resource ID type (.id / name). This is an internal service field, setting a value is not required.
    ___path_ String
    Resource path for CRUD operations. This is an internal service field, setting a value is not required.
    ___ts_ String
    A set of transformations for field names. This is an internal service field, setting a value is not required.
    bits Double
    key length
    comment String
    key String
    key
    keyOwner String
    SSH key owner
    keyType String
    key type
    rsa Boolean
    key type is rsa
    systemUserSshkeysId String
    The ID of this resource.
    user String
    username to which the SSH key is assigned.
    ___id_ number
    Resource ID type (.id / name). This is an internal service field, setting a value is not required.
    ___path_ string
    Resource path for CRUD operations. This is an internal service field, setting a value is not required.
    ___ts_ string
    A set of transformations for field names. This is an internal service field, setting a value is not required.
    bits number
    key length
    comment string
    key string
    key
    keyOwner string
    SSH key owner
    keyType string
    key type
    rsa boolean
    key type is rsa
    systemUserSshkeysId string
    The ID of this resource.
    user string
    username to which the SSH key is assigned.
    ___id_ float
    Resource ID type (.id / name). This is an internal service field, setting a value is not required.
    ___path_ str
    Resource path for CRUD operations. This is an internal service field, setting a value is not required.
    ___ts_ str
    A set of transformations for field names. This is an internal service field, setting a value is not required.
    bits float
    key length
    comment str
    key str
    key
    key_owner str
    SSH key owner
    key_type str
    key type
    rsa bool
    key type is rsa
    system_user_sshkeys_id str
    The ID of this resource.
    user str
    username to which the SSH key is assigned.
    ___id_ Number
    Resource ID type (.id / name). This is an internal service field, setting a value is not required.
    ___path_ String
    Resource path for CRUD operations. This is an internal service field, setting a value is not required.
    ___ts_ String
    A set of transformations for field names. This is an internal service field, setting a value is not required.
    bits Number
    key length
    comment String
    key String
    key
    keyOwner String
    SSH key owner
    keyType String
    key type
    rsa Boolean
    key type is rsa
    systemUserSshkeysId String
    The ID of this resource.
    user String
    username to which the SSH key is assigned.

    Import

    #The ID can be found via API or the terminal

    #The command for the terminal is -> :put [/user/ssh-keys get [print show-ids]]

    $ pulumi import routeros:index/systemUserSshkeys:SystemUserSshkeys test *1
    

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

    Package Details

    Repository
    routeros terraform-routeros/terraform-provider-routeros
    License
    Notes
    This Pulumi package is based on the routeros Terraform Provider.
    routeros logo
    routeros 1.83.1 published on Monday, Apr 28, 2025 by terraform-routeros