Documentation ¶
Overview ¶
SPDX-License-Identifier: BSD-3-Clause Copyright (c) 2022, Unikraft GmbH and The KraftKit Authors. Licensed under the BSD-3-Clause License (the "License"). You may not use this file except in compliance with the License.
Index ¶
Constants ¶
View Source
const InputDelimeter = ":"
Variables ¶
View Source
var NameToType = map[string]InitrdFormat{ "odc": ODC, "newc": NEWC, "ustar": USTAR, }
Functions ¶
This section is empty.
Types ¶
type InitrdConfig ¶
type InitrdConfig struct { Output string `yaml:",omitempty" json:"output,omitempty"` Input []string `yaml:",omitempty" json:"input,omitempty"` Format InitrdFormat `yaml:",omitempty" json:"format,omitempty"` Compress bool `yaml:",omitempty" json:"compress,omitempty"` WorkingDir string OutDir string }
func NewFromFile ¶ added in v0.6.0
func NewFromFile(path string) (*InitrdConfig, error)
NewFromFile interprets a given path as a initramfs disk file and returns an instantiated InitrdConfig if successful.
func ParseInitrdConfig ¶
func ParseInitrdConfig(workdir string, value string) (*InitrdConfig, error)
ParseInitrdConfig parse short syntax for architecture configuration
func (*InitrdConfig) RelativePath ¶
func (i *InitrdConfig) RelativePath(path string) string
RelativePath resolve a relative path based the working directory
type InitrdFormat ¶
type InitrdFormat int
const ( ODC InitrdFormat = iota NEWC USTAR )
func (InitrdFormat) String ¶
func (d InitrdFormat) String() string
Click to show internal directories.
Click to hide internal directories.