Skip to content

Instantly share code, notes, and snippets.

@jcockhren
Forked from anonymous/init.sls
Created April 4, 2017 19:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jcockhren/3a43d0eeba39d71b4217f0a9ae05e4da to your computer and use it in GitHub Desktop.
Save jcockhren/3a43d0eeba39d71b4217f0a9ae05e4da to your computer and use it in GitHub Desktop.
homeassistant:
pip.installed:
- bin_env: '/usr/bin/pip3'
python3-pip:
pkg.installed
cython3:
pkg.installed
libudev-dev:
pkg.installed
python3-sphinx:
pkg.installed
python3-setuptools:
pkg.installed
homeassistant-user:
group.present:
- name: hass
user.present:
- name: hass
- system: true
- createhome: true
- groups:
- hass
- dialout
- require:
- group: hass
homeassistant-service-file:
file.managed:
- name: /etc/systemd/system/homeassistant.service
- mode: 0444
- source: salt://homeassistant/files/homeassistant.service
- template: jinja
homeassistant-configuration-dir:
file.directory:
- name: /etc/homeassistant
- user: hass
- group: hass
homeassistant-configuration:
file.managed:
- name: /etc/homeassistant/configuration.yaml
- source: salt://homeassistant/files/configuration.yaml
- user: hass
- dir_mode: 0755
- file_mode: 0640
- template: jinja
homeassistant-service:
service.running:
- name: homeassistant
- enable: True
- reload: True
- require:
- file: /etc/systemd/system/homeassistant.service
- watch:
- file: /etc/homeassistant/configuration.yaml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment