summaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-devtools
diff options
context:
space:
mode:
authorKoen Kooi <koen@dominion.thruhere.net>2011-10-10 20:11:53 +0200
committerKoen Kooi <koen@dominion.thruhere.net>2011-10-10 20:11:53 +0200
commit7ab4010c82780f15ad4d16a17f43defdb43f6d8d (patch)
tree6fdcb04d29925ff373c2ca179cf38aff3f99a571 /meta-oe/recipes-devtools
parent9278fe715d5eebd16af1a2d20a92255744913dbb (diff)
downloadmeta-openembedded-7ab4010c82780f15ad4d16a17f43defdb43f6d8d.tar.gz
cloud9: add systemd unit
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Diffstat (limited to 'meta-oe/recipes-devtools')
-rw-r--r--meta-oe/recipes-devtools/cloud9/cloud9/cloud9.service9
-rw-r--r--meta-oe/recipes-devtools/cloud9/cloud9_0.5.1.bb22
2 files changed, 29 insertions, 2 deletions
diff --git a/meta-oe/recipes-devtools/cloud9/cloud9/cloud9.service b/meta-oe/recipes-devtools/cloud9/cloud9/cloud9.service
new file mode 100644
index 000000000..027d03a86
--- /dev/null
+++ b/meta-oe/recipes-devtools/cloud9/cloud9/cloud9.service
@@ -0,0 +1,9 @@
1[Unit]
2Description=Cloud9 IDE
3ConditionPathExists=|/var/lib/cloud9
4
5[Service]
6ExecStart=/usr/bin/node /usr/share/cloud9/bin/cloud9.js -l 0.0.0.0 -w /var/lib/cloud9 -p 3000
7
8[Install]
9WantedBy=multi-user.target
diff --git a/meta-oe/recipes-devtools/cloud9/cloud9_0.5.1.bb b/meta-oe/recipes-devtools/cloud9/cloud9_0.5.1.bb
index 60506b896..8afc9e2cf 100644
--- a/meta-oe/recipes-devtools/cloud9/cloud9_0.5.1.bb
+++ b/meta-oe/recipes-devtools/cloud9/cloud9_0.5.1.bb
@@ -3,9 +3,11 @@ HOMEPAGE = "http://c9.io"
3LICENSE = "GPLv3" 3LICENSE = "GPLv3"
4LIC_FILES_CHKSUM = "file://LICENSE;md5=4784c3bcff601fd8f9515f52a11e7018" 4LIC_FILES_CHKSUM = "file://LICENSE;md5=4784c3bcff601fd8f9515f52a11e7018"
5 5
6PR = "r2" 6PR = "r3"
7 7
8SRC_URI = "git://github.com/jadonk/cloud9.git;protocol=git" 8SRC_URI = "git://github.com/jadonk/cloud9.git;protocol=git \
9 file://cloud9.service \
10 "
9 11
10SRCREV = "08bae1d1cc2ba9f7f883a25afd07f0339a82fa8b" 12SRCREV = "08bae1d1cc2ba9f7f883a25afd07f0339a82fa8b"
11S = "${WORKDIR}/git" 13S = "${WORKDIR}/git"
@@ -41,8 +43,24 @@ do_install () {
41 echo "#!/bin/sh" > ${D}${bindir}/cloud9 43 echo "#!/bin/sh" > ${D}${bindir}/cloud9
42 echo "node /usr/share/cloud9/bin/cloud9.js -l 0.0.0.0 -w /var/lib/cloud9 -p 3000" >> ${D}${bindir}/cloud9 44 echo "node /usr/share/cloud9/bin/cloud9.js -l 0.0.0.0 -w /var/lib/cloud9 -p 3000" >> ${D}${bindir}/cloud9
43 chmod 0755 ${D}${bindir}/cloud9 45 chmod 0755 ${D}${bindir}/cloud9
46
47 install -d ${D}${base_libdir}/systemd/system
48 install -m 0644 ${WORKDIR}/*.service ${base_libdir}/systemd/system/
44} 49}
45 50
51
46FILES_${PN}-dbg += "/usr/share/cloud9/support/jsdav/support/node-o3-xml-v4/lib/o3-xml/.debug" 52FILES_${PN}-dbg += "/usr/share/cloud9/support/jsdav/support/node-o3-xml-v4/lib/o3-xml/.debug"
53
54FILES_${PN} += "${base_libdir}/systemd/system"
47RDEPENDS_${PN} = "nodejs gzip" 55RDEPENDS_${PN} = "nodejs gzip"
48 56
57pkg_postinst_${PN} () {
58 # can't do this offline
59 if [ "x$D" != "x" ]; then
60 exit 1
61 fi
62
63 if [ -e ${base_bindir}/systemctl ] ; then
64 systemctl enable cloud9.service
65 fi
66}