linux

package
v0.4.10 Latest Latest
Warning

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

Go to latest
Published: Jun 26, 2019 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CentOSVersion

func CentOSVersion(w io.Writer) (string, error)

CentOSVersion extract CentOS operating system version

func Modprobe

func Modprobe(out io.Writer, module string) error

func ModprobeBFNetFilter

func ModprobeBFNetFilter(out io.Writer) error

func ModprobeOverlay

func ModprobeOverlay(out io.Writer) error

func RedHatVersion

func RedHatVersion(w io.Writer) (string, error)

RedHatVersion extract RedHat operating system version

func SwapOff

func SwapOff(out io.Writer) error

SwapOff disables Linux swap.

func SysctlLoadAllFiles

func SysctlLoadAllFiles(out io.Writer) error

func Systemctl

func Systemctl(out io.Writer, command, service string) error

func SystemctlActive

func SystemctlActive(out io.Writer, service string) (bool, error)

func SystemctlDisable

func SystemctlDisable(out io.Writer, service string) error

func SystemctlDisableAndStop

func SystemctlDisableAndStop(out io.Writer, service string) error

func SystemctlEnable

func SystemctlEnable(out io.Writer, service string) error

func SystemctlEnableAndStart

func SystemctlEnableAndStart(out io.Writer, service string) error

func SystemctlEnabled

func SystemctlEnabled(out io.Writer, service string) (bool, error)

func SystemctlReload

func SystemctlReload(out io.Writer) error

func SystemctlStart

func SystemctlStart(out io.Writer, service string) error

func SystemctlStop

func SystemctlStop(out io.Writer, service string) error

func YumInstall

func YumInstall(out io.Writer, packages []string) error

Types

type KubernetesPackages

type KubernetesPackages interface {
	InstallKubernetesPackages(out io.Writer, kubernetesVersion string) error
	InstallKubeadmPackage(out io.Writer, kubernetesVersion string) error
}

type YumInstaller

type YumInstaller struct{}

func NewYumInstaller

func NewYumInstaller() *YumInstaller

func (*YumInstaller) InstallKubeadmPackage

func (y *YumInstaller) InstallKubeadmPackage(out io.Writer, kubernetesVersion string) error

func (*YumInstaller) InstallKubernetesPackages

func (y *YumInstaller) InstallKubernetesPackages(out io.Writer, kubernetesVersion string) error

Jump to

Keyboard shortcuts

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