Aspirerelease/17.0
Watch Aspire live streamsDocsTry Aspire

WithHostKeyFile

Method
📦 CommunityToolkit.Aspire.Hosting.Sftp v13.6.1
func (SftpContainerResource) WithHostKeyFile(
keyFile string,
keyType KeyType,
) SftpContainerResource

Signature

methodWithHostKeyFilebuilder
Adds a bind mount for the specified host key file to an SFTP container resource.
WithHostKeyFile(
keyFile string,
keyType KeyType,
) SftpContainerResource
keyFilestringThe path to the host key file.
keyTypeKeyTypeThe type of the host key.
SftpContainerResource

The IResourceBuilder.

Returns a handle; failures surface later via Err().

Applies to

This method applies to the following types: