Till Maas
64b2d76de7
Merge pull request #90 from tyll/ansible27
...
Fix Ansible 2.7 support
2018-10-16 12:11:03 +02:00
Till Maas
49c7c6a0f4
tests: Properly set the name of assert tasks
...
Otherwise it breaks with Ansible 2.7 or does not show the name with
previous Ansible versions.
2018-10-16 11:31:22 +02:00
Till Maas
207d31b4d0
tests: Use vars: with include_tasks
...
Specifying vars as foo=bar does not work anymore with Ansible 2.7.
Specify the vars using a dictionary instead.
This fixes #89
2018-10-16 11:31:22 +02:00
Till Maas
eb6b954e32
Merge pull request #88 from tyll/fedora29
...
Fix Fedora 29 support
2018-10-16 11:30:14 +02:00
Till Maas
4d16eadd03
Merge pull request #87 from linux-system-roles/th/module-minor-cleanups
...
th/module-minor-cleanups
2018-10-15 21:03:13 +02:00
Till Maas
97adeb5668
Default to install network-scripts for initscripts
...
Newer releases of `initscripts` ship the network scripts in a separate
package called `network-scripts`.
This fixes #81
2018-10-15 21:00:26 +02:00
Till Maas
d4936d1ca7
Require bridge-utils only for older distributions
...
The initscripts provider uses iproute2 in newer releases to setup
bridges.
This fixes #84
2018-10-15 21:00:05 +02:00
Till Maas
84fe98508e
Use is version instead of |version_compare
...
Using tests as filters is deprecated and `version_compare` was renamed
to `version` in Ansible 2.5.
2018-10-15 20:53:20 +02:00
Thomas Haller
b4972517a4
module: fix name for ArgValidator_DictConnection
...
The name is actually not ever used, because
ArgValidator_DictConnection() is never validated directly.
Instead, it is always nested inside ArgValidator_ListConnections()
which passes "connections[$IDX]" as name to self.nested._validate().
Anyway, still when looking at the name of a ArgValidator_DictConnection
instance, it makes slightly more sense to call it just "connection".
2018-10-10 15:20:25 +02:00
Thomas Haller
97e216c716
module: don't expose "name" parameter for ArgValidator.validate()
...
The "name" argument is an implementation detail, that is used
by ArgValidatorDict and ArgValidatorList to pass a complex (nested)
name of what is currently parsed.
Callers are not supposed to see or use this argument.
Hide it, by adding an internal helper method _validate().
2018-10-10 15:20:25 +02:00
Thomas Haller
6856b5407d
module: rename internal ArgValidator._validate()
...
First a trivial renaming because the next commit will
add a different "_validate" method.
2018-10-10 15:20:25 +02:00
Thomas Haller
8daa14eb36
module: make Utils.create_uuid() working without pygobject
...
Utils.create_uuid() only needs the "uuid" module, which
is commonly available. Don't load it together with the
NM module, as that requires pygobject.
2018-10-10 15:20:25 +02:00
Pavel Cahyna
979145cbae
More doc improvements
2018-10-04 15:54:06 +02:00
Pavel Cahyna
ddada6e4c9
Restore previous meaning
...
in cases where it was lost or garbled by the restructuring.
Other minor doc improvements.
2018-10-04 15:54:06 +02:00
Vaclav Dolezal
60843a7f8d
readme: apply some other suggestions from pcahyna
2018-10-04 15:54:06 +02:00
Vaclav Dolezal
3e7a373b39
readme: apply some suggestions from pcahyna
2018-10-04 15:54:06 +02:00
Vaclav Dolezal
8c6f4e7f94
Apply requested changes to README
2018-10-04 15:54:06 +02:00
Vaclav Dolezal
89e2903032
Update and cleanup README
...
Co-author: Ioanna Gkioka <igkioka@redhat.com>
Signed-off-by: Vaclav Dolezal <vdolezal@redhat.com>
2018-10-04 15:54:06 +02:00
Till Maas
a10e72b905
Merge pull request #83 from tyll/network_provider_debug
...
Print network provider early
2018-08-28 18:42:46 +02:00
Till Maas
db6384f83c
Print network provider early
...
The list of packages to install depends on the network provider, so
print it out early.
2018-08-24 15:21:03 +02:00
Pavel Cahyna
8369b953cc
Update Galaxy tags.
...
Remove beta and add tags.
Update the OS versions and Ansible version (2.5 because of service_facts).
2018-08-21 20:47:38 +02:00
Till Maas
d0562b2ecd
Reword warnings
2018-08-15 18:41:26 +02:00
Pavel Cahyna
e1b50047c7
Fix typo
2018-08-15 17:02:57 +02:00
Pavel Cahyna
ff04b5aff0
consistent style for booleans
2018-08-15 16:47:13 +02:00
Pavel Cahyna
6440103bab
Delete a spurious character
2018-08-15 16:46:40 +02:00
Pavel Cahyna
bc8b0398b0
Add a prominent warning about things that the role removes.
2018-08-15 16:41:39 +02:00
Till Maas
712ff3fa88
Fix typo
2018-08-15 10:04:47 +02:00
Till Maas
53ee0e37ed
Do not mention wait:-1
2018-08-15 10:04:47 +02:00
Till Maas
09258d84e3
Support compatibility values for 'state' setting
2018-08-15 10:04:47 +02:00
Till Maas
e1bb399311
Use loop to install packages
2018-08-15 10:04:47 +02:00
Till Maas
23605615da
Separate 'persistent_state' from 'state'
...
- persistent_state represents whether a profile is stored on disk
- persistent_state defaults to 'present'
- When there is no type specified for the profile, it is enough for a
profile with the same name to be stored on the target's systems file
system. Otherwise the role will fail
- state now represents the runtime state and can be up, down or
unspecified
- translate the state definitions into actions that will be performed.
The actions correspond to the previous states.
- add the possibility to write unit tests to only verify parts of the
resulting connection dictionary to only check for the expected changes
instead of the full connection that can also contain unrelated defaults
2018-08-15 10:04:47 +02:00
Till Maas
987c8d05bb
Do not log long list of installed packages
...
This keeps the output more readable.
2018-08-15 10:04:47 +02:00
Till Maas
d76ac65581
Do not require profiles to be specified for 'up'
...
This allows to up profiles that are only available on disk.
2018-08-15 10:04:47 +02:00
Till Maas
382c34197b
Modularize role
...
Splitting the role in smaller parts helps to keep the overview and to
develop separate tests.
2018-08-15 10:04:47 +02:00
Till Maas
d866422d9d
Merge pull request #74 from tyll/autodetect_provider
...
Use network manager only when it is running
2018-08-01 23:43:59 +02:00
Till Maas
c279f0afc5
Run integration tests with other provider, too
...
- Amend and add files to run integration tests against the provider that
was not autodetected, too.
- Add check to ensure that all integration tests run against both
providers
- Run black check for all python scripts
2018-08-01 23:13:30 +02:00
Till Maas
4b9c91763b
Use nm provider by default only when NetworkManager is running
...
- Use initscripts as provider except when NetworkManager is running
- Rename network_provider_default to network_provider_os_default, since
it contains the default based on the OS
2018-08-01 18:32:01 +02:00
Till Maas
441667560e
Update limitations of initscripts and nm provider
2018-08-01 18:13:58 +02:00
Till Maas
22539bdc18
Merge pull request #75 from tyll/interface_name
...
Use profile name for interface name by default
2018-08-01 09:41:28 +02:00
Till Maas
3c826ad355
More README clarifications on the variables and behavior
2018-07-30 19:12:44 +02:00
Till Maas
6bf70bcf60
Use profile name for interface name by default
...
* by default ```name``` is used as ```interface_name```
* if ```interface_name``` is set to the empty string, it will not be set
* if ```mac``` is specified, ```interface_name``` defaults to not being set
This fixes #41
2018-07-25 21:56:43 +02:00
Till Maas
64879e74d9
Merge pull request #73 from tyll/black-squash
...
Use black as formatter and enable flake8/pylint
2018-07-20 13:16:20 +02:00
Till Maas
2f6605cf79
Merge pull request #72 from tyll/test_bridge1
...
Working tests from #53
2018-07-18 17:29:54 +02:00
Till Maas
e32033f995
Use black as formatter and enable flake8/pylint
2018-07-18 17:23:18 +02:00
Till Maas
35f2dcf8f7
Install bridge-utils if necessary for initscripts
...
Fixes #68
2018-07-16 08:26:50 +02:00
Till Maas
9b3d2d3ad8
Add simple test for bridges
2018-07-16 08:26:50 +02:00
pcahyna
7d44710f44
Merge pull request #69 from tyll/fixes
...
Fix typo in tox.ini
2018-07-11 15:32:02 +02:00
Till Maas
7c5dce7a1d
Fix typo in tox.ini
2018-07-11 12:35:35 +02:00
Till Maas
fdcd0f8ea7
Merge pull request #52 from tyll/test_connection_down
...
Taking a connection down does not work
2018-07-11 12:34:16 +02:00
Till Maas
459601c8e7
Fail when trying to down a non-existing NM profile
2018-07-11 10:06:45 +02:00