WireguardControl.ts overview
Wireguard control mechanisms.
Since v1.0.0
Exports Grouped by Category
Constructors
makeBundledWgQuickLayer
Signature
declare const makeBundledWgQuickLayer: (options: { sudo: boolean }) => WireguardControl
Since v1.0.0
makeUserspaceLayer
Signature
declare const makeUserspaceLayer: () => WireguardControl
Since v1.0.0
Layers
BundledWgQuickLayer
Signature
declare const BundledWgQuickLayer: Layer.Layer<WireguardControl, never, never>
Since v1.0.0
UserspaceLayer
Signature
declare const UserspaceLayer: Layer.Layer<WireguardControl, never, never>
Since v1.0.0
Models
WireguardControl (interface)
Signature
export interface WireguardControl {
readonly [TypeId]: TypeId
readonly up: (
wireguardConfig: WireguardConfig.WireguardConfig,
wireguardInterface: WireguardInterface.WireguardInterface
) => Effect.Effect<
WireguardInterface.WireguardInterface,
Socket.SocketError | ParseResult.ParseError | PlatformError.PlatformError | Cause.TimeoutException,
FileSystem.FileSystem | Path.Path | CommandExecutor.CommandExecutor
>
readonly down: (
wireguardConfig: WireguardConfig.WireguardConfig,
wireguardInterface: WireguardInterface.WireguardInterface,
wireguardGoProcess?: exec.ChildProcess
) => Effect.Effect<
WireguardInterface.WireguardInterface,
PlatformError.PlatformError | ParseResult.ParseError | Cause.TimeoutException,
FileSystem.FileSystem | Path.Path | CommandExecutor.CommandExecutor
>
readonly upScoped: (
wireguardConfig: WireguardConfig.WireguardConfig,
wireguardInterface: WireguardInterface.WireguardInterface
) => Effect.Effect<
WireguardInterface.WireguardInterface,
Socket.SocketError | ParseResult.ParseError | PlatformError.PlatformError | Cause.TimeoutException,
FileSystem.FileSystem | Path.Path | Scope.Scope | CommandExecutor.CommandExecutor
>
}
Since v1.0.0
Tags
WireguardControl
Signature
declare const WireguardControl: Context.Tag<WireguardControl, WireguardControl>
Since v1.0.0
Type ids
TypeId
Signature
declare const TypeId: unique symbol
Since v1.0.0
TypeId (type alias)
Signature
type TypeId = typeof TypeId
Since v1.0.0