diff options
author | Héctor Orón Martínez <zumbi@debian.org> | 2018-05-19 16:18:19 +0200 |
---|---|---|
committer | Héctor Orón Martínez <zumbi@debian.org> | 2018-05-19 16:18:19 +0200 |
commit | 8ab62bc45ed897f007493d02084538503ade6f37 (patch) | |
tree | 39aaa39328f1b3b6b346d21a15b1ff5465ec8659 /actions | |
parent | 4808cb7058c548bf76476ec2f9618d784d76bdda (diff) |
New upstream version 1.0.0+git20180328.8f2bc2a
Diffstat (limited to 'actions')
-rw-r--r-- | actions/debootstrap_action.go | 2 | ||||
-rw-r--r-- | actions/ostree_deploy_action.go | 14 | ||||
-rw-r--r-- | actions/run_action.go | 2 |
3 files changed, 16 insertions, 2 deletions
diff --git a/actions/debootstrap_action.go b/actions/debootstrap_action.go index a53d153..4f30ee6 100644 --- a/actions/debootstrap_action.go +++ b/actions/debootstrap_action.go @@ -86,7 +86,7 @@ func (d *DebootstrapAction) Run(context *debos.DebosContext) error { } if d.KeyringPackage != "" { - cmdline = append(cmdline, fmt.Sprintf("--keyring=%s", d.KeyringPackage)) + cmdline = append(cmdline, fmt.Sprintf("--include=%s", d.KeyringPackage)) } if d.Components != nil { diff --git a/actions/ostree_deploy_action.go b/actions/ostree_deploy_action.go index b2d373d..d69600d 100644 --- a/actions/ostree_deploy_action.go +++ b/actions/ostree_deploy_action.go @@ -13,6 +13,8 @@ Yaml syntax: remote_repository: URL branch: branch name os: os name + tls-client-cert-path: path to client certificate + tls-client-key-path: path to client certificate key setup-fstab: bool setup-kernel-cmdline: bool appendkernelcmdline: arguments @@ -38,6 +40,10 @@ Optional properties: action to the configured commandline. - append-kernel-cmdline -- additional kernel command line arguments passed to kernel. + +- tls-client-cert-path -- path to client certificate to use for the remote repository + +- tls-client-key-path -- path to client certificate key to use for the remote repository */ package actions @@ -61,6 +67,8 @@ type OstreeDeployAction struct { SetupFSTab bool `yaml:"setup-fstab"` SetupKernelCmdline bool `yaml:"setup-kernel-cmdline"` AppendKernelCmdline string `yaml:"append-kernel-cmdline"` + TlsClientCertPath string `yaml:"tls-client-cert-path"` + TlsClientKeyPath string `yaml:"tls-client-key-path"` } func NewOstreeDeployAction() *OstreeDeployAction { @@ -103,6 +111,7 @@ func (ot *OstreeDeployAction) Run(context *debos.DebosContext) error { return fmt.Errorf("rootfs deploy failed: %v", err) } context.Rootdir = context.ImageMntDir + context.Origins["filesystem"] = context.ImageMntDir } repoPath := "file://" + path.Join(context.Artifactdir, ot.Repository) @@ -128,7 +137,10 @@ func (ot *OstreeDeployAction) Run(context *debos.DebosContext) error { } /* FIXME: add support for gpg signing commits so this is no longer needed */ - opts := ostree.RemoteOptions{NoGpgVerify: true} + opts := ostree.RemoteOptions{NoGpgVerify: true, + TlsClientCertPath: ot.TlsClientCertPath, + TlsClientKeyPath: ot.TlsClientKeyPath} + err = dstRepo.RemoteAdd("origin", ot.RemoteRepository, opts, nil) if err != nil { return err diff --git a/actions/run_action.go b/actions/run_action.go index ad374d8..90e4572 100644 --- a/actions/run_action.go +++ b/actions/run_action.go @@ -107,6 +107,8 @@ func (run *RunAction) doRun(context debos.DebosContext) error { if !run.PostProcess { if !run.Chroot { cmd.AddEnvKey("ROOTDIR", context.Rootdir) + cmd.AddEnvKey("RECIPEDIR", context.RecipeDir) + cmd.AddEnvKey("ARTIFACTDIR", context.Artifactdir) } if context.Image != "" { cmd.AddEnvKey("IMAGE", context.Image) |