[chef] Re: Re: Reprepro cookbook


Chronological Thread 
  • From: Douglas Garstang < >
  • To:
  • Subject: [chef] Re: Re: Reprepro cookbook
  • Date: Fri, 19 Jun 2015 09:02:34 -0700

Here's the data bag, with the keys redacted.

{
  "id": "main",
  "fqdn": "pypiserv-004.dev.slicetest.com",
  "repo_dir": "/srv/apt",
  "incoming": "/srv/apt_incoming",
  "description": "APT Repository for our packages.",
  "codenames": [
    "trusty"
  ],
  "allow": [
    "unstable>sid", "stable>squeeze"
  ],
  "pgp": {
    "email": " "> ",
    "fingerprint": "PGP Fingerprint for the key",
    "public": "<redacted>",
    "private": "<redacted>"
  },
  "pulls": {
    "name": "sid",
    "from": "sid",
    "component": "main"
  },
  "architectures": [
    "amd64","i386","all","source"
  ]
}


I'm not sure how to get the chef client to run with -l debug via vagrant.

Doug.

On Fri, Jun 19, 2015 at 8:34 AM, Tensibai < " target="_blank"> > wrote:

According to this line https://github.com/jesseadams/reprepro/blob/master/recipes/default.rb#L92

not_if "GNUPGHOME=/root/.gnupg gpg --list-secret-keys --fingerprint #{node['reprepro']['pgp_email']} | egrep -qx '.*Key fingerprint = #{node['reprepro']['pgp_fingerprint']}'"

It should not happen if your databag is set up properly, the quality sounds out of cause in your problem.

Blaming the code quality with so few debugging information is unlikely to get you a return from the authors.

Run with -l debug to see why the guard does not apply and give some insight on what give the guard if you try it in a vagrant ssh session, tell us which distribution you're using, well give insight on your platform so we don't have to guess.

 

Le 2015-06-19 16:31, Douglas Garstang a écrit :

I was trying to use the Debian Reprepro cookbook located here:
https://github.com/jesseadams/reprepro

It runs fine on the first run, and then fails on subsequent runs (ie a simple 'vagrant provision') due to the logic that imports the gpg key not being handled idempotently.

==> default: ================================================================================
==> default: Error executing action `run` on resource 'execute[import packaging key]'
==> default: ================================================================================
==> default:
==> default:
==> default: Mixlib::ShellOut::ShellCommandFailed
==> default: ------------------------------------
==> default: Expected process to exit with [0], but received '2'
==> default: ---- Begin output of /bin/echo -e '-----BEGIN PGP PRIVATE KEY BLOCK-----
==> default: Version: GnuPG v1
==> default:
==> default: <redacted>
==> default: -----END PGP PRIVATE KEY BLOCK-----
==> default: ' | gpg --import - ----
==> default: STDOUT:
==> default: STDERR: gpg: key 18DB12D8: already in secret keyring
==> default: gpg: Total number processed: 1
==> default: gpg:       secret keys read: 1
==> default: gpg:  secret keys unchanged: 1

Disappointing quality from something with Opscode's name on it. Can someone recommend a cookbook for setting up a Debian package repository of better quality? Alternatively I concede I might be doing something wrong in the way I'm implementing it, but I don't think so.

Doug

 

 



--



Archive powered by MHonArc 2.6.16.

§