freebsd.rst 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. .. meta::
  2. :description: How do you install Salt on FreeBSD?
  3. :keywords: freebsd
  4. =======
  5. FreeBSD
  6. =======
  7. Installation
  8. ============
  9. Salt is available in the FreeBSD ports tree at `sysutils/py-salt
  10. <https://www.freshports.org/sysutils/py-salt/>`_.
  11. FreeBSD binary repo
  12. ===================
  13. Install Salt on FreeBSD via the official package repository. Salt is packaged
  14. both as a Python 2.7 or 3.7 version.
  15. For Python 2.7 use:
  16. .. code-block:: bash
  17. pkg install py27-salt
  18. For Python 3.7 use:
  19. .. code-block:: bash
  20. pkg install py37-salt
  21. FreeBSD ports
  22. =============
  23. Installation from ports:
  24. .. code-block:: bash
  25. cd /usr/ports/sysutils/py-salt
  26. make install
  27. Python 3.7 can be used by setting default Python version to 3.7:
  28. .. code-block:: text
  29. echo "DEFAULT_VERSIONS+= python=3.7" >> /etc/make.conf
  30. Post-installation tasks
  31. =======================
  32. **rc.conf**
  33. Activate the Salt Master in ``/etc/rc.conf``:
  34. .. code-block:: bash
  35. sysrc salt_master_enable="YES"
  36. **Start the Master**
  37. Start the Salt Master as follows:
  38. .. code-block:: bash
  39. service salt_master start
  40. **rc.conf**
  41. Activate the Salt Minion in ``/etc/rc.conf``:
  42. .. code-block:: bash
  43. sysrc salt_minion_enable="YES"
  44. **Start the Minion**
  45. Start the Salt Minion as follows:
  46. .. code-block:: bash
  47. service salt_minion start
  48. Now go to the :ref:`Configuring Salt<configuring-salt>` page.