mirror of
https://github.com/valitydev/salt.git
synced 2024-11-06 00:25:22 +00:00
Merge branch 'master' into feature/slack_webhook_returner
This commit is contained in:
commit
f6cf18efe1
@ -11,6 +11,7 @@ def golden_images_branch = 'master'
|
||||
def nox_passthrough_opts = ''
|
||||
def use_spot_instances = true
|
||||
def jenkins_slave_label = 'kitchen-slave'
|
||||
def kitchen_platforms_file = '/var/jenkins/workspace/nox-cloud-platforms.yml'
|
||||
|
||||
properties([
|
||||
buildDiscarder(logRotator(artifactDaysToKeepStr: '', artifactNumToKeepStr: '', daysToKeepStr: '', numToKeepStr: '30')),
|
||||
@ -30,6 +31,7 @@ runTests(
|
||||
testrun_timeout: testrun_timeout,
|
||||
run_full: params.runFull,
|
||||
use_spot_instances: use_spot_instances,
|
||||
jenkins_slave_label: jenkins_slave_label)
|
||||
jenkins_slave_label: jenkins_slave_label,
|
||||
kitchen_platforms_file: kitchen_platforms_file)
|
||||
|
||||
// vim: ft=groovy
|
||||
|
@ -11,6 +11,7 @@ def golden_images_branch = 'master'
|
||||
def nox_passthrough_opts = ''
|
||||
def use_spot_instances = true
|
||||
def jenkins_slave_label = 'kitchen-slave'
|
||||
def kitchen_platforms_file = '/var/jenkins/workspace/nox-cloud-platforms.yml'
|
||||
|
||||
properties([
|
||||
buildDiscarder(logRotator(artifactDaysToKeepStr: '', artifactNumToKeepStr: '', daysToKeepStr: '', numToKeepStr: '30')),
|
||||
@ -30,6 +31,7 @@ runTests(
|
||||
testrun_timeout: testrun_timeout,
|
||||
run_full: params.runFull,
|
||||
use_spot_instances: use_spot_instances,
|
||||
jenkins_slave_label: jenkins_slave_label)
|
||||
jenkins_slave_label: jenkins_slave_label,
|
||||
kitchen_platforms_file: kitchen_platforms_file)
|
||||
|
||||
// vim: ft=groovy
|
||||
|
48
.ci/kitchen-centos8-py3
Normal file
48
.ci/kitchen-centos8-py3
Normal file
@ -0,0 +1,48 @@
|
||||
@Library('salt@master-1.3') _
|
||||
|
||||
// Define the maximum time, in hours, that a test run should run for
|
||||
def testrun_timeout = 6
|
||||
|
||||
def distro_name = 'centos'
|
||||
def distro_version = '8'
|
||||
def python_version = 'py3'
|
||||
def nox_env_name = 'runtests-zeromq'
|
||||
def golden_images_branch = 'master'
|
||||
def nox_passthrough_opts = '--ssh-tests'
|
||||
def concurrent_builds = 1
|
||||
def use_spot_instances = true
|
||||
def jenkins_slave_label = 'kitchen-slave'
|
||||
|
||||
properties([
|
||||
buildDiscarder(logRotator(artifactDaysToKeepStr: '', artifactNumToKeepStr: '', daysToKeepStr: '', numToKeepStr: '30')),
|
||||
parameters([
|
||||
booleanParam(defaultValue: true, description: 'Run full test suite', name: 'runFull')
|
||||
])
|
||||
])
|
||||
|
||||
// Only set milestones on PR builds
|
||||
if (env.CHANGE_ID) {
|
||||
// Be sure to cancel any previously running builds
|
||||
def buildNumber = env.BUILD_NUMBER as int
|
||||
if (buildNumber > concurrent_builds) {
|
||||
// This will cancel the previous build which also defined a matching milestone
|
||||
milestone(buildNumber - concurrent_builds)
|
||||
}
|
||||
// Define a milestone for this build so that, if another build starts, this one will be aborted
|
||||
milestone(buildNumber)
|
||||
}
|
||||
|
||||
runTests(
|
||||
env: env,
|
||||
distro_name: distro_name,
|
||||
distro_version: distro_version,
|
||||
python_version: python_version,
|
||||
golden_images_branch: golden_images_branch,
|
||||
nox_env_name: nox_env_name,
|
||||
nox_passthrough_opts: nox_passthrough_opts,
|
||||
testrun_timeout: testrun_timeout,
|
||||
run_full: params.runFull,
|
||||
use_spot_instances: use_spot_instances,
|
||||
jenkins_slave_label: jenkins_slave_label)
|
||||
|
||||
// vim: ft=groovy
|
@ -433,6 +433,7 @@ def install(pkgs=None, # pylint: disable=R0912,R0913,R0914
|
||||
no_cache_dir=False,
|
||||
cache_dir=None,
|
||||
no_binary=None,
|
||||
disable_version_check=False,
|
||||
**kwargs):
|
||||
'''
|
||||
Install packages with pip
|
||||
@ -604,6 +605,11 @@ def install(pkgs=None, # pylint: disable=R0912,R0913,R0914
|
||||
no_cache_dir
|
||||
Disable the cache.
|
||||
|
||||
disable_version_check
|
||||
Pip may periodically check PyPI to determine whether a new version of
|
||||
pip is available to download. Passing True for this option disables
|
||||
that check.
|
||||
|
||||
CLI Example:
|
||||
|
||||
.. code-block:: bash
|
||||
@ -756,6 +762,9 @@ def install(pkgs=None, # pylint: disable=R0912,R0913,R0914
|
||||
)
|
||||
cmd.extend(['--mirrors', mirror])
|
||||
|
||||
if disable_version_check:
|
||||
cmd.extend(['--disable-pip-version-check'])
|
||||
|
||||
if build:
|
||||
cmd.extend(['--build', build])
|
||||
|
||||
|
@ -901,6 +901,7 @@ def installed(name,
|
||||
use_vt=use_vt,
|
||||
trusted_host=trusted_host,
|
||||
no_cache_dir=no_cache_dir,
|
||||
disable_version_check=True,
|
||||
**kwargs
|
||||
)
|
||||
|
||||
|
56
salt/templates/rh_ip/rh8_eth.jinja
Normal file
56
salt/templates/rh_ip/rh8_eth.jinja
Normal file
@ -0,0 +1,56 @@
|
||||
DEVICE="{{name}}"
|
||||
{% if nickname %}NAME="{{nickname}}"
|
||||
{%endif%}{% if hwaddr %}HWADDR="{{hwaddr}}"
|
||||
{%endif%}{% if macaddr %}MACADDR="{{macaddr}}"
|
||||
{%endif%}{% if uuid %}UUID="{{uuid}}"
|
||||
{%endif%}{% if userctl %}USERCTL="{{userctl}}"
|
||||
{%endif%}{% if master %}MASTER="{{master}}"
|
||||
{%endif%}{% if slave %}SLAVE="{{slave}}"
|
||||
{%endif%}{% if vlan %}VLAN="{{vlan}}"
|
||||
{% if reorder_hdr %}REORDER_HDR="{{reorder_hdr}}"
|
||||
{%endif%}{% if vlan_id %}VID="{{vlan_id}}"
|
||||
{%endif%}{% if phys_dev %}PHYSDEV="{{phys_dev}}"
|
||||
{%endif%}{%endif%}{% if devtype %}TYPE="{{devtype}}"
|
||||
{%endif%}{% if proto %}BOOTPROTO="{{proto}}"
|
||||
{%endif%}{% if onboot %}ONBOOT="{{onboot}}"
|
||||
{%endif%}{% if onparent %}ONPARENT={{onparent}}
|
||||
{%endif%}{% if ipv4_failure_fatal %}IPV4_FAILURE_FATAL="{{ipv4_failure_fatal}}"
|
||||
{%endif%}{% if ipaddr %}IPADDR="{{ipaddr}}"
|
||||
{%endif%}{% if ipaddr_start %}IPADDR_START="{{ipaddr_start}}"
|
||||
{%endif%}{% if ipaddr_end %}IPADDR_END="{{ipaddr_end}}"
|
||||
{%endif%}{% if clonenum_start %}CLONENUM_START="{{clonenum_start}}"
|
||||
{%endif%}{% if netmask %}NETMASK="{{netmask}}"
|
||||
{%endif%}{% if prefix %}PREFIX="{{prefix}}"
|
||||
{%endif%}{% if ipaddrs %}{% for i in ipaddrs -%}
|
||||
IPADDR{{loop.index}}="{{i['ipaddr']}}"
|
||||
PREFIX{{loop.index}}="{{i['prefix']}}"
|
||||
{% endfor -%}
|
||||
{%endif%}{% if gateway %}GATEWAY="{{gateway}}"
|
||||
{%endif%}{% if enable_ipv6 %}IPV6INIT="yes"
|
||||
{% if ipv6_autoconf %}IPV6_AUTOCONF="{{ipv6_autoconf}}"
|
||||
{%endif%}{% if dhcpv6c %}DHCPV6C="{{dhcpv6c}}"
|
||||
{%endif%}{% if ipv6addr %}IPV6ADDR="{{ipv6addr}}"
|
||||
{%endif%}{% if ipv6gateway %}IPV6_DEFAULTGW="{{ipv6gateway}}"
|
||||
{%endif%}{% if ipv6addrs %}IPV6ADDR_SECONDARIES="{{ ipv6addrs|join(' ') }}"
|
||||
{%endif%}{% if ipv6_peerdns %}IPV6_PEERDNS="{{ipv6_peerdns}}"
|
||||
{%endif%}{% if ipv6_defroute %}IPV6_DEFROUTE="{{ipv6_defroute}}"
|
||||
{%endif%}{% if ipv6_peerroutes %}IPV6_PEERROUTES="{{ipv6_peerroutes}}"
|
||||
{%endif%}{%endif%}{% if srcaddr %}SRCADDR="{{srcaddr}}"
|
||||
{%endif%}{% if peerdns %}PEERDNS="{{peerdns}}"
|
||||
{%endif%}{% if peerroutes %}PEERROUTES="{{peerroutes}}"
|
||||
{%endif%}{% if peerntp %}PEERNTP="{{peerntp}}"
|
||||
{%endif%}{% if defroute %}DEFROUTE="{{defroute}}"
|
||||
{%endif%}{% if bridge %}BRIDGE="{{bridge}}"
|
||||
{%endif%}{% if stp %}STP="{{stp}}"
|
||||
{%endif%}{% if delay or delay == 0 %}DELAY="{{delay}}"
|
||||
{%endif%}{% if mtu %}MTU="{{mtu}}"
|
||||
{%endif%}{% if zone %}ZONE="{{zone}}"
|
||||
{%endif%}{% if my_inner_ipaddr %}MY_INNER_IPADDR={{my_inner_ipaddr}}
|
||||
{%endif%}{% if my_outer_ipaddr %}MY_OUTER_IPADDR={{my_outer_ipaddr}}
|
||||
{%endif%}{% if bonding %}BONDING_OPTS="{%for item in bonding %}{{item}}={{bonding[item]}} {%endfor%}"
|
||||
{%endif%}{% if ethtool %}ETHTOOL_OPTS="{%for item in ethtool %}{{item}} {{ethtool[item]}} {%endfor%}"
|
||||
{%endif%}{% if domain %}DOMAIN="{{ domain|join(' ') }}"
|
||||
{%endif%}{% if nm_controlled %}NM_CONTROLLED="{{nm_controlled}}"
|
||||
{% endif %}{% for server in dns -%}
|
||||
DNS{{loop.index}}="{{server}}"
|
||||
{% endfor -%}
|
@ -45,10 +45,7 @@ class VultrTest(CloudTest):
|
||||
Tests the return of running the --list-sizes command for Vultr
|
||||
'''
|
||||
size_list = self.run_cloud('--list-sizes {0}'.format(self.PROVIDER))
|
||||
self.assertIn(
|
||||
'32768 MB RAM,4x110 GB SSD,40.00 TB BW',
|
||||
[i.strip() for i in size_list]
|
||||
)
|
||||
self.assertIn('2048 MB RAM,64 GB SSD,2.00 TB BW', [i.strip() for i in size_list])
|
||||
|
||||
# Commented for now, Vultr driver does not yet support key management
|
||||
# def test_key_management(self):
|
||||
|
@ -2,6 +2,7 @@
|
||||
|
||||
# Import Python Libs
|
||||
from __future__ import absolute_import, print_function, unicode_literals
|
||||
import os
|
||||
import time
|
||||
import threading
|
||||
|
||||
@ -36,6 +37,11 @@ class _SaltnadoIntegrationTestCase(SaltnadoTestCase): # pylint: disable=abstrac
|
||||
@skipIf(HAS_ZMQ_IOLOOP is False, 'PyZMQ version must be >= 14.0.1 to run these tests.')
|
||||
@skipIf(StrictVersion(zmq.__version__) < StrictVersion('14.0.1'), 'PyZMQ must be >= 14.0.1 to run these tests.')
|
||||
class TestSaltAPIHandler(_SaltnadoIntegrationTestCase):
|
||||
|
||||
def setUp(self):
|
||||
super(TestSaltAPIHandler, self).setUp()
|
||||
os.environ['ASYNC_TEST_TIMEOUT'] = '300'
|
||||
|
||||
def get_app(self):
|
||||
urls = [('/', saltnado.SaltAPIHandler)]
|
||||
|
||||
@ -335,7 +341,7 @@ class TestSaltAPIHandler(_SaltnadoIntegrationTestCase):
|
||||
headers={'Content-Type': self.content_type_map['json'],
|
||||
saltnado.AUTH_TOKEN_HEADER: self.token['token']},
|
||||
connect_timeout=30,
|
||||
request_timeout=30,
|
||||
request_timeout=300,
|
||||
)
|
||||
response_obj = salt.utils.json.loads(response.body)
|
||||
self.assertEqual(len(response_obj['return']), 1)
|
||||
|
Loading…
Reference in New Issue
Block a user