All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 2/2] openvswitch: Ensure pki directory creation
@ 2013-07-26 14:06 Mihai Prica
  2013-07-31  3:00 ` Bruce Ashfield
  0 siblings, 1 reply; 2+ messages in thread
From: Mihai Prica @ 2013-07-26 14:06 UTC (permalink / raw)
  To: meta-virtualization

RPM doesn't guarantee the order in which postinstalls are ran.
Added code to ensure the pki directory is initialized.

Signed-off-by: Mihai Prica <mihai.prica@intel.com>
---
 .../openvswitch/openvswitch_1.10.0.bb              |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/recipes-networking/openvswitch/openvswitch_1.10.0.bb b/recipes-networking/openvswitch/openvswitch_1.10.0.bb
index fff597c..3703c1b 100644
--- a/recipes-networking/openvswitch/openvswitch_1.10.0.bb
+++ b/recipes-networking/openvswitch/openvswitch_1.10.0.bb
@@ -14,7 +14,7 @@ RDEPENDS_${PN}-pki = "${PN}"
 RDEPENDS_${PN}-brcompat = "${PN} ${PN}-switch"
 RRECOMMENDS_${PN} += "kernel-module-openvswitch"
 
-PR = "r1"
+PR = "r2"
 
 SRC_URI = "http://openvswitch.org/releases/openvswitch-${PV}.tar.gz \
 	file://openvswitch-switch \
@@ -91,6 +91,10 @@ pkg_postinst_${PN}-controller () {
                 exit 1
         fi
 
+    if test ! -d $D/${datadir}/${PN}/pki; then
+        ovs-pki init --dir=$D/${datadir}/${PN}/pki
+    fi
+
 	cd $D/${sysconfdir}/openvswitch-controller
         if ! test -e cacert.pem; then
             ln -s $D/${datadir}/${PN}/pki/switchca/cacert.pem cacert.pem
-- 
1.7.9.5



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH 2/2] openvswitch: Ensure pki directory creation
  2013-07-26 14:06 [PATCH 2/2] openvswitch: Ensure pki directory creation Mihai Prica
@ 2013-07-31  3:00 ` Bruce Ashfield
  0 siblings, 0 replies; 2+ messages in thread
From: Bruce Ashfield @ 2013-07-31  3:00 UTC (permalink / raw)
  To: Mihai Prica; +Cc: meta-virtualization

On Fri, Jul 26, 2013 at 10:06 AM, Mihai Prica <mihai.prica@intel.com> wrote:
> RPM doesn't guarantee the order in which postinstalls are ran.
> Added code to ensure the pki directory is initialized.

Looks good, and tested fine here. Again, sorry for the delay, this is
now merged.

Bruce

>
> Signed-off-by: Mihai Prica <mihai.prica@intel.com>
> ---
>  .../openvswitch/openvswitch_1.10.0.bb              |    6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
>
> diff --git a/recipes-networking/openvswitch/openvswitch_1.10.0.bb b/recipes-networking/openvswitch/openvswitch_1.10.0.bb
> index fff597c..3703c1b 100644
> --- a/recipes-networking/openvswitch/openvswitch_1.10.0.bb
> +++ b/recipes-networking/openvswitch/openvswitch_1.10.0.bb
> @@ -14,7 +14,7 @@ RDEPENDS_${PN}-pki = "${PN}"
>  RDEPENDS_${PN}-brcompat = "${PN} ${PN}-switch"
>  RRECOMMENDS_${PN} += "kernel-module-openvswitch"
>
> -PR = "r1"
> +PR = "r2"
>
>  SRC_URI = "http://openvswitch.org/releases/openvswitch-${PV}.tar.gz \
>         file://openvswitch-switch \
> @@ -91,6 +91,10 @@ pkg_postinst_${PN}-controller () {
>                  exit 1
>          fi
>
> +    if test ! -d $D/${datadir}/${PN}/pki; then
> +        ovs-pki init --dir=$D/${datadir}/${PN}/pki
> +    fi
> +
>         cd $D/${sysconfdir}/openvswitch-controller
>          if ! test -e cacert.pem; then
>              ln -s $D/${datadir}/${PN}/pki/switchca/cacert.pem cacert.pem
> --
> 1.7.9.5
>
> _______________________________________________
> meta-virtualization mailing list
> meta-virtualization@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/meta-virtualization



-- 
"Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end"


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-07-31  3:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-26 14:06 [PATCH 2/2] openvswitch: Ensure pki directory creation Mihai Prica
2013-07-31  3:00 ` Bruce Ashfield

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.