store: introduce state directory
Prior to this commit outputs directory used by local target was owned by root. This made impossible for osbuild-composer to delete images. (osbuild-composer doesn't run as root). This commit introduces state directory in which osbuild-composer creates outputs directory. Because this directory is owned by osbuild-composer, it's able to delete files inside.
This commit is contained in:
parent
0cf8a20744
commit
6d15833e4e
5 changed files with 24 additions and 31 deletions
|
|
@ -259,14 +259,7 @@ func TestCompose(t *testing.T) {
|
|||
Customizations: nil,
|
||||
},
|
||||
OutputType: "tar",
|
||||
Targets: []*target.Target{
|
||||
{
|
||||
Name: "org.osbuild.local",
|
||||
Created: time.Time{},
|
||||
Status: "WAITING",
|
||||
Options: &target.LocalTargetOptions{},
|
||||
},
|
||||
},
|
||||
Targets: []*target.Target{},
|
||||
}
|
||||
|
||||
expectedComposeLocalAndAws := &store.Compose{
|
||||
|
|
@ -281,11 +274,6 @@ func TestCompose(t *testing.T) {
|
|||
},
|
||||
OutputType: "tar",
|
||||
Targets: []*target.Target{
|
||||
{
|
||||
Name: "org.osbuild.local",
|
||||
Status: "WAITING",
|
||||
Options: &target.LocalTargetOptions{},
|
||||
},
|
||||
{
|
||||
Name: "org.osbuild.aws",
|
||||
Status: "WAITING",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue