osbuild2: port tar assembler to new stage
This commit is contained in:
parent
bec194dfff
commit
33cebcc8fc
1 changed files with 26 additions and 0 deletions
26
internal/osbuild2/tar_stage.go
Normal file
26
internal/osbuild2/tar_stage.go
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
package osbuild2
|
||||
|
||||
type TarStageOptions struct {
|
||||
// Filename for tar archive
|
||||
Filename string `json:"filename"`
|
||||
|
||||
// Enable support for POSIX ACLs
|
||||
ACLs bool `json:"acls,omitempty"`
|
||||
|
||||
// Enable support for SELinux contexts
|
||||
SELinux bool `json:"selinux,omitempty"`
|
||||
|
||||
// Enable support for extended attributes
|
||||
Xattrs bool `json:"xattrs,omitempty"`
|
||||
}
|
||||
|
||||
func (TarStageOptions) isStageOptions() {}
|
||||
|
||||
// Assembles a tree into a tar archive. Compression is determined by the suffix
|
||||
// (i.e., --auto-compress is used).
|
||||
func NewTarAssembler(options *TarStageOptions) *Stage {
|
||||
return &Stage{
|
||||
Type: "org.osbuild.tar",
|
||||
Options: options,
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue