Gentoo Archives: gentoo-commits

From: Patrick McLean <chutzpah@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-admin/salt/files/, app-admin/salt/
Date: Tue, 31 Jan 2017 23:22:14
Message-Id: 1485904792.c2c2e58b596a22f0100dda08e9163ad7a09780c4.chutzpah@gentoo
1 commit: c2c2e58b596a22f0100dda08e9163ad7a09780c4
2 Author: Patrick McLean <chutzpah <AT> gentoo <DOT> org>
3 AuthorDate: Tue Jan 31 20:04:25 2017 +0000
4 Commit: Patrick McLean <chutzpah <AT> gentoo <DOT> org>
5 CommitDate: Tue Jan 31 23:19:52 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c2c2e58b
7
8 app-admin/salt: Security version bump to 2015.8.13
9
10 Gentoo-Bug: 607824
11
12 Package-Manager: Portage-2.3.3, Repoman-2.3.1
13
14 app-admin/salt/Manifest | 1 +
15 .../salt-2015.8.13-failing-gateway-tests.patch | 69 ++++++++++
16 app-admin/salt/salt-2015.8.13.ebuild | 141 +++++++++++++++++++++
17 3 files changed, 211 insertions(+)
18
19 diff --git a/app-admin/salt/Manifest b/app-admin/salt/Manifest
20 index 589341d..a68766a 100644
21 --- a/app-admin/salt/Manifest
22 +++ b/app-admin/salt/Manifest
23 @@ -1,4 +1,5 @@
24 DIST salt-2015.5.10.tar.gz 5693422 SHA256 863a96e70f8521af35fe11b10d25b3205a0bfbba9a8aee02e2842aa7106496fd SHA512 78a4cbe5c771208e957360689a25ae4e44566987e07e7fda54e6db9028485eacc6ad016c65c981090f9b5d95331e46048a094aecc27703b3956c06ab6ebad95d WHIRLPOOL 805b48df07707d85d8338251f26c72164a5421731fc11f5c933b72af97348a2f11ee35889f72ec032acbea275e98575d35786b56fd84a7917f8fdbc30567ae86
25 DIST salt-2015.8.12.tar.gz 7033938 SHA256 712f72b30a9555ea46a51bc677e05ffa2eefaeefa6b48d4f7ae45dbcb1073c69 SHA512 8ce940a413c740bd82c6c96103d48b376a47cb8161a5d72ece3f4bf6b39134bd722787a427249726dc137064d032fa913c7f6c6db22d0808ba1a829d4f25e9ec WHIRLPOOL 723660eac1346c3ba29b88c7db1a4485a194aebbdf33ea6dc411c420059767a3feb5c863941d772b504cede4a78a57e3ce696601872d21d29f4def373db697d4
26 +DIST salt-2015.8.13.tar.gz 7036243 SHA256 cca82c9a4f267692660b098c1f76e54ab6a24131391893719bde0eb3a1ed2959 SHA512 ec8626f7360542bfeea90fc3d6fd9d9d015da4c2a6adf9957c22501ed9531b0a44d2cbc4853c41856b4cd46c142d2441884ec99700f3c0a5310cc428f9f1ec2a WHIRLPOOL c21f3bdc5fd674ea664c7e8fd58ef6685328a6ee3679850f3e9a085b1e604e1224a3323b906b47075fb8dd39f373583fb549e7b0f3f725d44928bcf716955a10
27 DIST salt-2016.11.0.tar.gz 9044879 SHA256 b516285926ee95cedc64ecddab05d14422b7c8819c9f6d046a431c41d608e6bc SHA512 0cddebe9fda1f7d08aa7ee5d4e49e182c67e7bc179136da30d20c991bc10d7299034198f6721b89eda2604480aa2cfe6960f37fadde4d72adf166a065a9f6443 WHIRLPOOL 595ab7c7e50cafdfc7d69a1e24964a88092e93416dc23b295e1ab59f1ce3ae8fa10b24c4e9fe45c1d2d8557290aceae66f93d3da81a1f1be62c98e537cb8ad6a
28 DIST salt-2016.3.4.tar.gz 8354090 SHA256 5d4c822719d7fb2d79b0103cd9b015d251300890f8aa174e16b73fcfd6eb22f9 SHA512 ca17c5607d23d09e95fb4b6afbcf1b4f0be6bab47ff3eee883c1464e13b5271b71f0e7bedfa8afe05f32bf3a0a6f4050a91afb9285b52aa0f3da6105221397e0 WHIRLPOOL 95347b1f8447e8701074727430ef0a232e92aa9e961451c445890552c6d9533569e470dfa4864f673c6c3b3eccb16ec9c3615cfcab6d29e74756861afe43fcac
29
30 diff --git a/app-admin/salt/files/salt-2015.8.13-failing-gateway-tests.patch b/app-admin/salt/files/salt-2015.8.13-failing-gateway-tests.patch
31 new file mode 100644
32 index 00000000..7d8512b
33 --- /dev/null
34 +++ b/app-admin/salt/files/salt-2015.8.13-failing-gateway-tests.patch
35 @@ -0,0 +1,69 @@
36 +diff --git a/tests/unit/states/boto_vpc_test.py b/tests/unit/states/boto_vpc_test.py
37 +index 53b6a24e4d..96b5630627 100644
38 +--- a/tests/unit/states/boto_vpc_test.py
39 ++++ b/tests/unit/states/boto_vpc_test.py
40 +@@ -179,16 +179,6 @@ class BotoVpcResourceTestCaseMixin(BotoVpcTestCaseMixin):
41 + self.assertTrue(exists)
42 +
43 + @mock_ec2
44 +- def test_present_when_resource_exists(self):
45 +- vpc = self._create_vpc(name='test')
46 +- resource = self._create_resource(vpc_id=vpc.id, name='test')
47 +- with patch.dict('salt.utils.boto.__salt__', funcs):
48 +- resource_present_result = salt_states['boto_vpc.{0}_present'.format(self.resource_type)](
49 +- name='test', vpc_name='test', **self.extra_kwargs)
50 +- self.assertTrue(resource_present_result['result'])
51 +- self.assertEqual(resource_present_result['changes'], {})
52 +-
53 +- @mock_ec2
54 + @skipIf(True, 'Disabled pending https://github.com/spulec/moto/issues/493')
55 + def test_present_with_failure(self):
56 + vpc = self._create_vpc(name='test')
57 +@@ -210,18 +200,6 @@ class BotoVpcResourceTestCaseMixin(BotoVpcTestCaseMixin):
58 + self.assertEqual(resource_absent_result['changes'], {})
59 +
60 + @mock_ec2
61 +- def test_absent_when_resource_exists(self):
62 +- vpc = self._create_vpc(name='test')
63 +- self._create_resource(vpc_id=vpc.id, name='test')
64 +-
65 +- with patch.dict('salt.utils.boto.__salt__', funcs):
66 +- resource_absent_result = salt_states['boto_vpc.{0}_absent'.format(self.resource_type)]('test')
67 +- self.assertTrue(resource_absent_result['result'])
68 +- self.assertEqual(resource_absent_result['changes']['new'][self.resource_type], None)
69 +- exists = funcs['boto_vpc.resource_exists'](self.resource_type, 'test').get('exists')
70 +- self.assertFalse(exists)
71 +-
72 +- @mock_ec2
73 + @skipIf(True, 'Disabled pending https://github.com/spulec/moto/issues/493')
74 + def test_absent_with_failure(self):
75 + vpc = self._create_vpc(name='test')
76 +@@ -293,28 +271,3 @@ class BotoVpcRouteTableTestCase(BotoVpcStateTestCaseBase, BotoVpcResourceTestCas
77 +
78 + new_subnets = changes['new']['subnets_associations']
79 + self.assertEqual(new_subnets[0]['subnet_id'], subnet2.id)
80 +-
81 +- @mock_ec2
82 +- def test_present_with_routes(self):
83 +- vpc = self._create_vpc(name='test')
84 +- igw = self._create_internet_gateway(name='test', vpc_id=vpc.id)
85 +-
86 +- route_table_present_result = salt_states['boto_vpc.route_table_present'](
87 +- name='test', vpc_name='test', routes=[{'destination_cidr_block': '0.0.0.0/0',
88 +- 'gateway_id': igw.id},
89 +- {'destination_cidr_block': '10.0.0.0/24',
90 +- 'gateway_id': 'local'}])
91 +- routes = [x['gateway_id'] for x in route_table_present_result['changes']['new']['routes']]
92 +-
93 +- self.assertEqual(set(routes), set(['local', igw.id]))
94 +-
95 +- route_table_present_result = salt_states['boto_vpc.route_table_present'](
96 +- name='test', vpc_name='test', routes=[{'destination_cidr_block': '10.0.0.0/24',
97 +- 'gateway_id': 'local'}])
98 +-
99 +- changes = route_table_present_result['changes']
100 +-
101 +- old_routes = [x['gateway_id'] for x in changes['old']['routes']]
102 +- self.assertEqual(set(routes), set(old_routes))
103 +-
104 +- self.assertEqual(changes['new']['routes'][0]['gateway_id'], 'local')
105
106 diff --git a/app-admin/salt/salt-2015.8.13.ebuild b/app-admin/salt/salt-2015.8.13.ebuild
107 new file mode 100644
108 index 00000000..eed7d2d
109 --- /dev/null
110 +++ b/app-admin/salt/salt-2015.8.13.ebuild
111 @@ -0,0 +1,141 @@
112 +# Copyright 1999-2017 Gentoo Foundation
113 +# Distributed under the terms of the GNU General Public License v2
114 +# $Id$
115 +
116 +EAPI=5
117 +PYTHON_COMPAT=(python2_7)
118 +
119 +inherit eutils systemd distutils-r1
120 +
121 +DESCRIPTION="Salt is a remote execution and configuration manager"
122 +HOMEPAGE="http://saltstack.org/"
123 +
124 +if [[ ${PV} == 9999* ]]; then
125 + inherit git-r3
126 + EGIT_REPO_URI="git://github.com/${PN}stack/${PN}.git"
127 + EGIT_BRANCH="develop"
128 + SRC_URI=""
129 + KEYWORDS=""
130 +else
131 + SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
132 + KEYWORDS="~x86 ~amd64"
133 +fi
134 +
135 +LICENSE="Apache-2.0"
136 +SLOT="0"
137 +IUSE="cherrypy ldap libcloud libvirt gnupg keyring mako mongodb mysql neutron nova"
138 +IUSE+=" openssl portage profile redis selinux test timelib raet +zeromq vim-syntax"
139 +
140 +RDEPEND="sys-apps/pciutils
141 + dev-python/jinja[${PYTHON_USEDEP}]
142 + >=dev-python/msgpack-0.3[${PYTHON_USEDEP}]
143 + dev-python/pyyaml[${PYTHON_USEDEP}]
144 + dev-python/markupsafe[${PYTHON_USEDEP}]
145 + >=dev-python/requests-1.0.0[${PYTHON_USEDEP}]
146 + dev-python/setuptools[${PYTHON_USEDEP}]
147 + >=www-servers/tornado-4.2.1[${PYTHON_USEDEP}]
148 + virtual/python-futures[${PYTHON_USEDEP}]
149 + libcloud? ( >=dev-python/libcloud-0.14.0[${PYTHON_USEDEP}] )
150 + mako? ( dev-python/mako[${PYTHON_USEDEP}] )
151 + ldap? ( dev-python/python-ldap[${PYTHON_USEDEP}] )
152 + libvirt? ( dev-python/libvirt-python[${PYTHON_USEDEP}] )
153 + openssl? (
154 + dev-libs/openssl:*[-bindist]
155 + dev-python/pyopenssl[${PYTHON_USEDEP}]
156 + )
157 + raet? (
158 + >=dev-python/libnacl-1.0.0[${PYTHON_USEDEP}]
159 + >=dev-python/ioflo-1.1.7[${PYTHON_USEDEP}]
160 + >=dev-python/raet-0.6.0[${PYTHON_USEDEP}]
161 + )
162 + zeromq? (
163 + >=dev-python/pyzmq-2.2.0[${PYTHON_USEDEP}]
164 + >=dev-python/pycrypto-2.6.1[${PYTHON_USEDEP}]
165 + )
166 + cherrypy? ( >=dev-python/cherrypy-3.2.2[${PYTHON_USEDEP}] )
167 + mongodb? ( dev-python/pymongo[${PYTHON_USEDEP}] )
168 + portage? ( sys-apps/portage[${PYTHON_USEDEP}] )
169 + keyring? ( dev-python/keyring[${PYTHON_USEDEP}] )
170 + mysql? ( dev-python/mysql-python[${PYTHON_USEDEP}] )
171 + redis? ( dev-python/redis-py[${PYTHON_USEDEP}] )
172 + selinux? ( sec-policy/selinux-salt )
173 + timelib? ( dev-python/timelib[${PYTHON_USEDEP}] )
174 + nova? ( >=dev-python/python-novaclient-2.17.0[${PYTHON_USEDEP}] )
175 + neutron? ( >=dev-python/python-neutronclient-2.3.6[${PYTHON_USEDEP}] )
176 + gnupg? ( dev-python/python-gnupg[${PYTHON_USEDEP}] )
177 + profile? ( dev-python/yappi[${PYTHON_USEDEP}] )
178 + vim-syntax? ( app-vim/salt-vim )"
179 +DEPEND="dev-python/setuptools[${PYTHON_USEDEP}]
180 + test? (
181 + dev-python/psutil[${PYTHON_USEDEP}]
182 + dev-python/pip[${PYTHON_USEDEP}]
183 + dev-python/virtualenv[${PYTHON_USEDEP}]
184 + dev-python/mock[${PYTHON_USEDEP}]
185 + dev-python/timelib[${PYTHON_USEDEP}]
186 + >=dev-python/boto-2.32.1[${PYTHON_USEDEP}]
187 + >=dev-python/moto-0.3.6[${PYTHON_USEDEP}]
188 + >=dev-python/SaltTesting-2015.2.16[${PYTHON_USEDEP}]
189 + ${RDEPEND}
190 + )"
191 +
192 +DOCS=(README.rst AUTHORS)
193 +
194 +REQUIRED_USE="|| ( raet zeromq )"
195 +
196 +PATCHES=(
197 + "${FILESDIR}/${PN}-2015.8.0-remove-buggy-tests.patch"
198 + "${FILESDIR}/${PN}-2015.5.5-auth-tests.patch"
199 + "${FILESDIR}/${PN}-2015.5.5-cron-tests.patch"
200 + "${FILESDIR}/${PN}-2015.5.5-remove-buggy-tests.patch"
201 + "${FILESDIR}/${PN}-2015.8.2-tmpdir.patch"
202 + "${FILESDIR}/${PN}-2015.8.10-remove-failing-boto-test.patch"
203 + "${FILESDIR}/${PN}-2015.8.13-failing-gateway-tests.patch"
204 +)
205 +
206 +python_prepare() {
207 + # this test fails because it trys to "pip install distribute"
208 + rm tests/unit/{modules,states}/zcbuildout_test.py \
209 + tests/unit/modules/{rh_ip,win_network,random_org}_test.py
210 +}
211 +
212 +python_install_all() {
213 + local svc
214 + USE_SETUPTOOLS=1 distutils-r1_python_install_all
215 +
216 + for svc in minion master syndic api; do
217 + newinitd "${FILESDIR}"/${svc}-initd-4 salt-${svc}
218 + newconfd "${FILESDIR}"/${svc}-confd-1 salt-${svc}
219 + if [[ -e pkg/salt-${svc}.service ]]; then
220 + sed -i -r 's/After=(.*)/After=syslog.target \1/' pkg/salt-${svc}.service || die
221 + systemd_dounit pkg/salt-${svc}.service
222 + elif [[ -e "${FILESDIR}"/salt-${svc}.service ]]; then
223 + systemd_dounit "${FILESDIR}"/salt-${svc}.service
224 + fi
225 + done
226 +
227 + insinto /etc/${PN}
228 + doins -r conf/*
229 +}
230 +
231 +python_test() {
232 + local tempdir
233 + # testsuite likes lots of files
234 + ulimit -n 3072
235 +
236 + # ${T} is too long a path for the tests to work
237 + tempdir="$(mktemp -dup /tmp salt-XXX)"
238 + mkdir "${T}/$(basename "${tempdir}")"
239 +
240 + (
241 + cleanup() { rm -f "${tempdir}"; }
242 + trap cleanup EXIT
243 +
244 + addwrite "${tempdir}"
245 + ln -s "$(realpath --relative-to=/tmp "${T}/$(basename "${tempdir}")")" "${tempdir}"
246 +
247 + USE_SETUPTOOLS=1 SHELL="/bin/bash" TMPDIR="${tempdir}" \
248 + ${EPYTHON} tests/runtests.py \
249 + --unit-tests --no-report --verbose
250 +
251 + ) || die "testing failed"
252 +}