Table of Contents

Class HostsFile

Namespace
Fabricator.Resources
Assembly
Fabricator.Resources.dll
[CompilationMapping(SourceConstructFlags.ObjectType)]
public class HostsFile
Inheritance
HostsFile
Inherited Members

Methods

ConcurrencyGroup(AbsolutePath)

The concurrency group of the resources managing the entries of the specified hosts file.

public static ConcurrencyGroup ConcurrencyGroup(AbsolutePath hostsFilePath)

Parameters

hostsFilePath AbsolutePath

The path to the hosts file.

Returns

ConcurrencyGroup

Record(string, string, FSharpOption<AbsolutePath>?, FSharpOption<IEnumerable<Resource>>?)

Creates a resource for managing a host file entry.

public static Resource Record(string ipAddress, string host, FSharpOption<AbsolutePath>? hostsFilePath, FSharpOption<IEnumerable<Resource>>? dependsOn)

Parameters

ipAddress string

The IP address for the host entry.

host string

The hostname to map to the IP address.

hostsFilePath FSharpOption<AbsolutePath>

Optional path to the hosts file. Defaults to the platform-specific hosts file path: Windows: %SystemRoot%\drivers\etc\hosts (resolved dynamically), Linux/macOS: /etc/hosts

dependsOn FSharpOption<IEnumerable<Resource>>

The resources this resource depends on.

Returns

Resource

A resource managing the host file entry.