Restart Apache on all Minions: sudo salt '*' service.start apache2 Services are controlled using the service module. List all packages installed on minion1: sudo salt 'minion1' pkg.list_pkgs Remove Apache from minion5: sudo salt 'minion5' pkg.remove apache2 Install Apache to all Minions: sudo salt '*' pkg.install apache2 If your Salt Minions are a version of Debian or Ubuntu, you would install or remove Apache with the examples below. For example, apache is the Apache httpd server package in Debian and Ubuntu, while httpd is the package name in RHEL-based systems. Install packages using the same package name used in the system repositories of the Salt minion. Packages can be targeted to individual Minions by specifying the minion’s hostname or IP address, or to all Minions by using *. As long as you’re running a Linux distribution supported by SaltStack, the Salt module controls the distribution’s package manager, be it apt, yum, etc. Packages are installed or removed from Minions using the pkg state module. The output should show true for each Minion: salt '*' test.ping Ping all Minions: sudo salt '*' test.ping sudo salt-run manage.upįor more information about Salt keys, see the salt-key man page. The command below should return the hostname or IP address of each Minion which has been verified and is running. To accept an individual minion, specify it by hostname or IP address: sudo salt-key -a hostname The install script is intended to be run on the Salt master and all minion machines. Salt Bootstrap is a configuration script which automatically detects the operating system it’s running on, sets the correct repositories, and installs Salt. We recommend that you configure private IP addresses for each system if your Linodes are located in the same data center. The hostname will be used to identify each Linode within Salt so be specific with their naming (e.g. You will need at least two Linodes: One will function as the Salt Master and the other(s) as Salt Minions. This guide walks you through configuring a Salt Master and Minion, and is relevant to any supported Linux distribution. Salt is a Python-based configuration management platform designed to control a number of slave servers (called Minions in Salt terminology) from a single master server.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |