[oe-commits] leimh : geoipupdate: add new recipe

git at git.openembedded.org git at git.openembedded.org
Wed Dec 31 15:47:09 UTC 2014


Module: meta-openembedded.git
Branch: master-next
Commit: 0936c01dc169ddd3a4dc62dd1a3cb58546d74162
URL:    http://git.openembedded.org/?p=meta-openembedded.git&a=commit;h=0936c01dc169ddd3a4dc62dd1a3cb58546d74162

Author: leimh <leimaohui at cn.fujitsu.com>
Date:   Fri Dec 26 14:23:26 2014 +0800

geoipupdate: add new recipe

for update the IP geolocation databases

Signed-off-by: leimh <leimaohui at cn.fujitsu.com>
Signed-off-by: Martin Jansa <Martin.Jansa at gmail.com>

---

 .../GeoIP/geoipupdate-2.1.0/GeoIP.conf             | 11 +++++++++
 .../GeoIP/geoipupdate-2.1.0/geoipupdate.cron       |  5 +++++
 .../recipes-support/GeoIP/geoipupdate_2.1.0.bb     | 26 ++++++++++++++++++++++
 3 files changed, 42 insertions(+)

diff --git a/meta-networking/recipes-support/GeoIP/geoipupdate-2.1.0/GeoIP.conf b/meta-networking/recipes-support/GeoIP/geoipupdate-2.1.0/GeoIP.conf
new file mode 100644
index 0000000..134cfed
--- /dev/null
+++ b/meta-networking/recipes-support/GeoIP/geoipupdate-2.1.0/GeoIP.conf
@@ -0,0 +1,11 @@
+# The following UserId and LicenseKey are required placeholders:
+UserId 999999
+LicenseKey 000000000000
+
+# Include one or more of the following ProductIds:
+# * GeoLite2-City - GeoLite 2 City
+# * GeoLite2-Country - GeoLite2 Country
+# * 506 - GeoLite Legacy Country
+# * 517 - GeoLite Legacy ASN
+# * 533 - GeoLite Legacy City
+ProductIds GeoLite2-City GeoLite2-Country 506 517 533
diff --git a/meta-networking/recipes-support/GeoIP/geoipupdate-2.1.0/geoipupdate.cron b/meta-networking/recipes-support/GeoIP/geoipupdate-2.1.0/geoipupdate.cron
new file mode 100644
index 0000000..40597a8
--- /dev/null
+++ b/meta-networking/recipes-support/GeoIP/geoipupdate-2.1.0/geoipupdate.cron
@@ -0,0 +1,5 @@
+# top of crontab
+MAILTO=your at email.com
+
+32 11 * * 4 /usr/local/bin/geoipupdate
+# end of crontab
diff --git a/meta-networking/recipes-support/GeoIP/geoipupdate_2.1.0.bb b/meta-networking/recipes-support/GeoIP/geoipupdate_2.1.0.bb
new file mode 100644
index 0000000..0de8a4d
--- /dev/null
+++ b/meta-networking/recipes-support/GeoIP/geoipupdate_2.1.0.bb
@@ -0,0 +1,26 @@
+require GeoIP.inc
+DEPENDS = "zlib curl"
+
+
+SRC_URI = "https://github.com/maxmind/geoipupdate/releases/download/v2.1.0/geoipupdate-2.1.0.tar.gz \
+           file://GeoIP.conf \
+           file://geoipupdate.cron \
+          "
+
+SRC_URI[md5sum] = "9107d082f15c8e482f4b6f1080e7deaf"
+SRC_URI[sha256sum] = "7388c46f6c483ae609e5f5333a2585bc9713d56bb522da5c11b09d41c87aa5fb"
+
+LICENSE = "GPLv2"
+
+LIC_FILES_CHKSUM = "\
+file://ChangeLog.md;md5=25f3500fad03ad7e6bf135b29c9c7c2d \
+"
+
+inherit autotools
+
+do_install_append() {
+    install -d ${D}/${sysconfdir}
+    install -d ${D}/${sysconfdir}/cron.d
+    install ${WORKDIR}/GeoIP.conf ${D}/${sysconfdir}/
+    install ${WORKDIR}/geoipupdate.cron ${D}/${sysconfdir}/cron.d/
+}



More information about the Openembedded-commits mailing list