snapcraft.yaml 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. name: home-assistant-snap
  2. version: '0.114.4'
  3. summary: Open source home automation that puts local control and privacy first
  4. description: |
  5. Home Assistant is a home automation platform running on Python 3.
  6. It is able to track and control all devices at home and offer a
  7. platform for automating control.
  8. Please see official docs: https://git.giaever.org/joachimmg/home-assistant-snap
  9. base: core20
  10. grade: stable
  11. confinement: strict
  12. license: Apache-2.0
  13. layout:
  14. /etc/pip.conf:
  15. bind-file: $SNAP_DATA/pip.conf
  16. /etc/openzwave:
  17. bind: $SNAP/openzwave
  18. slots:
  19. components:
  20. interface: content
  21. content: components
  22. write:
  23. - $SNAP_DATA/custom_components
  24. certs:
  25. interface: content
  26. content: certs
  27. write:
  28. - $SNAP_DATA/certs
  29. configurations:
  30. interface: content
  31. write:
  32. - $SNAP_DATA
  33. apps:
  34. hass:
  35. command: bin/hass --config $SNAP_DATA
  36. command-chain:
  37. - bin/slot-certs
  38. daemon: simple
  39. environment:
  40. PIP_USER: 1
  41. restart-condition: always
  42. plugs:
  43. - bluez
  44. - network
  45. - network-bind
  46. - raw-usb
  47. # GPIO devices etc.. (e.g RaZberry GPIO hat)
  48. - physical-memory-control
  49. slots:
  50. - components
  51. certs-daemon:
  52. command: bin/certs-daemon
  53. daemon: oneshot
  54. restart-condition: always
  55. timer: 00:00-24:00/287
  56. slots:
  57. - certs
  58. plugs:
  59. - network
  60. - network-bind
  61. refresh-certs:
  62. command: bin/certs-daemon
  63. slots:
  64. - certs
  65. plugs:
  66. - network
  67. - network-bind
  68. hooks:
  69. prepare-slot-certs:
  70. plugs:
  71. - network
  72. - network-bind
  73. parts:
  74. homeassistant:
  75. plugin: python-wot-plugin
  76. source: https://github.com/home-assistant/core.git
  77. source-tag: ${SNAPCRAFT_PROJECT_VERSION}
  78. python-packages:
  79. - setuptools
  80. - wheel
  81. - Cython
  82. - pip
  83. build-packages:
  84. - python3
  85. - python3-dev
  86. - python3-setuptools
  87. - python3-wheel
  88. - pkg-config
  89. - autoconf
  90. - build-essential
  91. - cmake
  92. - cython3
  93. - ffmpeg
  94. - libavcodec-dev
  95. - libavdevice-dev
  96. - libavfilter-dev
  97. - libavformat-dev
  98. - libavresample-dev
  99. - libavutil-dev
  100. - libffi-dev
  101. - libglib2.0-dev
  102. - libglu1-mesa-dev
  103. - libgpiod-dev
  104. - libjpeg-dev
  105. - libopenzwave1.5-dev
  106. - libssl-dev
  107. - libswscale-dev
  108. - libudev-dev
  109. - libxml2-dev
  110. - libxslt1-dev
  111. - zlib1g-dev
  112. stage-packages:
  113. - freeglut3
  114. - ffmpeg
  115. - libglu1-mesa
  116. - zlib1g
  117. requirements:
  118. - requirements_all.txt
  119. constraints:
  120. - homeassistant/package_constraints.txt
  121. override-build: |
  122. snapcraftctl build
  123. sed -i 's/include-system-site-packages = false/include-system-site-packages = true/g' $SNAPCRAFT_PART_INSTALL/pyvenv.cfg
  124. hooks:
  125. plugin: dump
  126. source: ./scripts/hooks
  127. source-type: local
  128. stage-packages:
  129. - uuid
  130. - libossp-uuid16
  131. - libassuan0
  132. - gpg
  133. - gpg-agent
  134. organize:
  135. configure: snap/hooks/configure
  136. post-refresh: snap/hooks/post-refresh
  137. prepare-slot-certs: snap/hooks/prepare-slot-certs
  138. bins:
  139. plugin: dump
  140. source: ./scripts/bin
  141. source-type: local
  142. organize:
  143. slot-certs: bin/slot-certs
  144. certs-daemon: bin/certs-daemon
  145. config:
  146. plugin: dump
  147. source: ./scripts/config
  148. source-type: local