Page MenuHomeDevCentral

Migrate the Salt states and modules to Python 3
ClosedPublic

Authored by dereckson on Feb 28 2018, 12:57.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Dec 17, 01:07
Unknown Object (File)
Sun, Dec 15, 14:29
Unknown Object (File)
Sun, Dec 15, 14:09
Unknown Object (File)
Fri, Dec 13, 06:03
Unknown Object (File)
Thu, Dec 12, 12:30
Unknown Object (File)
Mon, Dec 9, 04:25
Unknown Object (File)
Sat, Dec 7, 12:28
Unknown Object (File)
Fri, Dec 6, 13:35
Subscribers
None

Details

Summary

Ref T1343.

Test Plan
  • Run unit tests for modules
  • Run modified modules functions
  • Run in test mode modified states

Diff Detail

Repository
rOPS Nasqueron Operations
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

dereckson created this revision.

Tests units pass.

This part currently committed works fine.

I've still to check the viperserv role's account unit: in roles/viperserv/account/init.sls and roles/viperserv/account/files/viperserv.sudoers, a string is iterated letter by letter.

Ysul
$ salt-call --local node.filter_by_role web_content_sls
local:
    - .be/dereckson
    - .org/nasqueron/api
    - .org/nasqueron/docs
    - .org/nasqueron/labs

$ salt-call --local state.apply roles/bastion/yubico/authorized_yubikeys test=True
[…]
Succeeded: 2
Failed:    0
[…]

$ salt-call --local forest.get_users
[dictionary with the correct users list]

$ salt-call --local state.apply roles/core/users test=True
[dictionaries are correctly iterated]

$ salt-call --local state.apply roles/devserver/webserver-wwwroot51 test=True
[dictionaries are correctly iterated]
Succeeded: 7
Failed:    0
[…]

$ salt-call --local state.apply roles/viperserv/account test=True
[a string is parsed as an iterable in the the sudoers template]

$ salt-call --local state.apply roles/webserver-legacy/php-sites/account test=True
[dictionaries are correctly iterated]

$ salt-call --local state.apply roles/webserver-legacy/php-sites/files test=True
[dictionaries are correctly iterated]

$ salt-call --local state.apply roles/webserver-legacy/php-sites/php-fpm test=True
[dictionaries are correctly iterated]

'''Notes :'''

  • www.dereckson.be files in /var/wwwroot/dereckson/www don't match staging
  • users states aren't executed in Ysul, pending ZFS /home configuration
This revision is now accepted and ready to land.Feb 28 2018, 13:22
This revision was automatically updated to reflect the committed changes.