Structureorlandos-nl.citadel 0.8.0Citadel
CommandFailed
TTY.swift:119struct CommandFailed
Other members in extension
View members
Hide members
This section is hidden by default because it contains too many (13) members.
Type members
static func connect(host: String, port: Int, authenticationMethod: SSHAuthenticationMethod, hostKeyValidator: SSHHostKeyValidator, reconnect: SSHReconnectMode, algorithms: SSHAlgorithms, protocolOptions: Set<SSHProtocolOption>, group: MultiThreadedEventLoopGroup, connectTimeout: TimeAmount
) async throws -> SSHClient Connects to an SSH server.
static func connect(on: Channel, authenticationMethod: @autoclosure @escaping () -> SSHAuthenticationMethod, hostKeyValidator: SSHHostKeyValidator, algorithms: SSHAlgorithms, protocolOptions: Set<SSHProtocolOption>
) async throws -> SSHClient Connects to an SSH server.
Instance members
var eventLoop: EventLoop
The event loop that this SSH connection is running on.
var isConnected: Bool
let logger: Logger
func close(
) async throws func createDirectTCPIPChannel(using: SSHChannelType.DirectTCPIP, initialize: @escaping (Channel) -> EventLoopFuture<Void>
) async throws -> Channel Creates a new direct TCP/IP channel. This channel type is used to open a TCP/IP connection to a remote host, through the remote SSH server.
func executeCommand(String, maxResponseSize: Int
) async throws -> ByteBuffer Executes a command on the remote server. This will return the output of the command. If the command fails, the error will be thrown. If the output is too large, the command will fail.
func executeCommand(String, maxResponseSize: Int, mergeStreams: Bool, inShell: Bool
) async throws -> ByteBuffer Executes a command on the remote server. This will return the output of the command (stdout). If the command fails, the error will be thrown. If the output is too large, the command will fail.
func executeCommandPair(String, inShell: Bool
) async throws -> ExecCommandStream Executes a command on the remote server. This will return the pair of streams stdout and stderr of the command. If the command fails, the error will be thrown.
func executeCommandStream(String, inShell: Bool
) async throws -> AsyncThrowingStream<ExecCommandOutput, Error> Executes a command on the remote server. This will return the output stream of the command. If the command fails, the error will be thrown.
func onDisconnect(perform: @escaping () -> ()
) func openSFTP(logger: Logger
) async throws -> SFTPClient Open a SFTP subchannel over the SSH connection using the
sftp
subsystem.
Citizens in Citadel
Conformances
protocol Error
A type representing an error value that can be thrown.
protocol Sendable
A type whose values can safely be passed across concurrency domains by copying.
Instance members
Instance features
var localizedDescription: String
Retrieve the localized description for this error.