ssh-keygen
Generate a new SSH key pair.
Installation
dagger install github.com/jedevc/daggerverse-sagikazarmark/ssh-keygen@a104424df38ca8b0b758f699dcfeeb0c2210cc2e
Entrypoint
Return Type
SshKeygen
Example
dagger -m github.com/jedevc/daggerverse-sagikazarmark/ssh-keygen@a104424df38ca8b0b758f699dcfeeb0c2210cc2e call \
func (m *myModule) example() *SshKeygen {
return dag.
SshKeygen()
}
@function
def example() -> dag.SshKeygen:
return (
dag.ssh_keygen()
)
@func()
example(): SshKeygen {
return dag
.sshKeygen()
}
Types
SshKeygen 🔗
Generate a new SSH key pair.
ed25519() 🔗
Generate a new SSH key pair using the Ed25519 algorithm.
Return Type
SshKeygenEd25519 !
Example
dagger -m github.com/jedevc/daggerverse-sagikazarmark/ssh-keygen@a104424df38ca8b0b758f699dcfeeb0c2210cc2e call \
ed-2-5-5-1-9
func (m *myModule) example() *SshKeygenEd25519 {
return dag.
SshKeygen().
Ed25519()
}
@function
def example() -> dag.SshKeygenEd25519:
return (
dag.ssh_keygen()
.ed25519()
)
@func()
example(): SshKeygenEd25519 {
return dag
.sshKeygen()
.ed25519()
}
rsa() 🔗
Generate a new SSH key pair using the RSA algorithm.
Return Type
SshKeygenRsa !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
bits | Integer | 4096 | Generate an RSA private key with the given number of bits. |
Example
dagger -m github.com/jedevc/daggerverse-sagikazarmark/ssh-keygen@a104424df38ca8b0b758f699dcfeeb0c2210cc2e call \
rsa
func (m *myModule) example() *SshKeygenRsa {
return dag.
SshKeygen().
Rsa()
}
@function
def example() -> dag.SshKeygenRsa:
return (
dag.ssh_keygen()
.rsa()
)
@func()
example(): SshKeygenRsa {
return dag
.sshKeygen()
.rsa()
}
ecdsa() 🔗
Generate a new SSH key pair using the ECDSA algorithm.
Return Type
SshKeygenEcdsa !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
bits | Integer | 256 | Generate an ECDSA private key with the given number of bits. |
Example
dagger -m github.com/jedevc/daggerverse-sagikazarmark/ssh-keygen@a104424df38ca8b0b758f699dcfeeb0c2210cc2e call \
ecdsa
func (m *myModule) example() *SshKeygenEcdsa {
return dag.
SshKeygen().
Ecdsa()
}
@function
def example() -> dag.SshKeygenEcdsa:
return (
dag.ssh_keygen()
.ecdsa()
)
@func()
example(): SshKeygenEcdsa {
return dag
.sshKeygen()
.ecdsa()
}
SshKeygenEd25519 🔗
Generate a new SSH key pair using the Ed25519 algorithm.
generate() 🔗
Generate a new SSH key pair using the Ed25519 algorithm.
Return Type
SshKeygenKeyPair !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
name | String | "id_ed25519" | Name used as public key file name and private key secret name. Set this to something unique if you need multiple keys. |
passphrase | Secret | - | Encrypt the private key with the given passphrase. |
Example
dagger -m github.com/jedevc/daggerverse-sagikazarmark/ssh-keygen@a104424df38ca8b0b758f699dcfeeb0c2210cc2e call \
ed-2-5-5-1-9 \
generate
func (m *myModule) example() *SshKeygenKeyPair {
return dag.
SshKeygen().
Ed25519().
Generate()
}
@function
def example() -> dag.SshKeygenKeyPair:
return (
dag.ssh_keygen()
.ed25519()
.generate()
)
@func()
example(): SshKeygenKeyPair {
return dag
.sshKeygen()
.ed25519()
.generate()
}
SshKeygenRsa 🔗
Generate a new SSH key pair using the RSA algorithm.
bits() 🔗
Return Type
Integer !
Example
dagger -m github.com/jedevc/daggerverse-sagikazarmark/ssh-keygen@a104424df38ca8b0b758f699dcfeeb0c2210cc2e call \
rsa \
bits
func (m *myModule) example(ctx context.Context) int {
return dag.
SshKeygen().
Rsa().
Bits(ctx)
}
@function
async def example() -> int:
return await (
dag.ssh_keygen()
.rsa()
.bits()
)
@func()
async example(): Promise<number> {
return dag
.sshKeygen()
.rsa()
.bits()
}
generate() 🔗
Generate a new SSH key pair using the RSA algorithm.
Return Type
SshKeygenKeyPair !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
name | String | "id_rsa" | Name used as public key file name and private key secret name. Set this to something unique if you need multiple keys. |
passphrase | Secret | - | Encrypt the private key with the given passphrase. |
Example
dagger -m github.com/jedevc/daggerverse-sagikazarmark/ssh-keygen@a104424df38ca8b0b758f699dcfeeb0c2210cc2e call \
rsa \
generate
func (m *myModule) example() *SshKeygenKeyPair {
return dag.
SshKeygen().
Rsa().
Generate()
}
@function
def example() -> dag.SshKeygenKeyPair:
return (
dag.ssh_keygen()
.rsa()
.generate()
)
@func()
example(): SshKeygenKeyPair {
return dag
.sshKeygen()
.rsa()
.generate()
}
SshKeygenEcdsa 🔗
Generate a new SSH key pair using the ECDSA algorithm.
bits() 🔗
Return Type
Integer !
Example
dagger -m github.com/jedevc/daggerverse-sagikazarmark/ssh-keygen@a104424df38ca8b0b758f699dcfeeb0c2210cc2e call \
ecdsa \
bits
func (m *myModule) example(ctx context.Context) int {
return dag.
SshKeygen().
Ecdsa().
Bits(ctx)
}
@function
async def example() -> int:
return await (
dag.ssh_keygen()
.ecdsa()
.bits()
)
@func()
async example(): Promise<number> {
return dag
.sshKeygen()
.ecdsa()
.bits()
}
generate() 🔗
Generate a new SSH key pair using the ECDSA algorithm.
Return Type
SshKeygenKeyPair !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
name | String | "id_ecdsa" | Name used as public key file name and private key secret name. Set this to something unique if you need multiple keys. |
passphrase | Secret | - | Encrypt the private key with the given passphrase. |
Example
dagger -m github.com/jedevc/daggerverse-sagikazarmark/ssh-keygen@a104424df38ca8b0b758f699dcfeeb0c2210cc2e call \
ecdsa \
generate
func (m *myModule) example() *SshKeygenKeyPair {
return dag.
SshKeygen().
Ecdsa().
Generate()
}
@function
def example() -> dag.SshKeygenKeyPair:
return (
dag.ssh_keygen()
.ecdsa()
.generate()
)
@func()
example(): SshKeygenKeyPair {
return dag
.sshKeygen()
.ecdsa()
.generate()
}
SshKeygenKeyPair 🔗
An SSH key pair.
publicKey() 🔗
Return Type
File !
Example
dagger -m github.com/jedevc/daggerverse-sagikazarmark/ssh-keygen@a104424df38ca8b0b758f699dcfeeb0c2210cc2e call \
ecdsa \
generate \
public-key
func (m *myModule) example() *File {
return dag.
SshKeygen().
Ecdsa().
Generate().
PublicKey()
}
@function
def example() -> dagger.File:
return (
dag.ssh_keygen()
.ecdsa()
.generate()
.public_key()
)
@func()
example(): File {
return dag
.sshKeygen()
.ecdsa()
.generate()
.publicKey()
}
privateKey() 🔗
Return Type
Secret !
Example
dagger -m github.com/jedevc/daggerverse-sagikazarmark/ssh-keygen@a104424df38ca8b0b758f699dcfeeb0c2210cc2e call \
ecdsa \
generate \
private-key
func (m *myModule) example() *Secret {
return dag.
SshKeygen().
Ecdsa().
Generate().
PrivateKey()
}
@function
def example() -> dagger.Secret:
return (
dag.ssh_keygen()
.ecdsa()
.generate()
.private_key()
)
@func()
example(): Secret {
return dag
.sshKeygen()
.ecdsa()
.generate()
.privateKey()
}