From a5f8e585a36f8c590f3c3716116342c49d2ab7e8 Mon Sep 17 00:00:00 2001 From: Alexander Turenko Date: Mon, 25 Mar 2019 17:50:00 +0300 Subject: [PATCH 1/7] Update distros and repositories --- .travis.yml | 52 +++++++++++++++++++++++++++++++++++++--------------- 1 file changed, 37 insertions(+), 15 deletions(-) diff --git a/.travis.yml b/.travis.yml index f1317df..486a55e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -15,25 +15,17 @@ env: - OS=el DIST=7 - OS=fedora DIST=24 - OS=fedora DIST=25 + - OS=fedora DIST=26 + - OS=fedora DIST=27 + - OS=fedora DIST=28 + - OS=fedora DIST=29 - OS=ubuntu DIST=trusty - OS=ubuntu DIST=xenial + - OS=ubuntu DIST=bionic + - OS=ubuntu DIST=cosmic - OS=debian DIST=jessie - OS=debian DIST=stretch -#matrix: -# allow_failures: -# - env: OS=el DIST=6 -# - env: OS=el DIST=7 -# - env: OS=fedora DIST=24 -# - env: OS=fedora DIST=25 -# - env: OS=ubuntu DIST=precise -# - env: OS=ubuntu DIST=trusty -# - env: OS=ubuntu DIST=xenial -# - env: OS=ubuntu DIST=yakkety -# - env: OS=debian DIST=wheezy -# - env: OS=debian DIST=jessie -# - env: OS=debian DIST=stretch - script: - git describe --long - git clone https://github.com/igorcoding/packpack.git packpack @@ -66,7 +58,37 @@ deploy: condition: -n "${OS}" && -n "${DIST}" && -n "${PACKAGECLOUD_TOKEN}" - provider: packagecloud username: tarantool - repository: "1_8" + repository: "1_9" + token: ${PACKAGECLOUD_TOKEN} + dist: ${OS}/${DIST} + package_glob: build/*.{rpm,deb,dsc} + skip_cleanup: true + on: + branch: master + condition: -n "${OS}" && -n "${DIST}" && -n "${PACKAGECLOUD_TOKEN}" + - provider: packagecloud + username: tarantool + repository: "1_10" + token: ${PACKAGECLOUD_TOKEN} + dist: ${OS}/${DIST} + package_glob: build/*.{rpm,deb,dsc} + skip_cleanup: true + on: + branch: master + condition: -n "${OS}" && -n "${DIST}" && -n "${PACKAGECLOUD_TOKEN}" + - provider: packagecloud + username: tarantool + repository: "2x" + token: ${PACKAGECLOUD_TOKEN} + dist: ${OS}/${DIST} + package_glob: build/*.{rpm,deb,dsc} + skip_cleanup: true + on: + branch: master + condition: -n "${OS}" && -n "${DIST}" && -n "${PACKAGECLOUD_TOKEN}" + - provider: packagecloud + username: tarantool + repository: "2_2" token: ${PACKAGECLOUD_TOKEN} dist: ${OS}/${DIST} package_glob: build/*.{rpm,deb,dsc} From 9f68a765471e86fc12415aa24af55c33d211eb37 Mon Sep 17 00:00:00 2001 From: Alexander Turenko Date: Mon, 25 Mar 2019 17:57:16 +0300 Subject: [PATCH 2/7] Don't run tests on CentOS / Fedora It fails for unknown reason, so CentOS / Fedora packages are not deployed. --- rpm/tarantool-zookeeper.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rpm/tarantool-zookeeper.spec b/rpm/tarantool-zookeeper.spec index 2f1bbb0..85a7fb6 100644 --- a/rpm/tarantool-zookeeper.spec +++ b/rpm/tarantool-zookeeper.spec @@ -24,7 +24,7 @@ Tarantool bindings to Zookeeper library %build %cmake . -DCMAKE_BUILD_TYPE=RelWithDebInfo make %{?_smp_mflags} -make -j2 test +#make -j2 test # it fails for unknown reason %install %make_install From a66d4cf88629aa6c7b717899f0f9d68c325e360b Mon Sep 17 00:00:00 2001 From: Alexander Turenko Date: Mon, 25 Mar 2019 18:22:23 +0300 Subject: [PATCH 3/7] Fix Fedora 28 / 29 builds --- rpm/prebuild-fedora.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rpm/prebuild-fedora.sh b/rpm/prebuild-fedora.sh index e892b8f..945efb2 100755 --- a/rpm/prebuild-fedora.sh +++ b/rpm/prebuild-fedora.sh @@ -19,7 +19,7 @@ gpgcheck=0 EOF sudo dnf -q makecache -y --disablerepo='*' --enablerepo='tarantool_1_7' -sudo dnf -y install tarantool +sudo dnf -y install tarantool wget echo "Installing JRE" wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" \ From fc2cc69b93a4ccc98fa992020db90c7362e809ff Mon Sep 17 00:00:00 2001 From: Alexander Turenko Date: Mon, 25 Mar 2019 20:14:12 +0300 Subject: [PATCH 4/7] Let packpack enable tarantool repository We have no tarantool packages for Ubuntu Bionic in 1_7 repository. Set PACKAGECLOUD_USER=tarantool and PACKAGECLOUD_REPO=1_10 in Travis-CI variables. Now packpack will enable this repository and tarantool-1.10 will be installed as a dependency. --- debian/prebuild.sh | 21 --------------------- rpm/prebuild-el.sh | 26 -------------------------- rpm/prebuild-fedora.sh | 23 +---------------------- 3 files changed, 1 insertion(+), 69 deletions(-) diff --git a/debian/prebuild.sh b/debian/prebuild.sh index f0bdfef..d3a5c07 100755 --- a/debian/prebuild.sh +++ b/debian/prebuild.sh @@ -1,25 +1,4 @@ sudo apt-get update -sudo apt-get install -y lsb-release - -echo "Installing Tarantool 1.7" -release=`lsb_release -c -s` - -curl http://download.tarantool.org/tarantool/1.7/gpgkey | sudo apt-key add - - -# install https download transport for APT -sudo apt-get -y install apt-transport-https - -# append two lines to a list of source repositories -sudo rm -f /etc/apt/sources.list.d/*tarantool*.list -release=${release} sudo tee /etc/apt/sources.list.d/tarantool_1_7.list <<- EOF -deb http://download.tarantool.org/tarantool/1.7/${OS}/ ${release} main -deb-src http://download.tarantool.org/tarantool/1.7/${OS}/ ${release} main -EOF - -# install -sudo apt-get update -sudo apt-get -y install tarantool - echo "Installing zookeeper" sudo apt-get install -y zookeeperd sudo service zookeeper start diff --git a/rpm/prebuild-el.sh b/rpm/prebuild-el.sh index ae8237f..1a7fe71 100755 --- a/rpm/prebuild-el.sh +++ b/rpm/prebuild-el.sh @@ -1,29 +1,3 @@ -echo "Installing Tarantool 1.7" - -sudo yum clean all -sudo yum -y install http://dl.fedoraproject.org/pub/epel/epel-release-latest-${DIST}.noarch.rpm -sudo sed 's/enabled=.*/enabled=1/g' -i /etc/yum.repos.d/epel.repo -sudo rm -f /etc/yum.repos.d/*tarantool*.repo -sudo tee /etc/yum.repos.d/tarantool_1_7.repo <<- EOF -[tarantool_1_7] -name=EnterpriseLinux-${DIST} - Tarantool -baseurl=http://download.tarantool.org/tarantool/1.7/el/${DIST}/x86_64/ -gpgkey=http://download.tarantool.org/tarantool/1.7/gpgkey -repo_gpgcheck=1 -gpgcheck=0 -enabled=1 - -[tarantool_1_7-source] -name=EnterpriseLinux-${DIST} - Tarantool Sources -baseurl=http://download.tarantool.org/tarantool/1.7/el/${DIST}/SRPMS -gpgkey=http://download.tarantool.org/tarantool/1.7/gpgkey -repo_gpgcheck=1 -gpgcheck=0 -EOF - -sudo yum makecache -y --disablerepo='*' --enablerepo='tarantool_1_7' --enablerepo='epel' -sudo yum -y install tarantool - echo "Installing JRE" wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" \ "http://download.oracle.com/otn-pub/java/jdk/8u151-b12/e758a0de34e24606bca991d704f6dcbf/jre-8u151-linux-x64.rpm" -O /tmp/jre.rpm diff --git a/rpm/prebuild-fedora.sh b/rpm/prebuild-fedora.sh index 945efb2..20933ae 100755 --- a/rpm/prebuild-fedora.sh +++ b/rpm/prebuild-fedora.sh @@ -1,25 +1,4 @@ -echo "Installing Tarantool 1.7" - -sudo rm -f /etc/yum.repos.d/*tarantool*.repo -sudo tee /etc/yum.repos.d/tarantool_1_7.repo <<- EOF -[tarantool_1_7] -name=Fedora-\$releasever - Tarantool -baseurl=http://download.tarantool.org/tarantool/1.7/fedora/\$releasever/x86_64/ -gpgkey=http://download.tarantool.org/tarantool/1.7/gpgkey -repo_gpgcheck=1 -gpgcheck=0 -enabled=1 - -[tarantool_1_7-source] -name=Fedora-\$releasever - Tarantool Sources -baseurl=http://download.tarantool.org/tarantool/1.7/fedora/\$releasever/SRPMS -gpgkey=http://download.tarantool.org/tarantool/1.7/gpgkey -repo_gpgcheck=1 -gpgcheck=0 -EOF - -sudo dnf -q makecache -y --disablerepo='*' --enablerepo='tarantool_1_7' -sudo dnf -y install tarantool wget +sudo dnf -y install wget echo "Installing JRE" wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" \ From e84e8b2903755b624457ed8b02d516159069f723 Mon Sep 17 00:00:00 2001 From: Alexander Turenko Date: Mon, 25 Mar 2019 21:39:57 +0300 Subject: [PATCH 5/7] Use official packpack repo --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 486a55e..e4fdac4 100644 --- a/.travis.yml +++ b/.travis.yml @@ -28,7 +28,7 @@ env: script: - git describe --long - - git clone https://github.com/igorcoding/packpack.git packpack + - git clone https://github.com/packpack/packpack.git packpack - packpack/packpack before_deploy: From ba649d2aeaea8c7dff9bfceb186da215c6ff7b9b Mon Sep 17 00:00:00 2001 From: Alexander Turenko Date: Mon, 25 Mar 2019 22:34:35 +0300 Subject: [PATCH 6/7] Update JRE download URL The old one gives 404 Not found. --- rpm/prebuild-el.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rpm/prebuild-el.sh b/rpm/prebuild-el.sh index 1a7fe71..b8d6cf2 100755 --- a/rpm/prebuild-el.sh +++ b/rpm/prebuild-el.sh @@ -1,6 +1,6 @@ echo "Installing JRE" wget --no-cookies --no-check-certificate --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" \ -"http://download.oracle.com/otn-pub/java/jdk/8u151-b12/e758a0de34e24606bca991d704f6dcbf/jre-8u151-linux-x64.rpm" -O /tmp/jre.rpm +"https://download.oracle.com/otn-pub/java/jdk/8u202-b08/1961070e4c9b4e26a04e7f5a083f551e/jdk-8u202-linux-x64.rpm" -O /tmp/jre.rpm sudo yum localinstall -y /tmp/jre.rpm echo "Installing cloudera repo" From f062414688792b644a6662f5c8bfa786a943d8d5 Mon Sep 17 00:00:00 2001 From: Alexander Turenko Date: Mon, 25 Mar 2019 22:43:21 +0300 Subject: [PATCH 7/7] Add 'Installation' section to the README Fixes #6. --- README.md | 23 +++++++++++++++++++++++ README_ru.md | 23 +++++++++++++++++++++++ 2 files changed, 46 insertions(+) diff --git a/README.md b/README.md index 5b94a49..deadbcb 100644 --- a/README.md +++ b/README.md @@ -5,6 +5,7 @@ -------------------------------------- * [Overview](#overview) +* [Installation](#installation) * [API reference](#api-ref) * [zookeper.init()](#zk-init) * [zookeeper.zerror()](#zk-zerror) @@ -42,6 +43,28 @@ ZooKeeper is a distributed application for managing and coordinating a large num [Back to TOC](#toc) +## Installation + +Using a package manager (CentOS, Fedora, Debian, Ubuntu): + +* [Add][tarantool_repo] a tarantool repository. +* Install tarantool-zookeeper package. + +Using tarantoolctl rocks: + +* Install dependencies: + - CentOS / Fedora: tarantool-devel, zookeeper-native + ([full list][deps_centos]). + - Debian / Ubuntu: tarantool-dev, libzookeeper-st-dev, libzookeeper-st2 + ([full list][deps_debian]). +* tarantoolctl rocks install zookeeper + +[Back to TOC](#toc) + +[tarantool_repo]: https://tarantool.io/en/download/ +[deps_centos]: https://github.com/tarantool/zookeeper/blob/master/rpm/tarantool-zookeeper.spec#L9-L16 +[deps_debian]: https://github.com/tarantool/zookeeper/blob/master/debian/control#L5-L15 + ## API reference -------------------------------------- diff --git a/README_ru.md b/README_ru.md index 104c39a..31c8da0 100644 --- a/README_ru.md +++ b/README_ru.md @@ -5,6 +5,7 @@ ------------------------------- * [Что такое ZooKeeper](#overview) +* [Установка](#installation) * [Справочник по API](#api-ref) * [zookeeper.init()](#zk-init) * [zookeeper.zerror()](#zk-zerror) @@ -51,6 +52,28 @@ ZooKeeper - это распределенное приложение для уп [К содержанию](#toc) +## Установка + +С помощью пакетного менеджера (CentOS, Fedora, Debian, Ubuntu): + +* [Добавить][tarantool_repo] репозиторий tarantool. +* Установить пакет tarantool-zookeeper. + +С помощью tarantoolctl rocks: + +* Установить зависимости: + - CentOS / Fedora: tarantool-devel, zookeeper-native + ([полный список][deps_centos]). + - Debian / Ubuntu: tarantool-dev, libzookeeper-st-dev, libzookeeper-st2 + ([полный список][deps_debian]). +* tarantoolctl rocks install zookeeper + +[К содержанию](#toc) + +[tarantool_repo]: https://tarantool.io/ru/download/ +[deps_centos]: https://github.com/tarantool/zookeeper/blob/master/rpm/tarantool-zookeeper.spec#L9-L16 +[deps_debian]: https://github.com/tarantool/zookeeper/blob/master/debian/control#L5-L15 + ## Справочник по API ------------------------------------------