package oci
import "github.com/moby/buildkit/executor/oci"
Index ¶
- func GenerateSpec(ctx context.Context, meta executor.Meta, mounts []executor.Mount, id, resolvConf, hostsFile string, namespace network.Namespace, opts ...oci.SpecOpts) (*specs.Spec, func(), error)
- func GetHostsFile(ctx context.Context, stateDir string, extraHosts []executor.HostIP) (string, func(), error)
- func GetMounts(ctx context.Context, mountOpts ...MountOpts) []specs.Mount
- func GetResolvConf(ctx context.Context, stateDir string) (string, error)
- func GetUser(ctx context.Context, root, username string) (uint32, uint32, []uint32, error)
- func ParseUIDGID(str string) (uid uint32, gid uint32, err error)
- func WithUIDGID(uid, gid uint32, sgids []uint32) containerdoci.SpecOpts
- type MountOpts
Functions ¶
func GenerateSpec ¶
func GenerateSpec(ctx context.Context, meta executor.Meta, mounts []executor.Mount, id, resolvConf, hostsFile string, namespace network.Namespace, opts ...oci.SpecOpts) (*specs.Spec, func(), error)
GenerateSpec generates spec using containerd functionality.
func GetHostsFile ¶
func GetHostsFile(ctx context.Context, stateDir string, extraHosts []executor.HostIP) (string, func(), error)
func GetMounts ¶
GetMounts returns default required for buildkit https://github.com/moby/buildkit/issues/429
func GetResolvConf ¶
func GetUser ¶
func ParseUIDGID ¶
ParseUIDGID takes the fast path to parse UID and GID if and only if they are both provided
func WithUIDGID ¶
func WithUIDGID(uid, gid uint32, sgids []uint32) containerdoci.SpecOpts
WithUIDGID allows the UID and GID for the Process to be set FIXME: This is a temporeray fix for the missing supplementary GIDs from containerd once the PR in containerd is merged we should remove this function.
Types ¶
type MountOpts ¶
MountOpts sets oci spec specific info for mount points
Source Files ¶
hosts.go mounts.go resolvconf.go spec_unix.go user.go
- Version
- v0.3.3
- Published
- Nov 21, 2018
- Platform
- js/wasm
- Imports
- 26 packages
- Last checked
- 6 seconds ago –
Tools for package owners.