From a448d9a2e53d2189f50ef232f4f138c525a47564 Mon Sep 17 00:00:00 2001 From: tkl Date: Wed, 7 Apr 2021 07:17:42 +0200 Subject: [PATCH] recipes-app: Add recipe for greenhouse web app --- recipes-app/greenhouse/files/run.sh | 3 +++ recipes-app/greenhouse/greenhouse.bb | 35 ++++++++++++++++++++++++++++ 2 files changed, 38 insertions(+) create mode 100644 recipes-app/greenhouse/files/run.sh create mode 100644 recipes-app/greenhouse/greenhouse.bb diff --git a/recipes-app/greenhouse/files/run.sh b/recipes-app/greenhouse/files/run.sh new file mode 100644 index 0000000..cb8b66d --- /dev/null +++ b/recipes-app/greenhouse/files/run.sh @@ -0,0 +1,3 @@ +#!/bin/sh + +gunicorn --bind 0.0.0.0:80 greenhouse:app diff --git a/recipes-app/greenhouse/greenhouse.bb b/recipes-app/greenhouse/greenhouse.bb new file mode 100644 index 0000000..29f0d7b --- /dev/null +++ b/recipes-app/greenhouse/greenhouse.bb @@ -0,0 +1,35 @@ +SUMMARY = "Greenhouse control" +SECTION = "Applications" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302" + +FILESEXTRAPATHS_prepend := "${THISDIR}/files:" + +PR = "r0" +SRCREV = "${AUTOREV}" +SRC_URI = " \ + git://git.blackfinn.de/python/greenhouse.git;protocol=https;branch=master \ + file://run.sh \ +" + +S = "${WORKDIR}/git" + +do_install_append () { + install -d ${D}/usr/ + install -d ${D}/usr/bin/ + install -m 0755 ${WORKDIR}/run.sh ${D}/usr/bin/ +} + +RDEPENDS_${PN} += " \ + python3 \ + python3-gunicorn \ + python3-flask \ + rpi.gpio \ + w1thermsensor \ +" + +FILES_${PN} = " \ + /usr/bin/run.sh \ +" + +inherit setuptools3