From: Martin Jansa <martin.jansa@gmail.com>
To: openembedded-devel@lists.openembedded.org
Subject: Re: [meta-webserver][PATCHv4] monkey: new v1.5.1 release.
Date: Fri, 18 Jul 2014 20:15:35 +0200 [thread overview]
Message-ID: <20140718181535.GQ2433@jama> (raw)
In-Reply-To: <1405147077-22498-1-git-send-email-eduardo@monkey.io>
[-- Attachment #1: Type: text/plain, Size: 5391 bytes --]
On Sat, Jul 12, 2014 at 12:37:57AM -0600, Eduardo Silva wrote:
> This patch add the minor release fix of Monkey HTTP Server v1.5.1. It fixes
> some problems when switching user when started as root.
>
> monkey/yocto: 941ce3a55496d42164164877735db6c8def63265
>
> Signed-off-by: Eduardo Silva <eduardo@monkey.io>
> ---
> .../recipes-httpd/monkey/files/monkey.init | 34 ++++++++++++++++++++++
> .../recipes-httpd/monkey/files/monkey.service | 12 ++++++++
> .../monkey/{monkey_1.5.0.bb => monkey_1.5.1.bb} | 25 ++++++++++++----
> 3 files changed, 65 insertions(+), 6 deletions(-)
> create mode 100644 meta-webserver/recipes-httpd/monkey/files/monkey.init
> create mode 100644 meta-webserver/recipes-httpd/monkey/files/monkey.service
> rename meta-webserver/recipes-httpd/monkey/{monkey_1.5.0.bb => monkey_1.5.1.bb} (59%)
>
> diff --git a/meta-webserver/recipes-httpd/monkey/files/monkey.init b/meta-webserver/recipes-httpd/monkey/files/monkey.init
> new file mode 100644
> index 0000000..40b2118
> --- /dev/null
> +++ b/meta-webserver/recipes-httpd/monkey/files/monkey.init
> @@ -0,0 +1,34 @@
> +#!/bin/sh
> +
> +PATH=/sbin:/bin:/usr/sbin:/usr/bin
> +DAEMON=/usr/bin/monkey
> +NAME=monkey
> +DESC="Monkey HTTP Server"
> +OPTS="--daemon"
> +
> +case "$1" in
> + start)
> + echo -n "Starting $DESC: "
> + start-stop-daemon --start -x "$DAEMON" -- $OPTS
> + echo "$NAME."
> + ;;
> + stop)
> + echo -n "Stopping $DESC: "
> + start-stop-daemon --stop -x "$DAEMON"
> + echo "$NAME."
> + ;;
> + restart|force-reload)
> + echo -n "Restarting $DESC: "
> + start-stop-daemon --stop -x "$DAEMON"
> + sleep 1
> + start-stop-daemon --start -x "$DAEMON" -- $OPTS
> + echo "$NAME."
> + ;;
> + *)
> + N=/etc/init.d/$NAME
> + echo "Usage: $N {start|stop|restart|force-reload}" >&2
> + exit 1
> + ;;
> +esac
> +
> +exit 0
> diff --git a/meta-webserver/recipes-httpd/monkey/files/monkey.service b/meta-webserver/recipes-httpd/monkey/files/monkey.service
> new file mode 100644
> index 0000000..f9aa57f
> --- /dev/null
> +++ b/meta-webserver/recipes-httpd/monkey/files/monkey.service
> @@ -0,0 +1,12 @@
> +[Unit]
> +Description=Monkey HTTP Server
> +After=network.target remote-fs.target
> +
> +[Service]
> +Type=forking
> +ExecStart=/usr/bin/monkey --daemon
> +PIDFile=/var/run/monkey.pid.2001
> +TimeoutSec=10
> +
> +[Install]
> +WantedBy=multi-user.target
> diff --git a/meta-webserver/recipes-httpd/monkey/monkey_1.5.0.bb b/meta-webserver/recipes-httpd/monkey/monkey_1.5.1.bb
> similarity index 59%
> rename from meta-webserver/recipes-httpd/monkey/monkey_1.5.0.bb
> rename to meta-webserver/recipes-httpd/monkey/monkey_1.5.1.bb
> index 6fa1b77..7d0239e 100644
> --- a/meta-webserver/recipes-httpd/monkey/monkey_1.5.0.bb
> +++ b/meta-webserver/recipes-httpd/monkey/monkey_1.5.1.bb
> @@ -7,22 +7,24 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=2ee41112a44fe7014dce33e26468ba93"
>
> SECTION = "net"
>
> -SRC_URI = "http://monkey-project.com/releases/1.5/monkey-${PV}.tar.gz"
> -SRC_URI[md5sum] = "9123fc371334621fde1c060ab17adcd3"
> -SRC_URI[sha256sum] = "f7a5e4839822750930a723f63a4edbf700e0fb8299a4b3637bd8bab5b1d098a7"
> +SRC_URI = "http://monkey-project.com/releases/1.5/monkey-${PV}.tar.gz \
> + file://monkey.service \
> + file://monkey.init"
> +
> +SRC_URI[md5sum] = "2fe04135728f5c3a86c3a412059e0da3"
> +SRC_URI[sha256sum] = "28dfc5e57bbcd305727e7af6a1a0587868db1c1286498757bfeb72edddf457e7"
>
> EXTRA_OECONF = " \
> --plugdir=${libdir}/monkey/ \
> --logdir=${localstatedir}/log/monkey/ \
> --pidfile=${localstatedir}/run/monkey.pid \
> --default-user=www-data \
> - --datadir= ${localstatedir}/www/monkey/ \
> + --datadir=${localstatedir}/www/monkey/ \
> --sysconfdir=${sysconfdir}/monkey/ \
> --enable-plugins=* \
> --disable-plugins=polarssl \
> --debug \
> - --malloc-libc \
> -"
> + --malloc-libc"
>
> inherit autotools-brokensep pkgconfig update-rc.d systemd
>
> @@ -34,3 +36,14 @@ SYSTEMD_SERVICE_${PN} = "monkey.service"
> FILES_${PN} += "${localstatedir}/www/monkey/"
>
> CONFFILES_${PN} = "${sysconfdir}/monkey/"
> +
> +do_install_append() {
> +
> + mkdir -p ${D}${sysconfdir}/init.d
> + install -m 0755 ${WORKDIR}/monkey.init ${D}${sysconfdir}/init.d/monkey
> +
> + if ${@base_contains('DISTRO_FEATURES','systemd','true','false',d)}; then
> + install -d ${D}${systemd_unitdir}/system
> + install -m 644 ${WORKDIR}/monkey.service ${D}/${systemd_unitdir}/system
> + fi
> +}
Now it failed with:
| NOTE: Not creating empty archive for monkey-locale-1.5.1-r0.2
| *** Error: CONTROL/conffiles mentions conffile /etc/monkey/ which does not exist
|
| opkg-build: Please fix the above errors and try again.
I guess it's because sysvinit script was removed by update-rc.d.bbclass and
then nothing was left in /etc/monkey
> --
> 1.9.1
>
> --
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-devel
--
Martin 'JaMa' Jansa jabber: Martin.Jansa@gmail.com
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 188 bytes --]
next prev parent reply other threads:[~2014-07-18 18:15 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-12 6:37 [meta-webserver][PATCHv4] monkey: new v1.5.1 release Eduardo Silva
2014-07-17 17:06 ` Eduardo Silva
2014-07-18 18:15 ` Martin Jansa [this message]
2014-07-18 18:19 ` Eduardo Silva
2014-07-18 18:27 ` Martin Jansa
2014-07-20 21:15 ` Eduardo Silva
2014-07-20 21:47 ` Martin Jansa
2014-07-25 10:05 ` Martin Jansa
2014-07-26 15:03 ` Eduardo Silva
2014-07-30 20:12 ` Directories in CONFFILES Was: " Martin Jansa
2014-08-04 19:57 ` Eduardo Silva
2014-08-05 7:50 ` Martin Jansa
2014-08-07 4:51 ` Eduardo Silva
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140718181535.GQ2433@jama \
--to=martin.jansa@gmail.com \
--cc=openembedded-devel@lists.openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox