zfs

package
v0.0.0-...-0ac389e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 13, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Overview

Package zfs handles interactions with the zfs filesystem

Index

Constants

This section is empty.

Variables

View Source
var (
	ZFSPath = "zfs"
)

ZFSPath is the path to the zfs binary

Functions

func GetCreationDate

func GetCreationDate(ctx context.Context, target string) (time.Time, error)

GetCreationDate will use the zfs command to get and parse the creation datetime of the specified volume/snapshot

func GetSnapshotsAndBookmarks

func GetSnapshotsAndBookmarks(ctx context.Context, target string) ([]files.SnapshotInfo, error)

GetSnapshotsAndBookmarks will retrieve all snapshots and bookmarks for the given target

func GetZFSProperty

func GetZFSProperty(ctx context.Context, prop, target string) (string, error)

GetZFSProperty will return the raw value returned by the "zfs get" command for the given property on the given target.

func GetZFSReceiveCommand

func GetZFSReceiveCommand(ctx context.Context, j *files.JobInfo) *exec.Cmd

GetZFSReceiveCommand will return the recv command to use for the given JobInfo

func GetZFSSendCommand

func GetZFSSendCommand(ctx context.Context, j *files.JobInfo) *exec.Cmd

GetZFSSendCommand will return the send command to use for the given JobInfo

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL