MosquittoServerResource

Handle
📦 CommunityToolkit.Aspire.Hosting.Mosquitto v13.6.1

A resource that represents a Mosquitto MQTT broker container.

type MosquittoServerResource interface {
ExpressionValue
IComputeResource
Resource
ResourceWithArgs
ResourceWithConnectionString
ResourceWithEndpoints
ResourceWithEnvironment
ResourceWithWaitSupport
}

Properties

propertyConnectionStringExpression*ReferenceExpressionget
Gets the connection string expression for the Mosquitto broker in the form of mqtt://host:port, suitable for use by MQTT clients.
ConnectionStringExpression() *ReferenceExpression
propertyHostEndpointReferenceExpressionget
Gets the host of the primary MQTT endpoint.
Host() EndpointReferenceExpression
propertyPortEndpointReferenceExpressionget
Gets the port of the primary MQTT endpoint.
Port() EndpointReferenceExpression
propertyPrimaryEndpointEndpointReferenceget
Gets the primary MQTT endpoint for the Mosquitto broker.
PrimaryEndpoint() EndpointReference
propertyUriExpression*ReferenceExpressionget
Gets the connection URI expression for the Mosquitto broker.
UriExpression() *ReferenceExpression

Methods

methodWithDataBindMountbuilder
Adds a bind mount for the data folder to a Mosquitto container resource.
WithDataBindMount(
source string,
options ...*WithDataBindMountOptions,
) MosquittoServerResource
sourcestringThe source directory on the host to mount into the container.
options...*WithDataBindMountOptionsOptional settings, described under Options.

Optional parameters are passed in a trailing options ...*WithDataBindMountOptions argument.

IsReadOnly*boolA flag that indicates if this is a read-only mount.
MosquittoServerResource

A reference to the IResourceBuilder.

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

methodWithDataVolumebuilder
Adds a named volume for the data folder to a Mosquitto container resource.
WithDataVolume(options ...*WithDataVolumeOptions) MosquittoServerResource
options...*WithDataVolumeOptionsOptional settings, described under Options.

Optional parameters are passed in a trailing options ...*WithDataVolumeOptions argument.

Name*stringThe name of the volume. Defaults to an auto-generated name based on the application and resource names.
IsReadOnly*boolA flag that indicates if this is a read-only volume.
MosquittoServerResource

A reference to the IResourceBuilder.

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