package fs

import "github.com/prometheus/procfs/internal/fs"

Index

Constants

const (
	// DefaultProcMountPoint is the common mount point of the proc filesystem.
	DefaultProcMountPoint = "/proc"

	// DefaultSysMountPoint is the common mount point of the sys filesystem.
	DefaultSysMountPoint = "/sys"

	// DefaultConfigfsMountPoint is the common mount point of the configfs.
	DefaultConfigfsMountPoint = "/sys/kernel/config"

	// DefaultSelinuxMountPoint is the common mount point of the selinuxfs.
	DefaultSelinuxMountPoint = "/sys/fs/selinux"
)

Types

type FS

type FS string

FS represents a pseudo-filesystem, normally /proc or /sys, which provides an interface to kernel data structures.

func NewFS

func NewFS(mountPoint string) (FS, error)

NewFS returns a new FS mounted under the given mountPoint. It will error if the mount point can't be read.

func (FS) Path

func (fs FS) Path(p ...string) string

Path appends the given path elements to the filesystem path, adding separators as necessary.

Source Files

fs.go

Version
v0.16.1 (latest)
Published
Apr 19, 2025
Platform
js/wasm
Imports
3 packages
Last checked
5 hours ago

Tools for package owners.