Skip to content

Commit

Permalink
foldup
Browse files Browse the repository at this point in the history
  • Loading branch information
hallyn committed Dec 22, 2023
1 parent fd6d1b2 commit 0912a26
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 10 deletions.
18 changes: 9 additions & 9 deletions pkg/mosconfig/files.go
Original file line number Diff line number Diff line change
Expand Up @@ -437,14 +437,14 @@ func (i *ImportFile) CompleteTargets(keyProject string) (UserTargets, error) {
}

type UserTarget struct {
ServiceName string `yaml:"service_name"` // name of target
Source string `yaml:"source"` // docker url from which to fetch
Version string `yaml:"version"` // A version for internal use.
Storage StorageList `yaml:"storage"`
ServiceType ServiceType `yaml:"service_type"`
Network TargetNetwork `yaml:"network"`
NSGroup string `yaml:"nsgroup"`
Digest string `yaml:"digest"`
Size int64 `yaml:"size"`
ServiceName string `yaml:"service_name"` // name of target
Source string `yaml:"source"` // docker url from which to fetch
Version string `yaml:"version"` // A version for internal use.
Storage TargetStorageList `yaml:"storage"`
ServiceType ServiceType `yaml:"service_type"`
Network TargetNetwork `yaml:"network"`
NSGroup string `yaml:"nsgroup"`
Digest string `yaml:"digest"`
Size int64 `yaml:"size"`
}
type UserTargets []UserTarget
2 changes: 2 additions & 0 deletions pkg/mosconfig/install.go
Original file line number Diff line number Diff line change
Expand Up @@ -368,9 +368,11 @@ func PublishManifest(project, repo, destpath, manifestpath string, skipBootkit b
ServiceType: t.ServiceType,
Network: t.Network,
NSGroup: t.NSGroup,
Storage: t.Storage,
Digest: digest,
Size: size},
)
log.Infof("appending storage item %#v", t.Storage)
}

workdir, err := os.MkdirTemp("", "manifest")
Expand Down
2 changes: 1 addition & 1 deletion pkg/mosconfig/mos.go
Original file line number Diff line number Diff line change
Expand Up @@ -461,7 +461,7 @@ func (mos *Mos) writeLxcConfig(t *Target) error {

// setup the storage mounts
for _, m := range t.Storage {
dest := m.Dest
dest := strings.TrimPrefix(m.Dest, "/")
src := filepath.Join("/storage", m.Label)
isdir, err := utils.IsDirErr(src)
if err != nil {
Expand Down

0 comments on commit 0912a26

Please sign in to comment.