summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app-admin/salt/Manifest1
-rw-r--r--app-admin/salt/files/salt-2018.3.2-skip-zeromq-test-that-hangs.patch79
-rw-r--r--app-admin/salt/salt-2018.3.2.ebuild155
3 files changed, 235 insertions, 0 deletions
diff --git a/app-admin/salt/Manifest b/app-admin/salt/Manifest
index 56db125c7c72..643d0900419e 100644
--- a/app-admin/salt/Manifest
+++ b/app-admin/salt/Manifest
@@ -1,3 +1,4 @@
DIST salt-2016.11.9.tar.gz 10062996 BLAKE2B 5176d04d07a69de21c9c136c201d334614c5675fd78e306a0160fae829b633441cd859f4ba1a0822dfbb9ae716475c53f6eb058187d4acc8a5770dd4ceace577 SHA512 896fd27c111e926e246b51d00b69d41c8f4d25ec0c034c9ff3dc5414f5e93592fd637cdeaecf02b3b98a4e5a7ce478bfda86b15497961078374608d76516593d
DIST salt-2017.7.5.tar.gz 11043026 BLAKE2B 9cae4e6ca3b0bac0dc0b9b9a5ae01e0bfb8e8b899aa029b324ac10c8c84024bbc419ace068cd0d2bff84ec6ddf1d13faf68ce34c68c19892c700c38e81da8c7c SHA512 684ffde7d98c73349b386c94de3d9fc09631a78c5d74e37e6dfd90fbb0c94decc529f56b1eba1559ce9932b16083f88e6495ff6cdf071b32a23028e9db47cc3d
DIST salt-2018.3.0.tar.gz 13448567 BLAKE2B 9048f9e507ded238bfd54d0aabfefb56522b20ba2479c3bf5aefc47fff0b6ce516709ad6e9109441941a60596d4f06a43c1448a149225f3f87715327a190d313 SHA512 3d64a4d12d4ff7effe644b682b138d8f49fd00523e9cfe3e80bebff9c944a089fb41cbac92e63139633425f49c1eebeb99145290a0bdd1b4f306da86abe9b2e5
+DIST salt-2018.3.2.tar.gz 12996445 BLAKE2B 8411fb0891e23ce8e35157662a0a45c0c5b13b62f3fd21cc4bbe5152f923a98b27cb5bee4fb8cb3e6ec5c9daed1afa27baf4b570b94f9f40eddc0891f72829e9 SHA512 142ebe13638d7e6dd0aecc9f0325002d30e115fe8688f5f74cbeb7ff21020327d65ded0dcd845e55362b97568b696887fa22243d66d5eadef65f97152d4775d3
diff --git a/app-admin/salt/files/salt-2018.3.2-skip-zeromq-test-that-hangs.patch b/app-admin/salt/files/salt-2018.3.2-skip-zeromq-test-that-hangs.patch
new file mode 100644
index 000000000000..7b94fafd447d
--- /dev/null
+++ b/app-admin/salt/files/salt-2018.3.2-skip-zeromq-test-that-hangs.patch
@@ -0,0 +1,79 @@
+diff --git a/tests/unit/transport/test_zeromq.py b/tests/unit/transport/test_zeromq.py
+index ccb337462e..97d2962e5e 100644
+--- a/tests/unit/transport/test_zeromq.py
++++ b/tests/unit/transport/test_zeromq.py
+@@ -45,6 +45,10 @@ ON_SUSE = False
+ if 'SuSE' in linux_distribution(full_distribution_name=False):
+ ON_SUSE = True
+
++ON_GENTOO = False
++if 'Gentoo' in linux_distribution(full_distribution_name=False):
++ ON_GENTOO = True
++
+
+ class BaseZMQReqCase(TestCase, AdaptedConfigurationTestCaseMixin):
+ '''
+@@ -122,63 +126,6 @@ class BaseZMQReqCase(TestCase, AdaptedConfigurationTestCaseMixin):
+ return payload, {'fun': 'send_clear'}
+
+
+-class ClearReqTestCases(BaseZMQReqCase, ReqChannelMixin):
+- '''
+- Test all of the clear msg stuff
+- '''
+- def setUp(self):
+- self.channel = salt.transport.client.ReqChannel.factory(self.minion_config, crypt='clear')
+-
+- def tearDown(self):
+- del self.channel
+-
+- @classmethod
+- @tornado.gen.coroutine
+- def _handle_payload(cls, payload):
+- '''
+- TODO: something besides echo
+- '''
+- raise tornado.gen.Return((payload, {'fun': 'send_clear'}))
+-
+-
+-@flaky
+-@skipIf(ON_SUSE, 'Skipping until https://github.com/saltstack/salt/issues/32902 gets fixed')
+-class AESReqTestCases(BaseZMQReqCase, ReqChannelMixin):
+- def setUp(self):
+- self.channel = salt.transport.client.ReqChannel.factory(self.minion_config)
+-
+- def tearDown(self):
+- del self.channel
+-
+- @classmethod
+- @tornado.gen.coroutine
+- def _handle_payload(cls, payload):
+- '''
+- TODO: something besides echo
+- '''
+- raise tornado.gen.Return((payload, {'fun': 'send'}))
+-
+- # TODO: make failed returns have a specific framing so we can raise the same exception
+- # on encrypted channels
+- #
+- #!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+- #
+- # WARNING: This test will fail randomly on any system with > 1 CPU core!!!
+- #
+- #!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+- def test_badload(self):
+- '''
+- Test a variety of bad requests, make sure that we get some sort of error
+- '''
+- # TODO: This test should be re-enabled when Jenkins moves to C7.
+- # Once the version of salt-testing is increased to something newer than the September
+- # release of salt-testing, the @flaky decorator should be applied to this test.
+- msgs = ['', [], tuple()]
+- for msg in msgs:
+- with self.assertRaises(salt.exceptions.AuthenticationError):
+- ret = self.channel.send(msg, timeout=5)
+-
+-
+ class BaseZMQPubCase(AsyncTestCase, AdaptedConfigurationTestCaseMixin):
+ '''
+ Test the req server/client pair
diff --git a/app-admin/salt/salt-2018.3.2.ebuild b/app-admin/salt/salt-2018.3.2.ebuild
new file mode 100644
index 000000000000..fff0c84f2aca
--- /dev/null
+++ b/app-admin/salt/salt-2018.3.2.ebuild
@@ -0,0 +1,155 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+PYTHON_COMPAT=( python2_7 python3_6 )
+
+inherit eutils systemd distutils-r1
+
+DESCRIPTION="Salt is a remote execution and configuration manager"
+HOMEPAGE="http://saltstack.org/"
+
+if [[ ${PV} == 9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="git://github.com/${PN}stack/${PN}.git"
+ EGIT_BRANCH="develop"
+ SRC_URI=""
+ KEYWORDS=""
+else
+ SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+ KEYWORDS="~x86 ~amd64"
+fi
+
+LICENSE="Apache-2.0"
+SLOT="0"
+IUSE="cherrypy ldap libcloud libvirt gnupg keyring mako mongodb mysql neutron nova"
+IUSE+=" openssl portage profile redis selinux test timelib raet +zeromq vim-syntax"
+
+RDEPEND="sys-apps/pciutils
+ dev-python/jinja[${PYTHON_USEDEP}]
+ dev-python/libnacl[${PYTHON_USEDEP}]
+ >=dev-python/msgpack-0.3[${PYTHON_USEDEP}]
+ dev-python/pyyaml[${PYTHON_USEDEP}]
+ dev-python/markupsafe[${PYTHON_USEDEP}]
+ >=dev-python/requests-1.0.0[${PYTHON_USEDEP}]
+ dev-python/setuptools[${PYTHON_USEDEP}]
+ >=www-servers/tornado-4.2.1[${PYTHON_USEDEP}]
+ <www-servers/tornado-5.0[${PYTHON_USEDEP}]
+ virtual/python-futures[${PYTHON_USEDEP}]
+ libcloud? ( >=dev-python/libcloud-0.14.0[${PYTHON_USEDEP}] )
+ mako? ( dev-python/mako[${PYTHON_USEDEP}] )
+ ldap? ( dev-python/python-ldap[${PYTHON_USEDEP}] )
+ libvirt? ( dev-python/libvirt-python[${PYTHON_USEDEP}] )
+ openssl? (
+ dev-libs/openssl:*[-bindist]
+ dev-python/pyopenssl[${PYTHON_USEDEP}]
+ )
+ raet? (
+ >=dev-python/libnacl-1.0.0[${PYTHON_USEDEP}]
+ >=dev-python/ioflo-1.1.7[${PYTHON_USEDEP}]
+ >=dev-python/raet-0.6.0[${PYTHON_USEDEP}]
+ )
+ zeromq? (
+ >=dev-python/pyzmq-2.2.0[${PYTHON_USEDEP}]
+ dev-python/pycryptodome[${PYTHON_USEDEP}]
+ )
+ cherrypy? ( >=dev-python/cherrypy-3.2.2[${PYTHON_USEDEP}] )
+ mongodb? ( dev-python/pymongo[${PYTHON_USEDEP}] )
+ portage? (
+ || (
+ sys-apps/portage[${PYTHON_USEDEP}]
+ sys-apps/portage-mgorny[${PYTHON_USEDEP}]
+ )
+ )
+ keyring? ( dev-python/keyring[${PYTHON_USEDEP}] )
+ mysql? ( dev-python/mysql-python[$(python_gen_usedep 'python2*')] )
+ redis? ( dev-python/redis-py[${PYTHON_USEDEP}] )
+ selinux? ( sec-policy/selinux-salt )
+ timelib? ( dev-python/timelib[$(python_gen_usedep 'python2*')] )
+ nova? ( >=dev-python/python-novaclient-2.17.0[${PYTHON_USEDEP}] )
+ neutron? ( >=dev-python/python-neutronclient-2.3.6[${PYTHON_USEDEP}] )
+ gnupg? ( dev-python/python-gnupg[${PYTHON_USEDEP}] )
+ profile? ( dev-python/yappi[${PYTHON_USEDEP}] )
+ vim-syntax? ( app-vim/salt-vim )"
+DEPEND="dev-python/setuptools[${PYTHON_USEDEP}]
+ test? (
+ dev-python/pytest-salt[${PYTHON_USEDEP}]
+ dev-python/psutil[${PYTHON_USEDEP}]
+ dev-python/pytest[${PYTHON_USEDEP}]
+ dev-python/pytest-catchlog[${PYTHON_USEDEP}]
+ dev-python/pip[${PYTHON_USEDEP}]
+ dev-python/virtualenv[${PYTHON_USEDEP}]
+ >=dev-python/mock-2.0.0[${PYTHON_USEDEP}]
+ dev-python/timelib[$(python_gen_usedep 'python2*')]
+ >=dev-python/boto-2.32.1[${PYTHON_USEDEP}]
+ !x86? ( >=dev-python/boto3-1.2.1[${PYTHON_USEDEP}] )
+ >=dev-python/moto-0.3.6[${PYTHON_USEDEP}]
+ >=dev-python/SaltTesting-2016.5.11[${PYTHON_USEDEP}]
+ >=dev-python/libcloud-0.14.0[${PYTHON_USEDEP}]
+ ${RDEPEND}
+ )"
+
+DOCS=( README.rst AUTHORS )
+
+REQUIRED_USE="|| ( raet zeromq )"
+RESTRICT="x86? ( test )"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-2017.7.0-dont-realpath-tmpdir.patch"
+ "${FILESDIR}/${PN}-2017.7.3-tests.patch"
+ "${FILESDIR}/${PN}-2018.3.2-skip-zeromq-test-that-hangs.patch"
+)
+
+python_prepare() {
+ # remove tests with external dependencies that may not be available
+ rm tests/unit/{test_zypp_plugins.py,utils/test_extend.py} || die
+ rm tests/unit/modules/test_boto_{vpc,secgroup,elb}.py || die
+ rm tests/unit/states/test_boto_vpc.py || die
+ rm tests/unit/modules/test_{kubernetes,vsphere}.py || die
+
+ # allow the use of the renamed msgpack
+ sed -i '/^msgpack/d' requirements/base.txt || die
+}
+
+python_install_all() {
+ local svc
+ USE_SETUPTOOLS=1 distutils-r1_python_install_all
+
+ for svc in minion master syndic api; do
+ newinitd "${FILESDIR}"/${svc}-initd-4 salt-${svc}
+ newconfd "${FILESDIR}"/${svc}-confd-1 salt-${svc}
+ systemd_dounit "${FILESDIR}"/salt-${svc}.service
+ done
+
+ insinto /etc/${PN}
+ doins -r conf/*
+}
+
+python_test() {
+ local tempdir
+ # testsuite likes lots of files
+ ulimit -n 3072 || die
+
+ # ${T} is too long a path for the tests to work
+ tempdir="$(mktemp -du --tmpdir=/tmp salt-XXX)"
+ mkdir "${T}/$(basename "${tempdir}")"
+ mkdir "${BUILD_DIR}"/../{templates,conf/cloud.{providers,profiles,maps}.d} || die
+
+ (
+ cleanup() {
+ rm -f "${tempdir}"
+ rmdir "${BUILD_DIR}"/../{templates,conf/cloud.{providers,profiles,maps}.d} || die
+ }
+
+ trap cleanup EXIT
+
+ addwrite "${tempdir}"
+ ln -s "$(realpath --relative-to=/tmp "${T}/$(basename "${tempdir}")")" "${tempdir}"
+
+ USE_SETUPTOOLS=1 SHELL="/bin/bash" \
+ TMPDIR="${tempdir}" \
+ ${EPYTHON} tests/runtests.py \
+ --unit-tests --no-report --verbose
+
+ ) || die "testing failed"
+}