Compare commits

..

1238 Commits

Author SHA1 Message Date
Joakim Sørensen
2bb014fda5 Update frontend to 0d1c7238 (#2681) 2021-03-04 17:16:17 +01:00
Pascal Vizeli
09203f67b2 Fix defaults for builds (#2675) 2021-03-04 11:48:25 +01:00
Joakim Sørensen
169c7ec004 Update frontend to 419e5644 (#2667) 2021-03-03 16:20:04 +01:00
Joakim Sørensen
202e94615e Update frontend to bee17fce (#2665)
* Update frontend to fe50f422

* revert unrelated change

* Update frontend to bee17fce
2021-03-03 15:15:07 +01:00
Pascal Vizeli
5fe2a815ad Fix error handling with new config handling (#2666) 2021-03-03 12:46:34 +01:00
Joakim Sørensen
a13a0b4770 Guard for missing repository file (#2664)
* Guard for missing repository file

* Update supervisor/store/data.py

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2021-03-03 11:33:58 +01:00
Joakim Sørensen
455bbc457b Update frontend to 9f73f0ca (#2661)
* Update frontend to 9f73f0ca

* Update frontend to 935d97ce
2021-03-02 17:12:36 +01:00
Joakim Sørensen
d50fd3b580 Add network description to translation files (#2660) 2021-03-02 15:41:00 +01:00
Pascal Vizeli
455e80b07c Merge branch 'main' of https://github.com/home-assistant/supervisor into main 2021-03-02 13:16:09 +00:00
Joakim Sørensen
291becbdf9 Update frontend to 1642c684 (#2657) 2021-03-01 17:19:48 +01:00
Pascal Vizeli
33385b46a7 Fix add-on is not installed anymore (#2656)
* Fix add-on is not installed anymore

* Fix and add tests
2021-03-01 17:19:38 +01:00
Pascal Vizeli
df17668369 Fix add-on is not installed anymore 2021-03-01 15:43:50 +00:00
Joakim Sørensen
43449c85bb Fix translation schema (#2654)
* Fix translation schema

* really fix it

* fix migration path

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2021-03-01 16:39:00 +01:00
Stefan Agner
9e86eda05a Adjust CPU runtime allocation to support multiple add-ons (#2655)
Adjust realtime CPU runtime allocation to support multiple
add-ons/plug-ins with the runtime flag set.

The cpu.rt_runtime_us allocation is somewhat special as it
allocates the guaranteed runtime. Hence we cannot simply allocate all
time to each add-on.

Unfortunately we cannot distribute the CPU time equally based on the
number of add-ons as we don't know the number of add-ons which will use
realtime ahead of time. Also adjusting at runtime is currenlty not
supported by the Docker Python SDK (the underlying http API does
however, so this would be a possible future improvement).

This solution distributes the total available time of 950ms to up to 5
add-ons/plug-ins in equal slices. On a quad-core system this allows up
to 760ms CPU time in the real-time scheduler per 1s (76% of one CPU)
which should be sufficient for most cases.
2021-03-01 15:29:10 +01:00
Pascal Vizeli
b288554d9c Allow dynamic lookup cgroup rules based on Host udev (#2652) 2021-03-01 14:57:44 +01:00
Joakim Sørensen
bee55d08fb Create FileConfiguration baseclass (#2651) 2021-03-01 12:26:43 +01:00
Joakim Sørensen
7a542aeb38 Add support for loading add-on translation files (#2644)
* Add support for loading add-on translation files

* Fix storing translations for installed add-ons

* Allow YAML, force schema

* Adjust schema
2021-03-01 11:44:24 +01:00
dependabot[bot]
8d42513ba8 Bump gitpython from 3.1.13 to 3.1.14 (#2647)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.1.13 to 3.1.14.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.1.13...3.1.14)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-01 11:33:41 +01:00
dependabot[bot]
89b7247aa2 Bump home-assistant/builder from 2021.01.1 to 2021.02.0 (#2650)
Bumps [home-assistant/builder](https://github.com/home-assistant/builder) from 2021.01.1 to 2021.02.0.
- [Release notes](https://github.com/home-assistant/builder/releases)
- [Commits](https://github.com/home-assistant/builder/compare/2021.01.1...8c4b820c467894c8374aca262deac0a8aef4982d)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-01 10:56:10 +01:00
dependabot[bot]
29132e7f4c Bump coverage from 5.4 to 5.5 (#2648)
Bumps [coverage](https://github.com/nedbat/coveragepy) from 5.4 to 5.5.
- [Release notes](https://github.com/nedbat/coveragepy/releases)
- [Changelog](https://github.com/nedbat/coveragepy/blob/master/CHANGES.rst)
- [Commits](https://github.com/nedbat/coveragepy/compare/coverage-5.4...coverage-5.5)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-01 10:24:38 +01:00
dependabot[bot]
3fd9baf78e Bump pylint from 2.6.2 to 2.7.2 (#2649)
Bumps [pylint](https://github.com/PyCQA/pylint) from 2.6.2 to 2.7.2.
- [Release notes](https://github.com/PyCQA/pylint/releases)
- [Changelog](https://github.com/PyCQA/pylint/blob/master/ChangeLog)
- [Commits](https://github.com/PyCQA/pylint/compare/pylint-2.6.2...pylint-2.7.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-01 10:17:21 +01:00
Philip Allgaier
f3aa3757ce Fixed typos in resolution notify (#2646) 2021-03-01 09:44:16 +01:00
Joakim Sørensen
3760967f59 Allow use YAML for addon and repository config (#2645)
* Allow use YAML for addon and repository config

* pylint
2021-02-28 20:00:02 +01:00
Joakim Sørensen
f7ab8e0f7f Update frontend to 478a4b25 (#2637) 2021-02-26 15:23:15 +01:00
Joakim Sørensen
0e46ea12b2 Allways store docker and repository config (#2636) 2021-02-26 13:40:47 +01:00
Joakim Sørensen
be226b2b01 Make homeassistant optional in partial snapshot (#2635) 2021-02-26 12:51:04 +01:00
dependabot[bot]
9e1239e192 Bump aiohttp from 3.7.3 to 3.7.4 (#2633)
Bumps [aiohttp](https://github.com/aio-libs/aiohttp) from 3.7.3 to 3.7.4.
- [Release notes](https://github.com/aio-libs/aiohttp/releases)
- [Changelog](https://github.com/aio-libs/aiohttp/blob/master/CHANGES.rst)
- [Commits](https://github.com/aio-libs/aiohttp/compare/v3.7.3...v3.7.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-26 09:43:45 +01:00
dependabot[bot]
2eba3d85b0 Bump pulsectl from 20.5.1 to 21.2.0 (#2634)
Bumps [pulsectl](https://github.com/mk-fg/python-pulse-control) from 20.5.1 to 21.2.0.
- [Release notes](https://github.com/mk-fg/python-pulse-control/releases)
- [Changelog](https://github.com/mk-fg/python-pulse-control/blob/master/CHANGES.rst)
- [Commits](https://github.com/mk-fg/python-pulse-control/commits)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-26 09:42:59 +01:00
Joakim Sørensen
9b569268ab Fix add-on updates (#2632)
* Fix add-on updates

* Add to security role
2021-02-25 23:29:39 +01:00
Pascal Vizeli
31f5033dca Add throttle to job execution (#2631)
* Add throttle to job execution

* fix unittests

* Add tests

* address comments

* add comment

* better on __init__

* New text

* Simplify logic
2021-02-25 23:29:03 +01:00
Pascal Vizeli
78d9c60be5 Log issues/suggestion with info (#2629) 2021-02-25 19:52:19 +01:00
Stefan Agner
baa86f09e5 Real-time fixes (#2630)
* Fix path of cpu.rt_runtime_us sysfs file

Fix detection of CPU bandwidth allocation (CONFIG_RT_GROUP_SCHED) option
by checking the correct file location.

* Set priority limit and memory lock limit

Set a soft limit of real-time priority 90 and hard limit of 99. The
maximum is 99, to avoid add-ons using such a high priority without
second thought set the soft limit to 90. This allows a process to higher
the limit to 99, if really required.

Also set max locked memory to 128MB. Locking memory from getting paged
out is often used for the real-time process/thread to avoid delays due
to swapping/pageing in. Ideally a real-time process should only do the
real-time job, hence not need too much memory.

* Remove check for support_cpu_realtime and set correct limit for audio plug-in
2021-02-25 18:48:08 +01:00
Pascal Vizeli
a4c4b39ba8 Fix k-anonymity handling (#2627) 2021-02-25 18:16:20 +01:00
Joakim Sørensen
752068bb56 Add /store API (#2626) 2021-02-25 16:15:51 +01:00
Pascal Vizeli
739cfbb273 Small cleanups with pwned handling (#2625) 2021-02-25 15:36:02 +01:00
Pascal Vizeli
115af4cadf Optimize resolution checks / add endpoint to trigger it manual (#2622) 2021-02-25 14:05:27 +01:00
Joakim Sørensen
ae3274e559 Add home-assistant version to API response (#2621) 2021-02-25 11:44:22 +01:00
dependabot[bot]
c61f096dbd Bump docker from 4.4.3 to 4.4.4 (#2619)
Bumps [docker](https://github.com/docker/docker-py) from 4.4.3 to 4.4.4.
- [Release notes](https://github.com/docker/docker-py/releases)
- [Commits](https://github.com/docker/docker-py/compare/4.4.3...4.4.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-25 10:27:24 +01:00
dependabot[bot]
ee7b5c42fd Bump awesomeversion from 21.2.2 to 21.2.3 (#2620)
Bumps [awesomeversion](https://github.com/ludeeus/awesomeversion) from 21.2.2 to 21.2.3.
- [Release notes](https://github.com/ludeeus/awesomeversion/releases)
- [Commits](https://github.com/ludeeus/awesomeversion/compare/21.2.2...21.2.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-25 10:27:05 +01:00
Pascal Vizeli
85d527bfbc Add check for pwned secrets to resolution center (#2614)
* Add check for pwned secrets to resolution center

* restructure check

* add checks

* Add test

* Add test

* reload secrets before check

* simplify

* create notification

* Use own exceptions

* Check on startup

* Apply suggestions from code review

Co-authored-by: Franck Nijhof <git@frenck.dev>

* Add job decorator

* Update supervisor/resolution/notify.py

Co-authored-by: Franck Nijhof <git@frenck.dev>

* Update supervisor/utils/pwned.py

Co-authored-by: Franck Nijhof <git@frenck.dev>

Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-02-25 09:37:45 +01:00
Pascal Vizeli
dd561da819 Fix landingpage on check_api_state (#2615)
Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2021-02-24 21:52:18 +01:00
Joakim Sørensen
cb5932cb8b Fix issue with concurrent reads (#2610)
* Fix issue with concurrent reads

* Use lock

* acquire/release

* handle ConnectionError

* No there was not mulitple issues, it's the same code just different syle.....Which is stated on the same page as that image...
2021-02-24 18:36:21 +01:00
Pascal Vizeli
8630adc54a Add execution limit for jobs (#2612)
* Add execution limit for jobs

* Add test for execution police

* Use better test

* Apply suggestions from code review

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Rename JobExecutionLimit

* fix typing

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2021-02-24 17:15:13 +01:00
Joakim Sørensen
90d8832cd2 Send event when add-on changes state (#2608)
* Send event when add-on changes state

* fix test
2021-02-23 15:12:30 +01:00
Pascal Vizeli
3802b97bb6 Add kernel docs about the device classes (#2607) 2021-02-22 15:10:28 +01:00
Pascal Vizeli
2de175e181 Remove not needed call_soon (#2606) 2021-02-22 14:41:44 +01:00
Joakim Sørensen
6b7d437b00 Signal frontend to refresh on SU startup (#2603)
* Signal frontend to refresh on SU startup

* Use sync variant
2021-02-22 14:31:48 +01:00
Pascal Vizeli
e2faf906de Use the cpu_rt support check also for rtprio (#2605) 2021-02-22 14:02:36 +01:00
Franck Nijhof
bb44ce5cd2 Fix small typo in log message (#2604) 2021-02-22 13:44:12 +01:00
Joakim Sørensen
15544ae589 Show add-on with bad config in log (#2601) 2021-02-22 13:43:03 +01:00
Pascal Vizeli
e421284471 Detect host support for CPU realtime + add an option for enable it (#2602) 2021-02-22 13:30:32 +01:00
Pascal Vizeli
785dc64787 Imrove the LXC detection (#2599) 2021-02-22 11:39:18 +01:00
Joakim Sørensen
7e7e3a7876 Update frontend to ef0bfb23 (#2598) 2021-02-22 11:22:47 +01:00
Pascal Vizeli
2b45c059e0 Support realtime scheduling for add-ons (#2593)
* Support realtime scheduling for add-ons

* support on audio

* address comments from @jens-maus
2021-02-22 11:22:36 +01:00
Joakim Sørensen
14ec61f9bd Update frontend to 2d3cf7d8 (#2594) 2021-02-22 09:41:52 +01:00
Joakim Sørensen
5cc72756f8 Fix some issues with the issue template (#2592) 2021-02-19 23:35:00 +01:00
Franck Nijhof
44785ef3e2 Update GitHub Issue Form template (#2591) 2021-02-19 23:18:23 +01:00
Franck Nijhof
e60d858feb Allow for static port in Watchdog add-on configuration (#2589) 2021-02-19 15:23:17 +01:00
Joakim Sørensen
b31ecfefcd Initial WS support (#2439)
* Initial WS support

* test

* Update frontend to fc7c4af2

* Fix issue with closing states

* log error

* make data optional

* limit stopping states

* Move wrappers to HomeAssistantWebSocket

* use info

* Use call_soon

* Use lookuptable for WS commands

* Fix tests
2021-02-19 11:57:31 +01:00
dependabot[bot]
c342231052 Bump docker from 4.4.2 to 4.4.3 (#2587)
Bumps [docker](https://github.com/docker/docker-py) from 4.4.2 to 4.4.3.
- [Release notes](https://github.com/docker/docker-py/releases)
- [Commits](https://github.com/docker/docker-py/compare/4.4.2...4.4.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-19 10:09:03 +01:00
dependabot[bot]
673666837e Bump sentry-sdk from 0.20.2 to 0.20.3 (#2588) 2021-02-19 08:59:22 +01:00
dependabot[bot]
c8f74d6c0d Bump actions/stale from v3.0.16 to v3.0.17 (#2586) 2021-02-19 08:42:14 +01:00
Pascal Vizeli
7ed9de8014 Fix device check if not exists (#2585) 2021-02-18 12:39:42 +01:00
Pascal Vizeli
8650947f04 Add capabilities for puleaudio (#2583)
* Add capabilities for puleaudio

* fix import
2021-02-17 17:21:47 +01:00
Pascal Vizeli
a0ac8ced31 Fix handling with full access / blocked devices (#2581)
* Fix handling with full access / blocked devices

* address comment

* Use name

* Add validation warning

* add GPIO check too

* remove warning

* return directly

* fix tests
2021-02-17 15:48:48 +01:00
Joakim Sørensen
2145bbea81 Update frontend to 03d41741 (#2580) 2021-02-17 13:12:37 +01:00
Pascal Vizeli
480000ee7f Fix typo in suggestion (#2578) 2021-02-17 12:49:07 +01:00
dependabot[bot]
9ec2ad022e Bump cryptography from 3.4.5 to 3.4.6 (#2576)
Bumps [cryptography](https://github.com/pyca/cryptography) from 3.4.5 to 3.4.6.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/main/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/3.4.5...3.4.6)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-17 12:01:18 +01:00
dependabot[bot]
43e40816dc Bump pylint from 2.6.0 to 2.6.2 (#2577)
Bumps [pylint](https://github.com/PyCQA/pylint) from 2.6.0 to 2.6.2.
- [Release notes](https://github.com/PyCQA/pylint/releases)
- [Changelog](https://github.com/PyCQA/pylint/blob/master/ChangeLog)
- [Commits](https://github.com/PyCQA/pylint/compare/pylint-2.6.0...pylint-2.6.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-17 12:00:59 +01:00
Pascal Vizeli
941ea3ee68 Fix audio cgroup issue (#2575) 2021-02-16 09:34:15 +01:00
Pascal Vizeli
a6e4b5159e Discovery for vlc telnet (#2573) 2021-02-16 09:31:07 +01:00
dependabot[bot]
6f542d58d5 Bump docker from 4.4.1 to 4.4.2 (#2571)
Bumps [docker](https://github.com/docker/docker-py) from 4.4.1 to 4.4.2.
- [Release notes](https://github.com/docker/docker-py/releases)
- [Commits](https://github.com/docker/docker-py/compare/4.4.1...4.4.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-16 08:41:01 +01:00
dependabot[bot]
b2b5fcee7d Bump sentry-sdk from 0.20.1 to 0.20.2 (#2572)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.20.1 to 0.20.2.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGELOG.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.20.1...0.20.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-16 08:40:38 +01:00
Pascal Vizeli
59a82345a9 Drop full privileged from audio plugin (#2570) 2021-02-16 08:40:19 +01:00
Pascal Vizeli
b61a747876 Kernel modules add-on flag need no extra cap (#2569) 2021-02-15 20:42:03 +01:00
dependabot[bot]
72e5d800d5 Bump cryptography from 3.4.4 to 3.4.5 (#2567)
Bumps [cryptography](https://github.com/pyca/cryptography) from 3.4.4 to 3.4.5.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/main/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/3.4.4...3.4.5)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-15 10:09:54 +01:00
dependabot[bot]
c7aa6d4804 Bump sentry-sdk from 0.20.0 to 0.20.1 (#2568)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.20.0 to 0.20.1.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGELOG.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.20.0...0.20.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-15 10:08:58 +01:00
Pascal Vizeli
b31063449d Fix path for tmpfs (#2565) 2021-02-13 20:34:32 +01:00
dependabot[bot]
477672459d Bump sentry-sdk from 0.19.5 to 0.20.0 (#2563)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.19.5 to 0.20.0.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGELOG.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.19.5...0.20.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-12 15:33:20 +01:00
Pascal Vizeli
9c33897296 Add some issues and suggestion (#2557) 2021-02-11 09:06:46 +01:00
Matheson Steplock
100cfb57c5 Fix Typos in LOGGER (#2552)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-02-10 21:53:37 +01:00
Pascal Vizeli
40b34071e7 Revert "Mask folder /dev/bus/usb RW (#2555)" (#2556)
This reverts commit 341833fd8f.
2021-02-10 11:35:21 +01:00
Pascal Vizeli
341833fd8f Mask folder /dev/bus/usb RW (#2555) 2021-02-10 10:37:40 +01:00
dependabot[bot]
f647fd6fea Bump cryptography from 3.4.3 to 3.4.4 (#2553)
Bumps [cryptography](https://github.com/pyca/cryptography) from 3.4.3 to 3.4.4.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/3.4.3...3.4.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-10 10:23:42 +01:00
dependabot[bot]
53642f2389 Bump gitpython from 3.1.12 to 3.1.13 (#2554)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.1.12 to 3.1.13.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.1.12...3.1.13)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-10 10:23:06 +01:00
Pascal Vizeli
b9bdd655ab Add hidraw to USB (#2549) 2021-02-09 21:09:57 +01:00
Pascal Vizeli
e9e1b5b54f Add support for hiddev on USB (#2548) 2021-02-09 19:25:16 +01:00
Franck Nijhof
be2163d635 Small tweaks to issue form (#2545) 2021-02-09 17:25:34 +01:00
Franck Nijhof
7f6dde3a5f Fix issue template forms (#2543) 2021-02-09 17:14:44 +01:00
Joakim Sørensen
334aafee23 Update frontend to c7821b9c (#2542) 2021-02-09 13:10:13 +01:00
Pascal Vizeli
1a20c18b19 Use Alpine 3.13 (#2539)
* Use Alpine 3.13

* Update builder.yml
2021-02-09 10:21:14 +01:00
dependabot[bot]
6e655b165c Bump cryptography from 3.3.1 to 3.4.3 (#2537)
* Bump cryptography from 3.3.1 to 3.4.3

Bumps [cryptography](https://github.com/pyca/cryptography) from 3.3.1 to 3.4.3.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/3.3.1...3.4.3)

Signed-off-by: dependabot[bot] <support@github.com>

* Update builder.yml

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2021-02-09 10:04:58 +01:00
Pascal Vizeli
d768b2fa1e Fix UI options without filter (#2536) 2021-02-08 21:37:44 +01:00
Joakim Sørensen
85bce1cfba Add core state to /info API (#2531) 2021-02-08 12:39:46 +01:00
Pascal Vizeli
a798a2466f Change Supervisor update flow with AppArmor (#2529) 2021-02-08 10:45:34 +01:00
dependabot[bot]
2a5d8a5c82 Bump actions/stale from v3.0.15 to v3.0.16 (#2527)
Bumps [actions/stale](https://github.com/actions/stale) from v3.0.15 to v3.0.16.
- [Release notes](https://github.com/actions/stale/releases)
- [Commits](https://github.com/actions/stale/compare/v3.0.15...9d6f46564a515a9ea11e7762ab3957ee58ca50da)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-08 09:40:58 +01:00
dependabot[bot]
ea62171d98 Bump pyupgrade from 2.9.0 to 2.10.0 (#2526)
Bumps [pyupgrade](https://github.com/asottile/pyupgrade) from 2.9.0 to 2.10.0.
- [Release notes](https://github.com/asottile/pyupgrade/releases)
- [Commits](https://github.com/asottile/pyupgrade/compare/v2.9.0...v2.10.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-08 09:40:46 +01:00
dependabot[bot]
196389d5ee Bump pre-commit from 2.10.0 to 2.10.1 (#2525)
Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 2.10.0 to 2.10.1.
- [Release notes](https://github.com/pre-commit/pre-commit/releases)
- [Changelog](https://github.com/pre-commit/pre-commit/blob/master/CHANGELOG.md)
- [Commits](https://github.com/pre-commit/pre-commit/compare/v2.10.0...v2.10.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-08 09:40:33 +01:00
dependabot[bot]
1776021620 Bump actions/cache from v2 to v2.1.4 (#2528)
Bumps [actions/cache](https://github.com/actions/cache) from v2 to v2.1.4.
- [Release notes](https://github.com/actions/cache/releases)
- [Commits](https://github.com/actions/cache/compare/v2...26968a09c0ea4f3e233fdddbafd1166051a095f6)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-08 09:39:28 +01:00
Pascal Vizeli
c42a9124d3 Fix cleanup with changed image (#2521) 2021-02-05 16:03:57 +01:00
dependabot[bot]
a44647b4cd Bump awesomeversion from 21.2.0 to 21.2.2 (#2520)
Bumps [awesomeversion](https://github.com/ludeeus/awesomeversion) from 21.2.0 to 21.2.2.
- [Release notes](https://github.com/ludeeus/awesomeversion/releases)
- [Commits](https://github.com/ludeeus/awesomeversion/compare/21.2.0...21.2.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-05 11:31:57 +01:00
Pascal Vizeli
e0c3fd87c5 Add API endpoint for add-on for his own config (#2515)
* Add API endpoint for add-on for his own config

* allow access his config
2021-02-04 16:32:48 +01:00
Pascal Vizeli
ed8f2a85b7 Fix memory stats calc (#2518) 2021-02-04 16:06:12 +01:00
Pascal Vizeli
48f8553c75 Show the current core state on message (#2516) 2021-02-04 15:52:48 +01:00
Joakim Sørensen
af4517fd1e Update frontend to 4273b72d (#2517) 2021-02-04 15:50:07 +01:00
Joakim Sørensen
78e6a46318 Update frontend to e06642e8 (#2513) 2021-02-03 18:00:43 +01:00
Pascal Vizeli
49ca923e51 Apply old udev handling like core container (#2511) 2021-02-03 12:56:25 +01:00
Pascal Vizeli
7ad22e0399 Make add-on file schema more future approved (#2510) 2021-02-03 12:06:22 +01:00
Pascal Vizeli
bb8acc6065 Fix add-on state was not fast reflected (#2509) 2021-02-03 12:02:09 +01:00
Joakim Sørensen
c0fa4a19e9 Change verbosity for hardware.trigger API (#2508) 2021-02-02 20:56:37 +01:00
Franck Nijhof
3f1741dd18 Typo: depircated -> deprecated (#2507) 2021-02-02 20:41:56 +01:00
Stefan Agner
9ef02e4110 Add eMMC life-time estimate support (#2413)
* Add eMMC life-time estimate support

Expose life time estimate as Host Info property "ssd_life_time"

* Fix pytest

* Fix path to helper

* Allow protected access in tests

* Apply suggestions from code review

Rename SSD to disk.

Co-authored-by: Pascal Vizeli <pascal.vizeli@syshack.ch>

* Rename functions as well

* Update host.py

Co-authored-by: Pascal Vizeli <pascal.vizeli@syshack.ch>
2021-02-02 10:31:02 +01:00
Pascal Vizeli
15a6f38ebb Make sure device is ready initialize on udev (#2504)
* Make sure device is ready initialize on udev

* fix style

* let's start with 2sec

* better logic

* style

* add change events back
2021-02-02 09:53:09 +01:00
dependabot[bot]
227f2e5a21 Bump pyupgrade from 2.8.0 to 2.9.0 (#2505)
Bumps [pyupgrade](https://github.com/asottile/pyupgrade) from 2.8.0 to 2.9.0.
- [Release notes](https://github.com/asottile/pyupgrade/releases)
- [Commits](https://github.com/asottile/pyupgrade/compare/v2.8.0...v2.9.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-02 09:52:51 +01:00
Pascal Vizeli
517d6ee981 Lookup udev device in monitor thread (#2503) 2021-02-01 18:29:05 +01:00
Pascal Vizeli
184eeb7f49 Udev - move away form depricated callback / increase buffer (#2502)
* Use new callback from udev / only forward

* minimize loop

* Udev - move away form depricated callback / increase buffer

* code cleanup
2021-02-01 17:33:53 +01:00
Joakim Sørensen
a3555c74e8 Bump awesomeversion from 21.1.8 to 21.2.0 (#2501) 2021-02-01 15:45:35 +01:00
Pascal Vizeli
657bafd458 Fix handling with shm and shared /dev (#2499)
* Fix handling with shm and shared /dev

* address commends

* let's share shm
2021-02-01 14:44:02 +01:00
Joakim Sørensen
2ad5df420c Rerun label check on synchronize (#2500) 2021-02-01 14:37:56 +01:00
Joakim Sørensen
b24d489ec5 Update frontend to a9192ae2 (#2498) 2021-02-01 13:26:54 +01:00
Franck Nijhof
6bb0210f1f Fix add-on is_valid check (#2497) 2021-02-01 11:27:34 +01:00
dependabot[bot]
c1de50266a Bump pytz from 2020.5 to 2021.1 (#2496)
Bumps [pytz](https://github.com/stub42/pytz) from 2020.5 to 2021.1.
- [Release notes](https://github.com/stub42/pytz/releases)
- [Commits](https://github.com/stub42/pytz/compare/release_2020.5...release_2021.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-01 11:27:17 +01:00
dependabot[bot]
562e02bc64 Bump pyupgrade from 2.7.4 to 2.8.0 (#2494)
Bumps [pyupgrade](https://github.com/asottile/pyupgrade) from 2.7.4 to 2.8.0.
- [Release notes](https://github.com/asottile/pyupgrade/releases)
- [Commits](https://github.com/asottile/pyupgrade/compare/v2.7.4...v2.8.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-01 11:27:04 +01:00
dependabot[bot]
f71ec7913a Bump awesomeversion from 21.1.5 to 21.1.8 (#2493)
Bumps [awesomeversion](https://github.com/ludeeus/awesomeversion) from 21.1.5 to 21.1.8.
- [Release notes](https://github.com/ludeeus/awesomeversion/releases)
- [Commits](https://github.com/ludeeus/awesomeversion/compare/21.1.5...21.1.8)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-01 11:26:51 +01:00
dependabot[bot]
d98baaf660 Bump jinja2 from 2.11.2 to 2.11.3 (#2495)
Bumps [jinja2](https://github.com/pallets/jinja) from 2.11.2 to 2.11.3.
- [Release notes](https://github.com/pallets/jinja/releases)
- [Changelog](https://github.com/pallets/jinja/blob/master/CHANGES.rst)
- [Commits](https://github.com/pallets/jinja/compare/2.11.2...2.11.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-01 11:26:30 +01:00
Pascal Vizeli
72db591576 Validate build env before using it (#2492) 2021-02-01 09:46:48 +01:00
Wouter Schoot
509a37fc04 Typofix exsist -> exist (#2491)
* Typofix exsist -> exist

* Typofix exist -> exists
2021-02-01 09:34:17 +01:00
Pascal Vizeli
17f62b6e86 Handle corrupt store branch / ignore local reset on corruption (#2490)
* Handle corrupt store branch / ignore local reset on corruption

* Update data.py

* Update data.py
2021-01-31 22:55:43 +01:00
Pascal Vizeli
b09aee7644 Filter out virtual vcs devices (#2489)
* Filter out virtual vcs devices

* fix test
2021-01-31 14:40:14 +01:00
Pascal Vizeli
babcc0de0c Cleanup supervisor/udev device action / add GPIO (#2488)
* Cleanup supervisor/udev device action / add GPIO

* Apply francks comment
2021-01-31 14:24:22 +01:00
Franck Nijhof
5cc47c9222 Re-enable old template until form is resolved (#2486) 2021-01-30 19:47:45 +01:00
Franck Nijhof
833559a3b3 Add initial GitHub Issue Form (#2485)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2021-01-30 19:35:15 +01:00
Pascal Vizeli
b8a976b344 Change handling kernel udev events (#2484)
* Change handling kernel udev events / add USB events

* finish USB

* map dev ro

* fix bind
2021-01-30 14:19:53 +01:00
Joakim Sørensen
10b14132b9 Update frontend to 86847263 (#2483) 2021-01-29 18:23:58 +01:00
Pascal Vizeli
18953f0b7c plug & play devices (#2482)
* Add support for plug&play container & full udev passtrhough

* plug & play devices

* this hack is not needed anymore

* Fix GPIO issue

* Apply suggestions from code review

Co-authored-by: Franck Nijhof <git@frenck.dev>

Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-01-29 17:17:41 +01:00
Joakim Sørensen
19f5fba3aa Bump awesomeversion from 21.1.4 to 21.1.5 (#2481) 2021-01-29 14:10:06 +01:00
Pascal Vizeli
636bc3e61a Handle GPIO / VIDEO map with subystem (#2478)
* Handle GPIO / VIDEO mapping with subystem

* fix tests

* add udev support

* init udev data

* fix
2021-01-29 11:28:16 +01:00
Pascal Vizeli
521037e1a6 Fix mknod creating of the device on runtime time (#2477) 2021-01-28 17:07:33 +01:00
Pascal Vizeli
e024c3e38d Improve device selection and show device by id if available (#2476) 2021-01-28 15:43:06 +01:00
Pascal Vizeli
6a0206c1e7 Next generation hardware handling (#2429)
* Next generation hardware handling

* need daemon for some details

* fix tests

* fix wrong coresys lookup

* test initial import

* test device lookup

* validate if device exists

* Add cgroups rules manager

* mapping udev from host

* Modify validation/options handling

* lookup devices

* add support for host udev mapping

* next

* Add policy support to add-ons

* Depricate hardware trigger call

* next cleanup round

* detect USB linking

* optimize

* readd udev utils for backwards compatibility

* fix tests

* Add more tests

* fix tests

* Make device explicit

* Add filter

* work on tests

* Add migration step

* clean out auto_uart

* Fix all tests

* Expose all device information

* small  improvment

* Fix loop over right devices

* Use migration for new device format

* Update rootfs/etc/cont-init.d/udev.sh

Co-authored-by: Franck Nijhof <git@frenck.dev>

* Fix old helper

* Fix API

* add helper for by-id

* fix tests

* Fix serial helper

* Fix hardware API schema

* Hide some virtual devices from tracking

* Apply suggestions from code review

Co-authored-by: Stefan Agner <stefan@agner.ch>

* Update supervisor/addons/validate.py

Co-authored-by: Stefan Agner <stefan@agner.ch>

* Update supervisor/addons/validate.py

Co-authored-by: Stefan Agner <stefan@agner.ch>

* fix lint

* Apply suggestions from code review

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Apply suggestions from code review

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* fix black

* fix lint

Co-authored-by: Franck Nijhof <git@frenck.dev>
Co-authored-by: Stefan Agner <stefan@agner.ch>
Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2021-01-28 15:26:56 +01:00
Joakim Sørensen
69a8a83528 Limit label check (#2475) 2021-01-28 12:07:42 +01:00
Joakim Sørensen
0307d700fa Add TypeError guard for docker stats (#2474) 2021-01-28 11:58:04 +01:00
Joakim Sørensen
919c383b41 Bump awesomeversion from 21.1.3 to 21.1.4 (#2473) 2021-01-28 11:41:11 +01:00
dependabot[bot]
d331af4d5a Bump pre-commit from 2.9.3 to 2.10.0 (#2472)
Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 2.9.3 to 2.10.0.
- [Release notes](https://github.com/pre-commit/pre-commit/releases)
- [Changelog](https://github.com/pre-commit/pre-commit/blob/master/CHANGELOG.md)
- [Commits](https://github.com/pre-commit/pre-commit/compare/v2.9.3...v2.10.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-28 08:46:29 +01:00
Joakim Sørensen
b5467d3c23 Update frontend to 5ee0250b (#2471) 2021-01-28 08:45:33 +01:00
dependabot[bot]
3ef0040d66 Bump coverage from 5.3.1 to 5.4 (#2470)
Bumps [coverage](https://github.com/nedbat/coveragepy) from 5.3.1 to 5.4.
- [Release notes](https://github.com/nedbat/coveragepy/releases)
- [Changelog](https://github.com/nedbat/coveragepy/blob/master/CHANGES.rst)
- [Commits](https://github.com/nedbat/coveragepy/compare/coverage-5.3.1...coverage-5.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-27 08:41:22 +01:00
Joakim Sørensen
ec4dfd2172 Add action to check PR labels (#2469)
* Check PR labels

* update

* update

* update

* only use lable events

* remove env stuff

* add back types
2021-01-26 14:21:05 +01:00
Pascal Vizeli
8f54d7c8e9 New version logic NM (#2466) 2021-01-26 10:33:35 +01:00
dependabot[bot]
b59e709dc0 Bump home-assistant/builder from 2020.11.0 to 2021.01.1 (#2468)
Bumps [home-assistant/builder](https://github.com/home-assistant/builder) from 2020.11.0 to 2021.01.1.
- [Release notes](https://github.com/home-assistant/builder/releases)
- [Commits](https://github.com/home-assistant/builder/compare/2020.11.0...e33ea8af3ad98e9ed7513cad92cc88fb303b42ff)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-26 10:17:50 +01:00
dependabot[bot]
b236e6c886 Bump pytest from 6.2.1 to 6.2.2 (#2467)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 6.2.1 to 6.2.2.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/6.2.1...6.2.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-26 09:47:45 +01:00
Pascal Vizeli
8acbb7d6f0 Fix API info calls access (#2464) 2021-01-25 10:45:08 +01:00
dependabot[bot]
49e4bc9381 Bump actions/stale from v3.0.14 to v3.0.15 (#2463)
Bumps [actions/stale](https://github.com/actions/stale) from v3.0.14 to v3.0.15.
- [Release notes](https://github.com/actions/stale/releases)
- [Commits](https://github.com/actions/stale/compare/v3.0.14...86561461b92875de77a8b2d2e75f004c826e8f45)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-25 09:59:20 +01:00
Philip Allgaier
36106cc08d Small README tweaks (#2460) 2021-01-24 21:18:06 +01:00
Pascal Vizeli
8f1763abe2 Fix OSError with custom component check (#2458) 2021-01-24 16:46:49 +01:00
Joakim Sørensen
480eebc6cb Update alert notification (#2457) 2021-01-23 21:06:55 +01:00
Pascal Vizeli
dccfffd979 Improve fixups with Job condition checks (#2451) 2021-01-21 16:48:25 +01:00
dependabot[bot]
1a978f4762 Bump pytest-cov from 2.11.0 to 2.11.1 (#2455)
Bumps [pytest-cov](https://github.com/pytest-dev/pytest-cov) from 2.11.0 to 2.11.1.
- [Release notes](https://github.com/pytest-dev/pytest-cov/releases)
- [Changelog](https://github.com/pytest-dev/pytest-cov/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest-cov/compare/v2.11.0...v2.11.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-21 09:29:47 +01:00
Pascal Vizeli
1fbc8f4060 Add discovery support for zwave_js (#2454)
* Add discovery support for zwave_js

* New schema

* hmm

* address comments
2021-01-20 16:51:51 +01:00
Pascal Vizeli
db3fc1421c Fix: stable issue with corrupt git repository / submodule (#2452) 2021-01-19 14:21:27 +01:00
dependabot[bot]
9ecd03db0e Bump pytest-cov from 2.10.1 to 2.11.0 (#2446)
Bumps [pytest-cov](https://github.com/pytest-dev/pytest-cov) from 2.10.1 to 2.11.0.
- [Release notes](https://github.com/pytest-dev/pytest-cov/releases)
- [Changelog](https://github.com/pytest-dev/pytest-cov/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest-cov/compare/v2.10.1...v2.11.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-18 13:54:22 +01:00
dependabot[bot]
f111ccb1b6 Bump awesomeversion from 21.1.2 to 21.1.3 (#2445)
Bumps [awesomeversion](https://github.com/ludeeus/awesomeversion) from 21.1.2 to 21.1.3.
- [Release notes](https://github.com/ludeeus/awesomeversion/releases)
- [Commits](https://github.com/ludeeus/awesomeversion/compare/21.1.2...21.1.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-18 13:54:07 +01:00
Joakim Sørensen
a32341cc5d Update frontend to 08c1b864 (#2444) 2021-01-17 17:54:42 +01:00
Pascal Vizeli
f73e277230 Fix issues with awesomeversion and representation (#2443) 2021-01-17 16:39:34 +01:00
Joakim Sørensen
8d8587ca29 Update wording in notification (#2438)
* Update wording in notification

* Update notify.py
2021-01-15 21:49:52 +01:00
Joakim Sørensen
88eb9511bf Add core version check (#2436)
* Add core version check

* Fix version handling, rename and use correct paths

* simplify check

* wrap approve check
2021-01-15 21:13:42 +01:00
Pascal Vizeli
e1068997ea Fix submodule update (#2434) 2021-01-15 14:28:31 +01:00
dependabot[bot]
560e04c64a Bump colorlog from 4.6.2 to 4.7.2 (#2432)
Bumps [colorlog](https://github.com/borntyping/python-colorlog) from 4.6.2 to 4.7.2.
- [Release notes](https://github.com/borntyping/python-colorlog/releases)
- [Commits](https://github.com/borntyping/python-colorlog/compare/v4.6.2...v4.7.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-15 14:24:40 +01:00
Joakim Sørensen
621ec03971 Ignore wheels on release (#2428)
* Fix wheels on publish

* ignore wheels for publish

* test

* revert test
2021-01-12 15:45:35 +01:00
Pascal Vizeli
d14a47d3f7 Auth: Improve authorisation (#2427) 2021-01-12 14:49:53 +01:00
Pascal Vizeli
3e9de0c210 Fix submodules - check if it is needed or not (#2426) 2021-01-12 13:53:04 +01:00
Joakim Sørensen
01a6e074a5 Adjust development tasks (#2425)
* Adjust development tasks

* add development
2021-01-12 13:50:11 +01:00
Joakim Sørensen
1434077f4e Update frontend panel to edcb7e87 (#2422) 2021-01-11 15:22:10 +01:00
Fredrik Erlandsson
3922175af1 Update git to support updates of submodules (#2378)
* Update git to support updates of submodules

* Remove unnecessary-comprehension

* prefix with **
2021-01-11 15:21:09 +01:00
Franck Nijhof
ec6852a8d7 Set a default for add-on options and schema config (#2421) 2021-01-11 12:36:19 +01:00
Pascal Vizeli
b0b908b4ae Fix missing repository (#2420) 2021-01-11 12:17:53 +01:00
Franck Nijhof
5a00336ef1 Set a default for add-on startup config (#2419) 2021-01-11 12:10:23 +01:00
Stefan Agner
d53f5e21f4 Increases core container timeout to match core shutdown time (#2417)
Align the core container timeout with what the core container
uses as grace period.
2021-01-11 11:24:54 +01:00
Stefan Agner
bd173fa333 Shutdown using systemd-logind if available (#2416)
The Reboot() and PowerOff() methods of the systemd D-Bus API are not
meant to be called directly when logind is in use. Make sure to use the
logind APIs if available.

Since OS release 5.1 systemd-logind is enabled.
2021-01-11 11:21:45 +01:00
Franck Nijhof
6b32fa31b6 Set a default for add-on boot config (#2418) 2021-01-11 11:17:23 +01:00
Joakim Sørensen
d1dba89e39 Add GitHub Action to build wheels (#2186)
* Make GitHub Action to build wheels

* try new

* fix branch

* fix typo

* test arch

* waitfor

* add ref

* fix wait

* fix name

* quote

* add complete step

* Update .github/workflows/wheels.yml

Co-authored-by: Franck Nijhof <git@frenck.dev>

* fix typo

* use name

* test

* merge them

* move

* test with requirement change

* add wheels-user

* revert version change

* use master

* bump awesomeversion

* set user

Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-01-08 18:57:35 +01:00
dependabot[bot]
b2f2806465 Bump gitpython from 3.1.11 to 3.1.12 (#2404)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.1.11 to 3.1.12.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.1.11...3.1.12)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-07 21:03:01 +01:00
Sergio Oller
3b70cd58a3 Allow GET method on /auth with BasicAuth (#2407)
* Allow GET on /auth with BasicAuth

* Accept GET without further validation

As suggested on https://github.com/home-assistant/supervisor/pull/2407#pullrequestreview-563712080
2021-01-07 21:02:36 +01:00
Joakim Sørensen
6769bfd824 Fix typo in reference (#2409) 2021-01-07 19:05:31 +01:00
dependabot[bot]
bff4af2534 Bump codecov/codecov-action from v1.2.0 to v1.2.1 (#2405)
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from v1.2.0 to v1.2.1.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/master/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v1.2.0...e156083f13aff6830c92fc5faa23505779fbf649)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-06 14:04:37 +01:00
dependabot[bot]
aabf575ac5 Bump actions/upload-artifact from v2.2.1 to v2.2.2 (#2400)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from v2.2.1 to v2.2.2.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v2.2.1...e448a9b857ee2131e752b06002bf0e093c65e571)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-05 09:50:24 +01:00
dependabot[bot]
4aacaf6bd6 Bump codecov/codecov-action from v1.1.1 to v1.2.0 (#2401)
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from v1.1.1 to v1.2.0.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/master/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v1.1.1...a92c414703a4bba586f6df7fcc885c9d0bdff772)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-05 09:49:32 +01:00
dependabot[bot]
268070e89c Bump dessant/lock-threads from v2.0.1 to v2.0.3 (#2398)
Bumps [dessant/lock-threads](https://github.com/dessant/lock-threads) from v2.0.1 to v2.0.3.
- [Release notes](https://github.com/dessant/lock-threads/releases)
- [Changelog](https://github.com/dessant/lock-threads/blob/master/CHANGELOG.md)
- [Commits](https://github.com/dessant/lock-threads/compare/v2.0.1...486f7380c15596f92b724e4260e4981c68d6bde6)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-04 09:37:26 +01:00
Joakim Sørensen
4fa2134cc6 Bump awesomeversion from 20.12.4 to 20.12.5 (#2394) 2021-01-02 22:13:35 +01:00
Pascal Vizeli
97c35de49a Refacture version handling with AwesomeVersion (#2392)
* Refacture version handling with AwesomeVersion

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* next

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* next

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* next

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* v20.12.3

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* next

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* next

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* fix exception

* fix schema

* cleanup plugins

* fix tests

* fix attach

* fix TypeError

* fix issue with compairing

* make lint happy

* Update supervisor/homeassistant/__init__.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Update tests/test_validate.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Update supervisor/docker/__init__.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Update supervisor/supervisor.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2020-12-31 17:09:33 +01:00
Joakim Sørensen
32fb550969 Bump docker to 4.4.1 (#2390) 2020-12-29 16:38:20 +01:00
dependabot[bot]
3457441929 Bump pytz from 2020.4 to 2020.5 (#2386)
Bumps [pytz](https://github.com/stub42/pytz) from 2020.4 to 2020.5.
- [Release notes](https://github.com/stub42/pytz/releases)
- [Commits](https://github.com/stub42/pytz/compare/release_2020.4...release_2020.5)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-28 16:26:50 +01:00
dependabot[bot]
32f0fc7a46 Bump codecov/codecov-action from v1.1.0 to v1.1.1 (#2381)
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from v1.1.0 to v1.1.1.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/master/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v1.1.0...1fc7722ded4708880a5aea49f2bfafb9336f0c8d)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-22 13:27:04 +01:00
dependabot[bot]
c891a8f164 Bump coverage from 5.3 to 5.3.1 (#2379)
Bumps [coverage](https://github.com/nedbat/coveragepy) from 5.3 to 5.3.1.
- [Release notes](https://github.com/nedbat/coveragepy/releases)
- [Changelog](https://github.com/nedbat/coveragepy/blob/master/CHANGES.rst)
- [Commits](https://github.com/nedbat/coveragepy/compare/coverage-5.3...coverage-5.3.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-21 15:18:02 +01:00
dependabot[bot]
991764af94 Bump actions/setup-python from v2.2.0 to v2.2.1 (#2380)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from v2.2.0 to v2.2.1.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](https://github.com/actions/setup-python/compare/v2.2.0...3105fb18c05ddd93efea5f9e0bef7a03a6e9e7df)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-21 15:17:25 +01:00
dependabot[bot]
1df447272e Bump codecov/codecov-action from v1.0.15 to v1.1.0 (#2375)
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from v1.0.15 to v1.1.0.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/master/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v1.0.15...7de43a7373de21874ae196a78f8eb633fcf7f0c4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-18 21:42:42 +01:00
dependabot[bot]
f032ae757b Bump actions/setup-python from v2.1.4 to v2.2.0 (#2376)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from v2.1.4 to v2.2.0.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](https://github.com/actions/setup-python/compare/v2.1.4...8c5ea631b2b2d5d8840cf4a2b183a8a0edc1e40d)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-18 21:42:10 +01:00
dependabot[bot]
e529b2859e Bump codecov from 2.1.10 to 2.1.11 (#2377)
Bumps [codecov](https://github.com/codecov/codecov-python) from 2.1.10 to 2.1.11.
- [Release notes](https://github.com/codecov/codecov-python/releases)
- [Changelog](https://github.com/codecov/codecov-python/blob/master/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-python/compare/v2.1.10...v2.1.11)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-18 21:40:42 +01:00
Casper
d1cb2368fa fix typo (#2372) 2020-12-16 10:13:20 +01:00
dependabot[bot]
7b812184d1 Bump pytest from 6.2.0 to 6.2.1 (#2373)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 6.2.0 to 6.2.1.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/6.2.0...6.2.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-16 10:12:57 +01:00
dependabot[bot]
4f7ce1c6ee Bump cryptography from 3.2.1 to 3.3.1 (#2360)
Bumps [cryptography](https://github.com/pyca/cryptography) from 3.2.1 to 3.3.1.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/3.2.1...3.3.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-15 12:52:47 +01:00
dependabot[bot]
44a5ac63db Bump pytest from 6.1.2 to 6.2.0 (#2365)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 6.1.2 to 6.2.0.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/6.1.2...6.2.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-15 12:52:22 +01:00
Joakim Sørensen
0989ee88cc Pin docker-py to commit (#2371)
Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-12-15 12:48:50 +01:00
dependabot[bot]
ba8b72c2c8 Bump sentry-sdk from 0.19.4 to 0.19.5 (#2362)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.19.4 to 0.19.5.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.19.4...0.19.5)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-15 12:28:11 +01:00
dependabot[bot]
2dbb4583f4 Bump debugpy from 1.2.0 to 1.2.1 (#2370)
Bumps [debugpy](https://github.com/microsoft/debugpy) from 1.2.0 to 1.2.1.
- [Release notes](https://github.com/microsoft/debugpy/releases)
- [Commits](https://github.com/microsoft/debugpy/compare/v1.2.0...v1.2.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-15 12:26:45 +01:00
Robin
81ad42e029 Fix typo in log message when completing snapshot (#2367) 2020-12-15 10:49:40 +01:00
dependabot[bot]
5d3695f8ba Bump pre-commit from 2.9.2 to 2.9.3 (#2356)
Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 2.9.2 to 2.9.3.
- [Release notes](https://github.com/pre-commit/pre-commit/releases)
- [Changelog](https://github.com/pre-commit/pre-commit/blob/master/CHANGELOG.md)
- [Commits](https://github.com/pre-commit/pre-commit/compare/v2.9.2...v2.9.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-08 08:35:18 +01:00
Pascal Vizeli
c771694aa0 Show link for help user with unsupported systems (#2354)
* Show link for help user with unsupported systems

* Update .github/ISSUE_TEMPLATE/config.yml

Co-authored-by: Franck Nijhof <git@frenck.dev>

Co-authored-by: Franck Nijhof <git@frenck.dev>
2020-12-07 11:45:46 +01:00
Pascal Vizeli
1ac0fd4c10 Add note for unsupported system (#2353) 2020-12-07 11:00:27 +01:00
dependabot[bot]
631ff8caef Bump voluptuous from 0.12.0 to 0.12.1 (#2352)
Bumps [voluptuous](https://github.com/alecthomas/voluptuous) from 0.12.0 to 0.12.1.
- [Release notes](https://github.com/alecthomas/voluptuous/releases)
- [Changelog](https://github.com/alecthomas/voluptuous/blob/master/CHANGELOG.md)
- [Commits](https://github.com/alecthomas/voluptuous/compare/0.12.0...0.12.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-07 10:39:49 +01:00
Joakim Sørensen
7382182132 Add changes to release drafter (#2349)
* Add changes to release drafter

* remove duplicate

* Add more labels

* add CI

* remove enhacement
2020-12-06 13:24:09 +01:00
Joakim Sørensen
4ff9da68ef Actually use the vlan_struct (#2347) 2020-12-05 13:04:37 +01:00
Pascal Vizeli
dee2998ee3 Fix issue with mark system wrong as rollback (#2345) 2020-12-05 11:19:27 +01:00
Pascal Vizeli
1d43236211 Upgrade json config handler logging to critical (#2344) 2020-12-05 10:57:20 +01:00
Pascal Vizeli
792bc610a3 Fix NM byte switch for ipv6 nameserver (#2342)
* Fix NM byte switch for ipv6 nameserver

* remove not needed code
2020-12-04 17:55:26 +01:00
Pascal Vizeli
7a51c828c2 Fix wrong exception handler 2020-12-04 15:26:13 +00:00
Pascal Vizeli
fab6fcd5ac Check NetworkManager Version if it is supported (#2340)
Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2020-12-04 12:38:12 +01:00
Joakim Sørensen
c8e00ba160 Adds vlan_struct (#2337)
* Return VLAN ID instead of wifistruct for VLAN

* Use vlan_struct

* fix typing

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-12-04 11:37:55 +01:00
Joakim Sørensen
6245b6d823 Fix KeyError in connectivity_enabled (#2336) 2020-12-03 21:40:34 +01:00
Pascal Vizeli
0c55bf20fc Fix issue on store git clone (#2331) 2020-12-03 21:06:48 +01:00
Pascal Vizeli
f8fd7b5933 Improve error handling with job condition (#2322)
* Improve error handling with job condition

* fix

* first patch

* last patch

* Address comments

* Revert strange replace
2020-12-03 12:24:32 +01:00
Pascal Vizeli
6462eea2ef Fix sentry stdlib spam (#2326) 2020-12-02 17:24:40 +01:00
Pascal Vizeli
3d79891249 Make dbus connection more robust (#2325)
* Make dbus connection more robust

* move rauc down
2020-12-02 17:22:28 +01:00
Pascal Vizeli
80763c4bbf Support OTA url over version files (#2324)
* Support OTA url over version files

* Fix new schema
2020-12-02 14:59:42 +01:00
Pascal Vizeli
59102afd45 Fix sentry with sets (#2323) 2020-12-02 12:43:38 +01:00
Pascal Vizeli
0b085354db Send list of images to sentry (#2321) 2020-12-01 14:29:37 +01:00
Pascal Vizeli
e2a473baa3 Add network reload to api (#2319) 2020-12-01 14:03:59 +01:00
Pascal Vizeli
06e10fdd3c Fix NM naming schema (#2318)
* Fix NM naming schema

* Address comments

* Add test
2020-12-01 12:11:20 +01:00
Pascal Vizeli
fb4386a7ad Use persistent MAC address instead clone / don't touch default (#2317) 2020-12-01 09:27:49 +01:00
Pascal Vizeli
2d294f6841 Make evaluation of container better (#2316) 2020-11-30 18:00:12 +01:00
Pascal Vizeli
e09a839148 Fix byte order for network DNS settings (#2315) 2020-11-30 15:22:02 +01:00
Pascal Vizeli
d9c4dae739 Send error to sentry from update 2020-11-30 10:28:05 +00:00
Pascal Vizeli
49853e92a4 Fix sentry spam (#2313) 2020-11-30 11:01:10 +01:00
Pascal Vizeli
19620d6808 Fix: cleanup repository from list (#2310)
* Fix: cleanup repository from list

* Add repr

* Avoid not exists error message
2020-11-29 14:00:29 +01:00
Pascal Vizeli
f6bf44de1c Add tests for remove function (#2309) 2020-11-29 12:34:33 +01:00
Pascal Vizeli
06fae59fc8 Remove corrupt FS on store sentry report (#2308) 2020-11-28 18:11:56 +01:00
Pascal Vizeli
5c25fcd84c Reset on invalid filesystem (#2307) 2020-11-28 15:57:00 +01:00
Pascal Vizeli
aa5297026f Handle Store suggestion (#2306)
* Handle Store suggestion

* Add fixup

* Add more fixup & list

* Enable fixups

* Add tests

* fix index

* fix break

* fix import

* Load it anyway

* Run suFix ccestion on load too

* fix error message

* fix error message

* Fix remove

* Finishing

* Add tests

* Fix error

* fix cleanup stale stuff

* Fix source

* use source as url

* add test for url

* Apply suggestions from code review

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2020-11-28 15:03:44 +01:00
Joakim Sørensen
841520b75e Strip device names (#2303) 2020-11-26 22:40:54 +01:00
Pascal Vizeli
d9e20307de Allow check to cleanup issues (#2302) 2020-11-26 22:38:33 +01:00
Pascal Vizeli
fda1b523ba Extend resolution center (#2297)
* Extend resolution center

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* move forward

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* Rename it to fixups

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* Finish p1

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* Finish p1 - add files

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* Finishup

* Add more tests

* Add test for suggestion

* Add more tests

* fix tests & isort

* address comments

* address comments v2

* fix isort

* Change reference handling
2020-11-26 17:16:36 +01:00
dependabot[bot]
7cccbc682c Bump pre-commit from 2.9.0 to 2.9.2 (#2300)
Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 2.9.0 to 2.9.2.
- [Release notes](https://github.com/pre-commit/pre-commit/releases)
- [Changelog](https://github.com/pre-commit/pre-commit/blob/master/CHANGELOG.md)
- [Commits](https://github.com/pre-commit/pre-commit/compare/v2.9.0...v2.9.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-26 08:30:35 +01:00
Pascal Vizeli
621eb4c4c0 Don't send DBusProgramError to sentry (#2294)
* Don't send DBusProgramError to sentry

* Add message
2020-11-24 14:18:00 +01:00
Pascal Vizeli
056926242f Fix sentry resoluton messages (#2295) 2020-11-24 14:17:47 +01:00
Pascal Vizeli
84294f286f Add unhealthy if update fails on startup 2020-11-24 12:51:16 +00:00
Joakim Sørensen
b6bc6b8498 Update frontend panel to 1d367eca (#2293) 2020-11-24 11:56:35 +01:00
Pascal Vizeli
845c935b39 Add JobManager API ignore (#2290)
* Disable job condition for unhealth & unsupported systems

* Add JobManager API ignore

* Apply suggestions from code review

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>

* Update tests/resolution/evaluation/test_evaluate_job_conditions.py

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>

* fix names

* address comments

* Update decorator.py

* adjust security

* add reset

* Apply suggestions from code review

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2020-11-24 10:54:57 +01:00
dependabot[bot]
19d8de89df Bump docker from 4.3.1 to 4.4.0 (#2292)
Bumps [docker](https://github.com/docker/docker-py) from 4.3.1 to 4.4.0.
- [Release notes](https://github.com/docker/docker-py/releases)
- [Commits](https://github.com/docker/docker-py/compare/4.3.1...4.4.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-24 08:49:22 +01:00
Joakim Sørensen
cfae20a3ec Change snapshot create conditions (#2289) 2020-11-23 22:57:41 +01:00
Joakim Sørensen
6db6ab96e6 Update frontend panel to 0ef88816 (#2291) 2020-11-23 22:57:11 +01:00
dependabot[bot]
48695c6805 Bump actions/stale from v3.0.13 to v3.0.14 (#2286)
Bumps [actions/stale](https://github.com/actions/stale) from v3.0.13 to v3.0.14.
- [Release notes](https://github.com/actions/stale/releases)
- [Commits](https://github.com/actions/stale/compare/v3.0.13...87c2b794b9b47a9bec68ae03c01aeb572ffebdb1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-23 09:36:20 +01:00
dependabot[bot]
d74908e3b5 Bump pre-commit from 2.8.2 to 2.9.0 (#2287)
Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 2.8.2 to 2.9.0.
- [Release notes](https://github.com/pre-commit/pre-commit/releases)
- [Changelog](https://github.com/pre-commit/pre-commit/blob/master/CHANGELOG.md)
- [Commits](https://github.com/pre-commit/pre-commit/compare/v2.8.2...v2.9.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-23 09:30:41 +01:00
Pascal Vizeli
7e94537e36 Soft restart supervisor (#2281)
* Add softrestart to supervisor

* decouble

* adjust logger

* make sure it need run

* Use job condition

* add more job running
2020-11-21 12:48:16 +01:00
Pascal Vizeli
1427e0ae96 Add jobs decorator to add-ons/snapshot/core and remove 404 hack (#2280)
* Add jobs decorator to add-ons/snapshot/core and remove 404 hack

* add to repair
2020-11-21 10:47:15 +01:00
Pascal Vizeli
01e27dfa2f Wifi mode old NM (#2279) 2020-11-21 10:20:31 +01:00
Joakim Sørensen
f48249c9d1 Remove HEALTHY from update_repositories (#2277) 2020-11-21 10:07:44 +01:00
Joakim Sørensen
e607d4feeb Fix missing primary interface after change (#2274)
* Fix missing primary interface after change

* Fix test
2020-11-20 12:01:59 +01:00
Joakim Sørensen
5367ac257e Update frontend panel to 46f55895 (#2275) 2020-11-20 11:51:43 +01:00
Joakim Sørensen
46dc6dc63b Add log about ratelimit (#2271)
* Add log about ratelimit

* Update wording

* create issue
2020-11-20 10:50:26 +01:00
dependabot[bot]
a59ea72c66 Bump sentry-sdk from 0.19.3 to 0.19.4 (#2273)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.19.3 to 0.19.4.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.19.3...0.19.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-20 09:44:28 +01:00
Pascal Vizeli
2daf46c444 Rename add-ons repository (#2272) 2020-11-19 21:10:37 +01:00
Pascal Vizeli
1bf38bdc99 Use Brotli instead of brotlipy (#2270) 2020-11-19 09:24:40 +01:00
dependabot[bot]
131909973c Bump aiohttp from 3.7.2 to 3.7.3 (#2269)
Bumps [aiohttp](https://github.com/aio-libs/aiohttp) from 3.7.2 to 3.7.3.
- [Release notes](https://github.com/aio-libs/aiohttp/releases)
- [Changelog](https://github.com/aio-libs/aiohttp/blob/master/CHANGES.rst)
- [Commits](https://github.com/aio-libs/aiohttp/compare/v3.7.2...v3.7.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-19 08:35:04 +01:00
Pascal Vizeli
ecdf4e53b8 Use atomic writes to make it more stable again full disk (#2267) 2020-11-18 17:08:57 +01:00
Pascal Vizeli
7aa039d162 Missing log what going on (#2268) 2020-11-18 17:08:28 +01:00
Pascal Vizeli
3dd3340e35 Make host feature cheaper to call and relay on it (#2266) 2020-11-18 14:13:49 +01:00
Pascal Vizeli
2f9fc39b72 Check if connectivity check if available on host (#2265)
* Check if connectivity check if available on host

* fix get

* not needed

* Update const.py

* Use enabled
2020-11-18 12:40:55 +01:00
Pascal Vizeli
80f4309799 Enforce internet host/system (#2263) 2020-11-18 11:29:23 +01:00
Pascal Vizeli
550fca4bcd Remove coroutine from job update (#2264) 2020-11-18 11:25:04 +01:00
Pascal Vizeli
4b500ef873 JobManager should not touch our exceptions (#2261)
* JobManager should not touch our exceptions

* Add tests

* temporary allow su update all time

* Update supervisor/jobs/decorator.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2020-11-17 18:46:02 +01:00
dependabot[bot]
476f021fbf Bump debugpy from 1.1.0 to 1.2.0 (#2260)
Bumps [debugpy](https://github.com/microsoft/debugpy) from 1.1.0 to 1.2.0.
- [Release notes](https://github.com/microsoft/debugpy/releases)
- [Commits](https://github.com/microsoft/debugpy/compare/v1.1.0...v1.2.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-17 18:38:00 +01:00
dependabot[bot]
8393ca5b23 Bump codecov/codecov-action from v1.0.14 to v1.0.15 (#2259)
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from v1.0.14 to v1.0.15.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Commits](https://github.com/codecov/codecov-action/compare/v1.0.14...239febf655bba88b16ff5dea1d3135ea8663a1f9)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-17 08:56:32 +01:00
dependabot[bot]
4eb7a60b88 Bump actions/upload-artifact from v2.2.0 to v2.2.1 (#2257)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from v2.2.0 to v2.2.1.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v2.2.0...726a6dcd0199f578459862705eed35cda05af50b)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-16 12:34:50 +01:00
Pascal Vizeli
2040102e21 Handle Unhealthy like Unsupported (#2255)
* Handle Unhealthy like Unsupported

* Add tests

* Add unhealthy to sentry

* Add test
2020-11-14 16:16:00 +01:00
Joakim Sørensen
7ee5737f75 Activate new network settings after update (#2253) 2020-11-13 18:15:46 +01:00
Pascal Vizeli
8d499753a0 Fix auto interface method (#2252) 2020-11-13 16:58:28 +01:00
Pascal Vizeli
028ec277eb Enable support for mdns & llmnr for host (#2251) 2020-11-13 16:47:56 +01:00
Pascal Vizeli
5552b1da49 Optimize flow / reduce call time (#2250)
* Optimize flow / reduce call time

* rename

* freeze too

* add connectivity task

* use newstyle timeout

* Fix tests

Co-authored-by: Ludeeus <ludeeus@ludeeus.dev>
2020-11-13 12:19:10 +01:00
Joakim Sørensen
06ab7e904f Split check for internet connection to help troubleshooting (#2248)
* Split check for internet connection to help troubleshooting

* Siplify

* revert

* cleanup

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-11-13 08:58:07 +01:00
Pascal Vizeli
e4bf820038 Check & fix git repository integrity (#2245)
* Check & fix git repository integrity

* fix typing

* New style error handling

* Fix return

* tag more issue

* Fix black
2020-11-13 08:35:45 +01:00
dependabot[bot]
c209d2fa8d Bump sentry-sdk from 0.19.2 to 0.19.3 (#2249)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.19.2 to 0.19.3.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.19.2...0.19.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-13 08:27:31 +01:00
Joakim Sørensen
784c5d3b7c Use bool for host internet (#2247)
* Use bool for host internet

* Ignore host check if no network manager

* Update supervisor/host/network.py

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>

* Check dbus connection isntead of supported features

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-11-13 00:07:05 +01:00
Joakim Sørensen
a18b706f99 Add JobManager and Job decorator (#2225)
* Adds condition decorator to block execution that require internet

* Fix exsisting tests

* Add internet state to network info

* Add healthy condition

* Add tests

* It's all changed

* rename
2020-11-12 22:57:28 +01:00
Pascal Vizeli
cd34a40dd8 Send issues with sentry report (#2246) 2020-11-12 14:57:04 +01:00
Pascal Vizeli
ced72e1273 Fix show update if version is None (#2244) 2020-11-12 10:11:38 +01:00
Pascal Vizeli
5416eda1d6 Improve the error logging with new DBusProgramError (#2243) 2020-11-12 09:34:43 +01:00
Pascal Vizeli
c76a4ff422 Revert: psk is not readable and only exists on initial (#2242)
* Revert: psk is not readable and only exists on initial

* fix tests
2020-11-11 21:07:28 +01:00
Stefan Agner
d558ad2d76 Use technology neutral "auto" instead of "dhcp" for autoconfiguration (#2241)
* Use technology neutral "auto"  instead of "dhcp" for autoconfiguration

IPv6 is often run with SLAAC which does not use a DHCP server but still
does automatic address configuration. Follow wording of NetworkManager
and use "auto" instead.

* Use "auto" also in interface_update.tmpl

* Update interface_update.tmpl

* remove newline

Co-authored-by: Pascal Vizeli <pascal.vizeli@syshack.ch>
Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-11-11 18:23:04 +01:00
Pascal Vizeli
5f2d183b1d Fix wifi conversation (#2240)
* Fix wifi conversation

* Fix naming

* simple
2020-11-11 17:09:48 +01:00
Pascal Vizeli
46e92036ec Fix handling with open or wpa-psk (#2239) 2020-11-11 16:33:46 +01:00
Pascal Vizeli
280d423bfe Fix error if a wlan scan is allready running (#2238)
* Fix error if a wlan scan is allready running

* fix other messages too
2020-11-11 13:48:50 +01:00
Pascal Vizeli
c4847ad10d Handle dbus single byte (#2237) 2020-11-11 13:09:13 +01:00
dependabot[bot]
0a7c75830b Bump pyupgrade from 2.7.3 to 2.7.4 (#2236)
Bumps [pyupgrade](https://github.com/asottile/pyupgrade) from 2.7.3 to 2.7.4.
- [Release notes](https://github.com/asottile/pyupgrade/releases)
- [Commits](https://github.com/asottile/pyupgrade/compare/v2.7.3...v2.7.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-11 08:45:07 +01:00
Pascal Vizeli
7aceb21123 Fix auth mode WEP (#2235)
* Fix auth mode WEP

* fix mapping
2020-11-10 18:07:20 +01:00
Pascal Vizeli
9264d437b1 Fix network API default value & tests (#2234) 2020-11-10 15:08:35 +01:00
Franck Nijhof
edc8d8960f Replace stale bot with GitHub Action (#2232) 2020-11-10 09:15:34 +01:00
dependabot[bot]
0f4f196dc9 Bump colorlog from 4.5.0 to 4.6.2 (#2233)
Bumps [colorlog](https://github.com/borntyping/python-colorlog) from 4.5.0 to 4.6.2.
- [Release notes](https://github.com/borntyping/python-colorlog/releases)
- [Commits](https://github.com/borntyping/python-colorlog/compare/v4.5.0...v4.6.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-10 09:15:01 +01:00
Pascal Vizeli
a027f4b5fc Revert info back to debug 2020-11-09 15:11:57 +00:00
Franck Nijhof
f025d1df05 Replace lock bot with GitHub Action (#2231) 2020-11-09 13:07:23 +01:00
Pascal Vizeli
4c560d7c54 Fix gateway None on API (#2230)
* Fix gateway None on API

* fix tests
2020-11-09 10:00:39 +01:00
Pascal Vizeli
a976ef6e67 Cleanup some logger (#2229) 2020-11-09 09:56:01 +01:00
Pascal Vizeli
e1b9d754af Fix all interface are primary (#2228) 2020-11-09 09:27:16 +01:00
Pascal Vizeli
ee49935b7d Odroid-C4 (#2226)
* Add Odroid-C4

* add machine
2020-11-09 08:57:18 +01:00
dependabot[bot]
36694c9ef0 Bump colorlog from 4.4.0 to 4.5.0 (#2227)
Bumps [colorlog](https://github.com/borntyping/python-colorlog) from 4.4.0 to 4.5.0.
- [Release notes](https://github.com/borntyping/python-colorlog/releases)
- [Commits](https://github.com/borntyping/python-colorlog/compare/v4.4.0...v4.5.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-09 08:57:08 +01:00
Pascal Vizeli
bd786811a3 Network: abstract dbus and supervisor - ipv6/wifi/vlan (#2217)
* Abstract code between dbus - supervisor

* cleanup v2

* fix address vs interface

* fix API calls

* Fix methodnames

* add vlan type

* add vlan support

* Fix tests

* Add wifi support

* more OOO

* fix typing import

* typing part 2

* Fix profile

* fix test payload

* ignore powersafe

* support privancy

* fix property

* Fix tests

* full support all API

* Fix all

* more robust

* Update supervisor/dbus/network/connection.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Fix gateway

* fix empty gateway

* Allow no ipv6 or ipv4 kernel support

* Exclude device drivers

* Add wifi

* Use loop on api

* refactory p1

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* refactory p2

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* refactory p3

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* refactory p4

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* refactory p5

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* refactory p6

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* refactory p7

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* refactory p8

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* Fix lint

* update sup p1

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* update sup p2

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* fix tests

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* fix logging

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* improve mock handling

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* add fixtures

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* fix tests

* better testing

* Add more tests

* Fix API test

* Add test for vlan payload

* Support variation

* Fix doc string

* support remove & wifi scan

* make sure we ignore local-link on ipv6

* remove privancy - add vlan

* Fix tests

* fix isort

* Fixture dbus by commands

* Add dnsmanager fixture

* expose commands called by dbus

* Add wifi tests

* Update supervisor/plugins/dns.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Address comments & fix tests

* change url to be closer on others

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2020-11-09 08:56:42 +01:00
Paulus Schoutsen
ffaeb2b96d Add validate session API (#2223) 2020-11-06 11:52:11 +01:00
dependabot[bot]
517e6cb437 Bump attrs from 20.2.0 to 20.3.0 (#2222)
Bumps [attrs](https://github.com/python-attrs/attrs) from 20.2.0 to 20.3.0.
- [Release notes](https://github.com/python-attrs/attrs/releases)
- [Changelog](https://github.com/python-attrs/attrs/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/python-attrs/attrs/compare/20.2.0...20.3.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-06 11:45:42 +01:00
Joakim Sørensen
9479672b88 Create evaluation modules (#2220)
* Create evaluation modules

* Use sys_core
2020-11-05 17:36:02 +01:00
Joakim Sørensen
934e59596a Adds more logs to session validation (#2219)
* Adds more logs to session validation

* It's not there

* Use debug

* format

* Create new timestamp if OverflowError
2020-11-05 10:40:56 +01:00
Joakim Sørensen
8f4ac10361 Add login support for dockerhub (#2218)
* Add login support for dockerhub

* Remove registry
2020-11-05 10:39:53 +01:00
Pascal Vizeli
50e0fd159f Add process lock for update + fix timeout (#2215) 2020-11-03 18:12:57 +01:00
Pascal Vizeli
28344ff5f3 Supervisor container startup health function (#2214)
* Supervisor container startup health function

* better struct

* add test

* address comment

* rename file

* Update tests/test_main.py

Co-authored-by: Stefan Agner <stefan@agner.ch>

Co-authored-by: Stefan Agner <stefan@agner.ch>
2020-11-03 16:36:10 +01:00
dependabot[bot]
608ae14246 Bump sentry-sdk from 0.19.1 to 0.19.2 (#2211)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.19.1 to 0.19.2.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.19.1...0.19.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-03 09:58:43 +01:00
dependabot[bot]
c0c0d44c2d Bump home-assistant/builder from 2020.10.0 to 2020.11.0 (#2210)
Bumps [home-assistant/builder](https://github.com/home-assistant/builder) from 2020.10.0 to 2020.11.0.
- [Release notes](https://github.com/home-assistant/builder/releases)
- [Commits](https://github.com/home-assistant/builder/compare/2020.10.0...c60c59d1300ac720519bbf35026f6b6904214d71)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-03 09:58:12 +01:00
Pascal Vizeli
5e947348ae Fix pulse cookie error (#2212) 2020-11-03 09:54:31 +01:00
Joakim Sørensen
1f4032f56f Add the log stream from docker if build fails (#2207)
* Add the log stream from docker if build fails

* Check if dict
2020-11-02 11:44:11 +01:00
dependabot[bot]
336ab0d2b1 Bump pre-commit from 2.8.1 to 2.8.2 (#2206)
Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 2.8.1 to 2.8.2.
- [Release notes](https://github.com/pre-commit/pre-commit/releases)
- [Changelog](https://github.com/pre-commit/pre-commit/blob/master/CHANGELOG.md)
- [Commits](https://github.com/pre-commit/pre-commit/compare/v2.8.1...v2.8.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-02 09:58:55 +01:00
dependabot[bot]
0f9d80dde4 Bump pytz from 2020.1 to 2020.4 (#2205)
Bumps [pytz](https://github.com/stub42/pytz) from 2020.1 to 2020.4.
- [Release notes](https://github.com/stub42/pytz/releases)
- [Commits](https://github.com/stub42/pytz/compare/release_2020.1...release_2020.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-02 09:58:36 +01:00
Joakim Sørensen
0fcab4d92b Fix missing metadata in the issue template (#2200) 2020-10-30 17:18:37 +01:00
Joakim Sørensen
abd35b62c8 Update issue template (#2199) 2020-10-30 17:11:51 +01:00
Pascal Vizeli
7b721ad8c6 Fix initialized state on dead/removing/pause containers (#2197) 2020-10-30 16:16:07 +01:00
Joakim Sørensen
37eaaf356d Add run_supervisor step to builder action (#2195)
* Add run_supervisor step to builder action

* split

* build it

* wording

* move so version push can depend on it
2020-10-30 13:42:45 +01:00
Pascal Vizeli
8cbb4b510b Init template sooner (#2194) 2020-10-30 10:37:34 +01:00
Pascal Vizeli
f71549e3df New fix for stale container on network (#2189)
* New fix for stale container on network

* fix core repair

* Clenaup before attach to network

* Fix reload

* Fix host network

* Fix prune network

* Remove refresh

* Fix unpack

* better name

* clean order

* Add comment why

* more comments

* Update supervisor/misc/tasks.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2020-10-30 10:03:05 +01:00
Joakim Sørensen
fe15bb6a30 Add workflow_dispatch for manual action run (#2192) 2020-10-29 18:31:52 +01:00
Pascal Vizeli
50d36b857a DNS plugin maintainance (#2179)
* DNS plugin maintainance

* cleanup old data

* move fallback to plugin

* smaller

* Allow plugin to write into config persistent

* Fix hosts

* create issue on dns loop
2020-10-29 15:48:57 +01:00
dependabot[bot]
db260dfbde Bump pre-commit from 2.7.1 to 2.8.1 (#2188)
Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 2.7.1 to 2.8.1.
- [Release notes](https://github.com/pre-commit/pre-commit/releases)
- [Changelog](https://github.com/pre-commit/pre-commit/blob/master/CHANGELOG.md)
- [Commits](https://github.com/pre-commit/pre-commit/compare/v2.7.1...v2.8.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-29 10:11:39 +01:00
dependabot[bot]
a0c99615aa Bump pytest from 6.1.1 to 6.1.2 (#2187)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 6.1.1 to 6.1.2.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/6.1.1...6.1.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-29 10:11:27 +01:00
dependabot[bot]
c66c806e6e Bump cchardet from 2.1.6 to 2.1.7 (#2182)
Bumps [cchardet](https://github.com/PyYoshi/cChardet) from 2.1.6 to 2.1.7.
- [Release notes](https://github.com/PyYoshi/cChardet/releases)
- [Changelog](https://github.com/PyYoshi/cChardet/blob/master/CHANGES.rst)
- [Commits](https://github.com/PyYoshi/cChardet/compare/2.1.6...2.1.7)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-28 09:43:37 +01:00
dependabot[bot]
a432d28ee3 Bump cryptography from 3.2 to 3.2.1 (#2181)
Bumps [cryptography](https://github.com/pyca/cryptography) from 3.2 to 3.2.1.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/3.2...3.2.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-28 09:43:17 +01:00
dependabot[bot]
742bc43500 Bump aiohttp from 3.7.1 to 3.7.2 (#2183)
Bumps [aiohttp](https://github.com/aio-libs/aiohttp) from 3.7.1 to 3.7.2.
- [Release notes](https://github.com/aio-libs/aiohttp/releases)
- [Changelog](https://github.com/aio-libs/aiohttp/blob/master/CHANGES.rst)
- [Commits](https://github.com/aio-libs/aiohttp/compare/v3.7.1...v3.7.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-28 09:42:51 +01:00
Joakim Sørensen
223e2f1df5 Fix missing await (#2180) 2020-10-27 15:10:57 +01:00
dependabot[bot]
ed9aea6219 Bump debugpy from 1.0.0 to 1.1.0 (#2178)
Bumps [debugpy](https://github.com/microsoft/debugpy) from 1.0.0 to 1.1.0.
- [Release notes](https://github.com/microsoft/debugpy/releases)
- [Commits](https://github.com/microsoft/debugpy/compare/v1.0.0...v1.1.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-27 11:30:24 +01:00
Joakim Sørensen
aa7b68d4d5 Fix missing await (#2177)
* Fix missing await

* One more
2020-10-26 21:14:42 +01:00
Pascal Vizeli
8e57cd2751 Remove uvloop (#2176) 2020-10-26 11:45:12 +01:00
dependabot[bot]
64229a188e Bump aiohttp from 3.6.3 to 3.7.1 (#2175)
* Bump aiohttp from 3.6.3 to 3.7.1

Bumps [aiohttp](https://github.com/aio-libs/aiohttp) from 3.6.3 to 3.7.1.
- [Release notes](https://github.com/aio-libs/aiohttp/releases)
- [Changelog](https://github.com/aio-libs/aiohttp/blob/master/CHANGES.rst)
- [Commits](https://github.com/aio-libs/aiohttp/compare/v3.6.3...v3.7.1)

Signed-off-by: dependabot[bot] <support@github.com>

* remove yarl pining

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-10-26 10:35:46 +01:00
dependabot[bot]
10cbbcc2de Bump gitpython from 3.1.10 to 3.1.11 (#2173)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.1.10 to 3.1.11.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.1.10...3.1.11)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-26 10:19:36 +01:00
dependabot[bot]
5318e4fbcd Bump cryptography from 3.1 to 3.2 (#2174)
Bumps [cryptography](https://github.com/pyca/cryptography) from 3.1 to 3.2.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/3.1...3.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-26 10:19:28 +01:00
Joakim Sørensen
007251a04c Use matrix builds (#2172) 2020-10-25 13:08:17 +01:00
Joakim Sørensen
fd4b3ee539 Move from azure pipelines to GitHub actions for build (#2170) 2020-10-24 13:57:51 +02:00
Pascal Vizeli
976ae96633 Revert dns restart logic (#2169) 2020-10-23 16:49:35 +02:00
Pascal Vizeli
042bdcdf37 Make startup more stable (#2167) 2020-10-23 16:48:03 +02:00
Pascal Vizeli
c423e9cf8e Fix plugin restart (#2166) 2020-10-23 14:57:42 +02:00
Joakim Sørensen
1f13d6aa91 Add build check to CI (#2165)
* Add build check to CI

* Use tag name
2020-10-23 14:30:41 +02:00
dependabot[bot]
78c09a0fa6 Bump pyupgrade from 2.7.2 to 2.7.3 (#2163)
Bumps [pyupgrade](https://github.com/asottile/pyupgrade) from 2.7.2 to 2.7.3.
- [Release notes](https://github.com/asottile/pyupgrade/releases)
- [Commits](https://github.com/asottile/pyupgrade/compare/v2.7.2...v2.7.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-23 10:12:21 +02:00
dependabot[bot]
e6d6f2ee8c Bump gitpython from 3.1.9 to 3.1.10 (#2164)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.1.9 to 3.1.10.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/commits)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-23 09:55:52 +02:00
Pascal Vizeli
2918ef6225 Update azure-pipelines-release.yml 2020-10-22 16:28:29 +02:00
Pascal Vizeli
35b626a1c5 Fix gvariant bytes array (#2162) 2020-10-22 15:56:32 +02:00
Pascal Vizeli
6f26536d97 update branch 2020-10-22 11:32:24 +00:00
Pascal Vizeli
01064564b4 Fix new version handling with Plugins (#2159) 2020-10-22 12:29:53 +02:00
Pascal Vizeli
0c6c6a6620 Update azure-pipelines-release.yml for Azure Pipelines 2020-10-21 20:55:16 +02:00
Joakim Sørensen
be166d533f Update frontend to c4ed7433 (#2157) 2020-10-21 20:52:02 +02:00
Pascal Vizeli
d3e5535221 Update azure-pipelines-release.yml 2020-10-21 20:32:40 +02:00
Pascal Vizeli
7206213cd8 Update azure-pipelines-release.yml 2020-10-21 17:27:11 +02:00
Pascal Vizeli
605782d707 Update azure-pipelines-release.yml for Azure Pipelines 2020-10-21 14:31:37 +02:00
Pascal Vizeli
2c387349c9 Update azure-pipelines-release.yml for Azure Pipelines 2020-10-21 14:20:46 +02:00
Pascal Vizeli
e9c9f98168 Update azure-pipelines-release.yml for Azure Pipelines 2020-10-21 14:14:04 +02:00
Pascal Vizeli
a98c7819b0 Fix version script 2020-10-21 12:02:43 +00:00
Pascal Vizeli
7c42c5758d Update azure-pipelines-release.yml for Azure Pipelines 2020-10-21 13:51:07 +02:00
Pascal Vizeli
c555146094 Update azure-pipelines-release.yml for Azure Pipelines 2020-10-21 13:48:09 +02:00
Pascal Vizeli
f48c9b5774 Update azure-pipelines-release.yml for Azure Pipelines 2020-10-21 13:45:40 +02:00
Pascal Vizeli
8d1732e5eb Update azure-pipelines-release.yml for Azure Pipelines 2020-10-21 13:42:19 +02:00
Pascal Vizeli
f2843db421 Streamline version handling (#2155)
* Streamline version handling

* guard detached add-on

* commit version

* fix version

* Update pipeline

* use su-version

* Handle core like before

* Fix dev

* Update supervisor/api/addons.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Cleanup

* Fix format

* fix import

* fix yml issue

* fix readme

* Update supervisor/api/addons.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Update frontend

* Address comments

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
Co-authored-by: Ludeeus <ludeeus@ludeeus.dev>
2020-10-21 13:40:38 +02:00
Joakim Sørensen
b513512551 Normalize CPU stats (#2154)
* Normalize CPU stats

* Change fixture to make it clearer

* guard for 0

* Update supervisor/docker/stats.py

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>

* Update stats.py

* Update stats.py

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-10-20 22:26:09 +02:00
Joakim Sørensen
1a59839b1b Correct typo in log message (#2156)
* Correct typo in log message

* More typos
2020-10-20 20:30:20 +02:00
Pascal Vizeli
45861617b9 Add test for network docker (#2153) 2020-10-20 10:52:16 +02:00
Pascal Vizeli
353544085e Show internal network settings (#2152) 2020-10-20 10:42:51 +02:00
Pascal Vizeli
144d3921f7 Support preinstalled landingpage (#2137) 2020-10-20 10:13:39 +02:00
dependabot[bot]
e44d22880e Bump sentry-sdk from 0.18.0 to 0.19.1 (#2150)
* Bump sentry-sdk from 0.18.0 to 0.19.1

Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.18.0 to 0.19.1.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.18.0...0.19.1)

Signed-off-by: dependabot[bot] <support@github.com>

* Disable auto enabling integrations for now

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-10-20 10:10:24 +02:00
Pascal Vizeli
c7692b43e8 Bump version 250 2020-10-19 16:46:11 +02:00
Pascal Vizeli
9c53caae80 Speedup HA core auth (#2144)
* Speedup HA core auth

* Add reset API call

* use delete

* Add complexe cache logic

* Allow manage api to handle auth reset/cache

* revert to only cache

* add tests

* ignore protected-access for this tests

* fix comment
2020-10-19 16:38:28 +02:00
Pascal Vizeli
7a1d85ca2b Fix old issues attach to Issues list (#2148) 2020-10-19 16:38:14 +02:00
Joakim Sørensen
e684223f32 Update frontend to eec4a91 (#2147) 2020-10-19 16:02:59 +02:00
Joakim Sørensen
9744f3354b Overwrite snapshot if slug allready exsist (#2146) 2020-10-19 13:57:58 +02:00
dependabot[bot]
c6e3787681 Bump codecov/codecov-action from v1.0.13 to v1.0.14 (#2143)
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from v1.0.13 to v1.0.14.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Commits](https://github.com/codecov/codecov-action/compare/v1.0.13...7d5dfa54903bd909319c580a00535b483d1efcf3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-19 10:14:26 +02:00
Pascal Vizeli
eab76a6d1d Bump version 249 2020-10-18 16:17:39 +02:00
Pascal Vizeli
6549a10935 Merge remote-tracking branch 'origin/master' into dev 2020-10-18 14:09:27 +00:00
Pascal Vizeli
530d40dbbd Bump cli min version to 2020.10.0 (#2140) 2020-10-18 15:41:58 +02:00
Joakim Sørensen
50f2d8e7d8 Update frontend to 713e057 (#2138) 2020-10-18 09:55:12 +02:00
Pascal Vizeli
7a9aac491e Use /info for resolution API (#2136) 2020-10-16 13:07:02 +02:00
Pascal Vizeli
7dcb609fd5 Add api access for resolution call (#2135) 2020-10-16 12:28:53 +02:00
Pascal Vizeli
d119e99001 Resolution: extend type and context (#2130)
* Resolution: extend type and context

* fix property

* add helper

* fix api

* fix tests

* Fix patch

* finish tests

* Update supervisor/resolution/const.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Update supervisor/resolution/const.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Fix type

* fix lint

* Update supervisor/api/resolution.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Update supervisor/resolution/__init__.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Update API & add more tests

* Update supervisor/api/resolution.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Update supervisor/resolution/__init__.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Update supervisor/resolution/__init__.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* fix black

* remove azure ci

* fix test

* fix tests

* fix tests

* fix tests p2

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2020-10-16 12:22:32 +02:00
Joakim Sørensen
fe0e41adec Log messages cleanup (#2129)
* Log cleanup

* More logs
2020-10-15 14:50:43 +02:00
dependabot[bot]
034393bd42 Bump actions/setup-python from v2.1.3 to v2.1.4 (#2128)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from v2.1.3 to v2.1.4.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](https://github.com/actions/setup-python/compare/v2.1.3...41b7212b1668f5de9d65e9c82aa777e6bbedb3a8)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-15 11:10:34 +02:00
Joakim Sørensen
02e72726a5 Add issues/suggestion to resolution center / start with diskspace (#2125)
Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-10-14 17:14:25 +02:00
dependabot[bot]
d599c3ad76 Bump debugpy from 1.0.0rc2 to 1.0.0 (#2126)
Bumps [debugpy](https://github.com/microsoft/debugpy) from 1.0.0rc2 to 1.0.0.
- [Release notes](https://github.com/microsoft/debugpy/releases)
- [Commits](https://github.com/microsoft/debugpy/compare/v1.0.0rc2...v1.0.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-14 10:11:31 +02:00
Pascal Vizeli
b00f7c44df Observer: rebuild container if the application don't response (#2121)
* Observer: rebuild container if the application don't response

* add network mask

* Fix version
2020-10-13 15:01:31 +02:00
Joakim Sørensen
028b170cff Add resolution manager and unsupported flags (#2124)
* Add unsupported reason flags

* Restore test_network.py

* Add Resolution manager object

* fix import
2020-10-13 12:54:17 +02:00
Pascal Vizeli
8da686fc34 Fix corrupt container on startup (#2122) 2020-10-13 11:02:54 +02:00
dependabot[bot]
3f6453aa89 Bump aiohttp from 3.6.2 to 3.6.3 (#2123)
Bumps [aiohttp](https://github.com/aio-libs/aiohttp) from 3.6.2 to 3.6.3.
- [Release notes](https://github.com/aio-libs/aiohttp/releases)
- [Changelog](https://github.com/aio-libs/aiohttp/blob/master/CHANGES.rst)
- [Commits](https://github.com/aio-libs/aiohttp/compare/v3.6.2...v3.6.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-13 10:27:34 +02:00
Pascal Vizeli
7967254673 CLI: remote latest tag, not needed anymore (#2120) 2020-10-12 21:56:19 +02:00
Pascal Vizeli
0f60fdd20b Make api soon available (#2119)
* Make api soon available

* add more tests
2020-10-12 15:56:29 +02:00
Joakim Sørensen
ccb8e5fe06 Add content-disposition header to snapshot download (#2116)
* Add content-disposition header to snapshot download

* compile it
2020-10-12 11:11:32 +02:00
dependabot[bot]
ba576d8748 Bump codecov from 2.1.9 to 2.1.10 (#2118)
Bumps [codecov](https://github.com/codecov/codecov-python) from 2.1.9 to 2.1.10.
- [Release notes](https://github.com/codecov/codecov-python/releases)
- [Changelog](https://github.com/codecov/codecov-python/blob/master/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-python/compare/v2.1.9...v2.1.10)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-12 09:20:10 +02:00
dependabot[bot]
edcd9ca6e6 Bump getsentry/action-release from v1.0.2 to v1.1 (#2117)
Bumps [getsentry/action-release](https://github.com/getsentry/action-release) from v1.0.2 to v1.1.
- [Release notes](https://github.com/getsentry/action-release/releases)
- [Commits](https://github.com/getsentry/action-release/compare/v1.0.2...770b4a8dfd940faf96cd27e2004fda20bcdad5ea)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-12 09:19:04 +02:00
Pascal Vizeli
ac4277cd7b Return default network connection (#2115) 2020-10-12 09:13:27 +02:00
Pascal Vizeli
4c525de5e2 Mark system without using NetworkManager as unsupported (#2114)
* Mark system without using NetworkManager as unsupported

* Use feature style

* fix code
2020-10-10 18:30:34 +02:00
Pascal Vizeli
cb751e0397 Rename snapshot remove like other API calls (#2113) 2020-10-10 15:08:13 +02:00
Pascal Vizeli
ac457c1c28 Add brotlipy for ingress / like core (#2112) 2020-10-10 12:58:37 +02:00
Joakim Sørensen
caa77b9337 Remove API docs (#2088) 2020-10-09 14:39:39 +02:00
dependabot[bot]
96d8785349 Bump colorlog from 4.2.1 to 4.4.0 (#2110)
Bumps [colorlog](https://github.com/borntyping/python-colorlog) from 4.2.1 to 4.4.0.
- [Release notes](https://github.com/borntyping/python-colorlog/releases)
- [Commits](https://github.com/borntyping/python-colorlog/compare/v4.2.1...v4.4.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-09 11:27:34 +02:00
Joakim Sørensen
e4f57d2269 Update frontend to 892843b (#2111) 2020-10-09 11:27:06 +02:00
Ludeeus
f946de1e46 Bump version to 248 2020-10-07 12:03:20 +00:00
Joakim Sørensen
d588987b8b Merge pull request #2107 from home-assistant/247patch 2020-10-07 13:56:02 +02:00
Joakim Sørensen
4925b5fa97 Pin yarl to 1.5.1 (#2106) 2020-10-07 11:43:15 +00:00
Ludeeus
aa3f6390d3 Bump version to 247 2020-10-07 11:43:00 +00:00
Joakim Sørensen
6ba413f452 Pin yarl to 1.5.1 (#2106) 2020-10-07 13:41:46 +02:00
Pascal Vizeli
10b6706e4a Make docker API more Consistency to exists (#2102)
Co-authored-by: Ludeeus <ludeeus@ludeeus.dev>
2020-10-06 16:02:22 +02:00
Joakim Sørensen
17559bfc8e Extract exception message from chain for API errors (#2100)
* Get message from excepiton chain

* cleanup
2020-10-06 15:53:58 +02:00
Joakim Sørensen
9dc2f43ffb Handle both cases of bind failures (#2099) 2020-10-06 11:28:09 +02:00
Joakim Sørensen
38db375fea Add docker/info API (#2095) 2020-10-06 11:26:56 +02:00
Joakim Sørensen
f35b6d0b00 Set permissions on JSON files (#2093)
* Set 600 premissions on json files

* Add test

* Fix local tar tests

* Fix tar test in action

* Use pytest fixture for tmp_path in tests

* remove not needed things
2020-10-05 15:14:09 +02:00
Pascal Vizeli
8d75583a07 Update manager role for access docker api endpoint (#2091) 2020-10-05 13:18:46 +02:00
Joakim Sørensen
361fc51477 Add pull request template (#2092) 2020-10-05 13:18:19 +02:00
Halász Dávid
f6019b4e68 Support for installing add-ons from password protected registries (#2038) 2020-10-05 12:19:25 +02:00
dependabot[bot]
998dd5387b Bump flake8 from 3.8.3 to 3.8.4 (#2089)
Bumps [flake8](https://gitlab.com/pycqa/flake8) from 3.8.3 to 3.8.4.
- [Release notes](https://gitlab.com/pycqa/flake8/tags)
- [Commits](https://gitlab.com/pycqa/flake8/compare/3.8.3...3.8.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-05 09:32:44 +02:00
dependabot[bot]
3b7776ca01 Bump pytest from 6.1.0 to 6.1.1 (#2090)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 6.1.0 to 6.1.1.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/6.1.0...6.1.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-05 09:31:48 +02:00
dependabot[bot]
5788d1dd32 Bump actions/upload-artifact from v2.1.4 to v2.2.0 (#2086)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from v2.1.4 to v2.2.0.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v2.1.4...27bce4eee761b5bc643f46a8dfb41b430c8d05f6)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-02 09:52:15 +02:00
dependabot[bot]
ff04d339f4 Bump gitpython from 3.1.8 to 3.1.9 (#2083)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.1.8 to 3.1.9.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/commits)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-01 08:57:07 +02:00
dependabot[bot]
e9d03c5c8e Bump actions/setup-python from v2.1.2 to v2.1.3 (#2082)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from v2.1.2 to v2.1.3.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](https://github.com/actions/setup-python/compare/v2.1.2...c181ffa198a1248f902bc2f7965d2f9a36c2d7f6)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-10-01 08:55:27 +02:00
dependabot[bot]
ab4b98470e Bump sentry-sdk from 0.17.8 to 0.18.0 (#2080)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.17.8 to 0.18.0.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.17.8...0.18.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-30 10:26:44 +02:00
Ludeeus
c4f0702595 Bump version to 247 2020-09-30 07:39:19 +00:00
Paulus Schoutsen
736c9cb2bd Merge pull request #2081 from home-assistant/dev 2020-09-30 09:37:02 +02:00
Joakim Sørensen
f24e8535d3 Update frontend to 9dabce1 (#2079) 2020-09-29 17:30:48 +02:00
dependabot[bot]
8e4f3e0526 Bump pytest from 6.0.2 to 6.1.0 (#2078)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 6.0.2 to 6.1.0.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/6.0.2...6.1.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-28 09:18:44 +02:00
Joakim Sørensen
a9abd933b5 Use multipart for snapshot uploads (#2076)
* Use multipart for snapshot uploads

* Wrap I/O and run in executor

* revert 7f26b43

* remove cleanup
2020-09-24 13:09:53 +02:00
dependabot[bot]
f1121fe66f Bump sentry-sdk from 0.17.7 to 0.17.8 (#2077)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.17.7 to 0.17.8.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.17.7...0.17.8)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-24 10:43:38 +02:00
dependabot[bot]
c26a2e399c Bump sentry-sdk from 0.17.6 to 0.17.7 (#2075)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.17.6 to 0.17.7.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.17.6...0.17.7)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-23 14:26:34 +02:00
Joakim Sørensen
1af90721cc Addon repositories (#2071)
* stash

* Add test

* Use executor

* Make remove a coroutine

* Change logging and return
2020-09-22 23:40:36 +02:00
Joakim Sørensen
9274a0fa17 Add uuid to update payload (#2070)
* Add uuid to update payload

* Add it to test
2020-09-22 23:38:04 +02:00
dependabot[bot]
9443032c2a Bump voluptuous from 0.11.7 to 0.12.0 (#2073)
Bumps [voluptuous](https://github.com/alecthomas/voluptuous) from 0.11.7 to 0.12.0.
- [Release notes](https://github.com/alecthomas/voluptuous/releases)
- [Changelog](https://github.com/alecthomas/voluptuous/blob/master/CHANGELOG.md)
- [Commits](https://github.com/alecthomas/voluptuous/commits/v0.12.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-22 23:36:42 +02:00
Iulian Onofrei
8deb1cf2e6 Fix typo in logger method name (#2069) 2020-09-19 03:11:52 +02:00
Pascal Vizeli
13c7ce6a0a Merge branch 'dev' of https://github.com/home-assistant/supervisor into dev 2020-09-17 10:33:06 +00:00
Pascal Vizeli
0f54824cdb add one test more 2020-09-17 10:32:41 +00:00
Pascal Vizeli
10cd722806 Bump version to 246 2020-09-17 12:12:32 +02:00
Pascal Vizeli
4aca056c5b Merge pull request #2065 from home-assistant/dev
Release 245
2020-09-17 12:11:51 +02:00
Pascal Vizeli
15a8f40f6f add more test 2020-09-17 10:07:05 +00:00
Pascal Vizeli
2ca2701f7a Fix 'CommentedSeq' object has no attribute 'items' (#2064) 2020-09-17 12:02:40 +02:00
Pascal Vizeli
78f63380f2 Handle exception chain on addon boot (#2063)
* Handle exception chain on addon boot

* fix import

* Add tests
2020-09-17 12:01:48 +02:00
Pascal Vizeli
7633d26806 Fix boot loop with OS 4.10 (#2062) 2020-09-17 11:29:33 +02:00
Joakim Sørensen
15cae6562f Update frontend to b7d7ca4 (#2061) 2020-09-17 11:01:50 +02:00
dependabot[bot]
c3546eb566 Bump sentry-sdk from 0.17.5 to 0.17.6 (#2060)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.17.5 to 0.17.6.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.17.5...0.17.6)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-16 09:18:22 +02:00
Pascal Vizeli
2a77a29f48 Bump version to 245 2020-09-15 17:32:33 +02:00
Pascal Vizeli
77be115eec Merge pull request #2059 from home-assistant/dev
Release 244
2020-09-15 17:32:01 +02:00
Joakim Sørensen
64a6c2e07c Update panel to d6aba04 (#2058) 2020-09-15 15:58:01 +02:00
Pascal Vizeli
045a3ba416 Disable auto boot for add-ons with missconfig (#2057) 2020-09-15 14:54:18 +02:00
Pascal Vizeli
4da2715d14 Add observer version to sentry (#2054) 2020-09-15 10:46:58 +02:00
dependabot[bot]
2f0e99d420 Bump sentry-sdk from 0.17.4 to 0.17.5 (#2056)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.17.4 to 0.17.5.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.17.4...0.17.5)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-15 08:48:35 +02:00
dependabot[bot]
8694eaaf1a Bump getsentry/action-release from v1.0.1 to v1.0.2 (#2055)
Bumps [getsentry/action-release](https://github.com/getsentry/action-release) from v1.0.1 to v1.0.2.
- [Release notes](https://github.com/getsentry/action-release/releases)
- [Commits](https://github.com/getsentry/action-release/compare/v1.0.1...61b2cc1defeb409c001886994e3944a03ef8935d)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-15 08:47:58 +02:00
Martin Hjelmare
0761885ebb Clean api doc (#1782)
* Clean supervisor

* Indent snapshot

* Clean host

* Indent host services

* Indent HassOS

* Clean hardware

* Clean home assistant

* Clean add-ons

* Clean ingress

* Clean discovery

* Clean services

* Clean mqtt

* Clean mysql

* Clean misc

* Clean dns

* Clean cli

* Clean observer

* Clean multicast

* Clean audio

* Clean auth
2020-09-14 17:04:15 +02:00
Pascal Vizeli
ca60a69b22 Add timeout handling to gdbus (#2053)
* Add timeout handling to gdbus

* fix bus name

* make it silent

* fix tests

* add more wraper
2020-09-14 14:22:38 +02:00
Joakim Sørensen
c9db42583b Capture typeerror exception (#2052) 2020-09-14 13:40:11 +02:00
dependabot[bot]
052a691a4d Bump coverage from 5.2.1 to 5.3 (#2050)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-14 10:46:59 +02:00
dependabot[bot]
2bcb0e5195 Bump pytest from 6.0.1 to 6.0.2 (#2049)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-14 10:46:10 +02:00
Pascal Vizeli
745845db19 Allow manager add-on access to observer (#2046)
* Allow manager add-on access to observer

* fix order
2020-09-12 18:00:05 +02:00
Pascal Vizeli
de064d1d9c Bump version 244 2020-09-11 23:19:37 +02:00
Pascal Vizeli
3b2351af0b Merge pull request #2045 from home-assistant/dev
Release 243
2020-09-11 23:18:28 +02:00
Pascal Vizeli
5cf833e3d6 Expose more info (#2044) 2020-09-11 23:01:18 +02:00
Pascal Vizeli
409b53109b Observer access handling (#2043)
* Change access handling

* add security check
2020-09-11 23:01:01 +02:00
Pascal Vizeli
da83edf231 Handle exception on DNS for add-ons (#2042)
* Handle exception on DNS for add-ons

* fix logger

* capture exception
2020-09-11 19:35:04 +02:00
Pascal Vizeli
7be508214a gvariant: parse byte string (#2041)
* Parse byte string

* fix lint
2020-09-11 18:36:19 +02:00
Pascal Vizeli
8b4a137252 Observer plugin (#2037)
* Observer plugin

* fix error handling

* remove stop function

* fix restart policy

* Add observer watchdog

* Add observer

* Update supervisor/plugins/observer.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* Expose port 4357

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2020-09-11 16:05:57 +02:00
Pascal Vizeli
4565b01eeb Only support IPv4 for DNS (#2040) 2020-09-10 23:51:31 +02:00
Franck Nijhof
0675f66ee6 Add support for media folder (#2034) 2020-09-10 11:03:35 +02:00
dependabot[bot]
b60d57c3a0 Bump sentry-sdk from 0.17.3 to 0.17.4 (#2036)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.17.3 to 0.17.4.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.17.3...0.17.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-10 08:10:27 +02:00
Pascal Vizeli
0e3d95cac0 Make docker cleanup more robust for overlayfs issues (#2033)
* Make docker cleanup more robust for overlayfs issues

* it's an issue

* more decent handling
2020-09-09 16:25:18 +02:00
Pascal Vizeli
548737a559 Bump version 243 2020-09-08 14:09:02 +02:00
Pascal Vizeli
598108d294 Merge pull request #2032 from home-assistant/dev
Release 242
2020-09-08 14:07:19 +02:00
Pascal Vizeli
a0261dbbcc Make sure we use localhost for watchdog (#2031) 2020-09-08 13:50:33 +02:00
Joakim Sørensen
2418122b46 Fixes issue with starting core after restore (#2030) 2020-09-08 13:44:20 +02:00
Pascal Vizeli
f104e60afa Bump version 242 2020-09-08 11:11:20 +02:00
Pascal Vizeli
ed45f27f3e Merge pull request #2029 from home-assistant/dev
Release 241
2020-09-08 10:41:23 +02:00
Pascal Vizeli
40aa5c9caf Write core state to /run/supervisor & monitor (#2027)
* Write core state to /run/supervisor & monitor

* Add watchdog

* Add log if they getting started

* fix stale comment

* Fix script

* avoid output

* fix tests

* fix lint

* Update rootfs/etc/services.d/watchdog/run

Co-authored-by: Franck Nijhof <git@frenck.dev>

Co-authored-by: Franck Nijhof <git@frenck.dev>
2020-09-08 10:09:41 +02:00
Joakim Sørensen
14b1ea4eb0 Update panel to 0c7c536 (#2026) 2020-09-07 20:29:33 +02:00
Pascal Vizeli
5052a339e3 Cleanup shutdown (#2025) 2020-09-07 18:45:22 +02:00
Pascal Vizeli
2321890dde Full support of bytes arrays on gvariant (#2024)
* Full support of bytes arrays on gvariant

* Fix overlay ssid

* cleanup ssid

* fix test
2020-09-07 16:34:20 +02:00
Pascal Vizeli
4cb5770ee0 Add repr for add-ons (#2023) 2020-09-07 16:11:46 +02:00
Pascal Vizeli
3a35561d1d Change shutdown/close handling to prevent abort (#2022)
* Change shutdown/close handling to prevent abort

* add coresys

* Ignore shutdown

* add comment back

* migrate supervisor update
2020-09-07 14:25:38 +02:00
Pascal Vizeli
6fbec53f8a Better fix for OS error on repository reading (#2021) 2020-09-07 11:50:53 +02:00
dependabot[bot]
c707934018 Bump attrs from 20.1.0 to 20.2.0 (#2020)
Bumps [attrs](https://github.com/python-attrs/attrs) from 20.1.0 to 20.2.0.
- [Release notes](https://github.com/python-attrs/attrs/releases)
- [Changelog](https://github.com/python-attrs/attrs/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/python-attrs/attrs/compare/20.1.0...20.2.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-07 09:44:56 +02:00
Pascal Vizeli
efd8efa248 Bump version 241 2020-09-05 13:12:06 +02:00
Pascal Vizeli
979861b764 Merge pull request #2018 from home-assistant/dev
Release 240
2020-09-05 13:11:36 +02:00
Pascal Vizeli
cdc53a159c make it more robust (#2017)
* make it more robust

* mark as unhealth
2020-09-05 13:06:26 +02:00
Pascal Vizeli
a203ed9cc5 Improve error reporting 2020-09-05 10:38:07 +00:00
Pascal Vizeli
5cab5f0c08 Fix error while add-on DNS sync (#2016) 2020-09-04 20:58:58 +02:00
Joakim Sørensen
25ea80e169 Fixes issues with managing wireless interfaces (#2015)
* Fixes issues with managing wireless interfaces

* Add test

* Add back fixture
2020-09-04 20:58:37 +02:00
Pascal Vizeli
f43b4e9e24 Bump version 240 2020-09-04 16:28:44 +02:00
Pascal Vizeli
160fbb2589 Merge pull request #2014 from home-assistant/dev
Release 239
2020-09-04 16:27:15 +02:00
Pascal Vizeli
c85aa664e1 Use packages version (#2013)
* Use package version

* more readable

* Fix
2020-09-04 16:20:07 +02:00
Joakim Sørensen
51dcbf5db7 Update panel to faee2c3 (#2012) 2020-09-04 16:00:21 +02:00
Pascal Vizeli
fa114a4a03 Update plugin required (#2011) 2020-09-04 14:37:18 +02:00
dependabot[bot]
d7fd58bdb9 Bump gitpython from 3.1.7 to 3.1.8 (#2010)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-04 09:09:58 +02:00
Pascal Vizeli
38b0aea8e2 Update manage role for network access (#2008) 2020-09-03 16:50:10 +02:00
Joakim Sørensen
41eade9325 Fix API.md for network/interface/ (#2009) 2020-09-03 16:49:59 +02:00
Joakim Sørensen
e64cf41aec Addon api changes (#2006)
* Add startup to addon info API

* Don't fail when validating, just return the problem as 200

* Add sugestions

* Review comments
2020-09-03 16:38:41 +02:00
Pascal Vizeli
02872b5e75 Prevent enable watchdog on startup once (#2005)
* Prevent enable watchdog on startup once

* Update supervisor/addons/addon.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

* fix black

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2020-09-03 16:36:45 +02:00
Joakim Sørensen
e4d49bb459 Remove annotations (#2007) 2020-09-03 16:36:09 +02:00
dependabot[bot]
d38b7d5a82 Bump sentry-sdk from 0.17.2 to 0.17.3 (#2003)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.17.2 to 0.17.3.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.17.2...0.17.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-03 09:16:17 +02:00
Joakim Sørensen
537c5d3197 Update frontend to c7f8fe1 (#2002) 2020-09-02 16:06:20 +02:00
dependabot[bot]
575df2fcf6 Bump sentry-sdk from 0.17.1 to 0.17.2 (#2001)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.17.1 to 0.17.2.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.17.1...0.17.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-02 08:36:10 +02:00
dependabot[bot]
c08c3c6b37 Bump sentry-sdk from 0.17.0 to 0.17.1 (#1999)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.17.0 to 0.17.1.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.17.0...0.17.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-31 10:03:32 +02:00
dependabot[bot]
2acf28609e Bump pydocstyle from 5.1.0 to 5.1.1 (#1998)
Bumps [pydocstyle](https://github.com/PyCQA/pydocstyle) from 5.1.0 to 5.1.1.
- [Release notes](https://github.com/PyCQA/pydocstyle/releases)
- [Changelog](https://github.com/PyCQA/pydocstyle/blob/master/docs/release_notes.rst)
- [Commits](https://github.com/PyCQA/pydocstyle/compare/5.1.0...5.1.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-31 09:45:51 +02:00
Pascal Vizeli
bb59d0431e fix dns server description 2020-08-30 21:59:47 +02:00
Joakim Sørensen
1c7b1f1462 Adds options_validate API (#1996) 2020-08-30 17:58:13 +02:00
Joakim Sørensen
f32d17d924 Format API error messages (#1997) 2020-08-30 17:53:10 +02:00
Pascal Vizeli
928a4d8dce Bump version 239 2020-08-29 15:12:38 +02:00
Pascal Vizeli
dd3ba93308 Merge pull request #1995 from home-assistant/dev
Release 238
2020-08-29 15:11:48 +02:00
Pascal Vizeli
7e1b179cdd Fix error handling unsupported (#1994)
* Try to catch unhealthy

* revert
2020-08-29 12:03:29 +02:00
Pascal Vizeli
a9a2c35f06 Sentry send env infos (#1992) 2020-08-29 11:44:08 +02:00
Pascal Vizeli
58b88a6919 Check if supervisor run priv (#1993) 2020-08-29 11:35:15 +02:00
Joakim Sørensen
f937876a1b Set parse issues as critical (#1989) 2020-08-29 10:56:45 +02:00
Pascal Vizeli
8193f43634 Fix secrets with add-on validation (#1990) 2020-08-29 10:54:16 +02:00
Pascal Vizeli
1d3f880f82 Bump version 238 2020-08-28 14:39:17 +02:00
Pascal Vizeli
ef2fa8d2e2 Merge pull request #1987 from home-assistant/dev
Release 237
2020-08-28 14:38:30 +02:00
Joakim Sørensen
51997b3e7c Update frontend to dc5b920 (#1986) 2020-08-28 14:31:19 +02:00
Joakim Sørensen
98785b00e2 Use jinja for payload generation (#1985) 2020-08-28 11:46:22 +02:00
Joakim Sørensen
8d3694884d Split payload so we can set auto without IP configuration (#1982)
* Guard for no interfaces

* Host reload on update

* Extract payload

* Check eth and wifi interfaces with a valid ip4 config

* Add tests

* Fix tests

* Move to enum
2020-08-28 10:40:50 +02:00
Pascal Vizeli
a2821a98ad Fix gvar for dbus if binary is not a string (#1984) 2020-08-27 17:04:14 +02:00
Pascal Vizeli
8d552ae15c Fix api proxy ensure_access_token for websocket (#1983) 2020-08-27 16:59:03 +02:00
Pascal Vizeli
6db4c60f47 Fix byte parser (#1981) 2020-08-27 14:31:34 +02:00
Pascal Vizeli
805c0385a0 Bump version 237 2020-08-27 11:52:32 +02:00
Pascal Vizeli
cea6e7a9f2 Merge pull request #1979 from home-assistant/dev
Release 236
2020-08-27 10:52:18 +02:00
Pascal Vizeli
127073c01b Small cleanup & adjustments for 236 (#1978) 2020-08-27 10:33:35 +02:00
dependabot[bot]
30fe36ae05 Bump cryptography from 3.0 to 3.1 (#1977)
Bumps [cryptography](https://github.com/pyca/cryptography) from 3.0 to 3.1.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/3.0...3.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-27 10:18:24 +02:00
Pascal Vizeli
58bd677832 fix ensure_access_token 2020-08-26 21:16:38 +00:00
Pascal Vizeli
1a3b369dd7 Update black 20.8b1 (#1976) 2020-08-26 23:01:29 +02:00
Pascal Vizeli
6e38216abd Adjust add-on state (#1975)
* Adjust add-on state

* schedule refresh addon
2020-08-26 22:52:41 +02:00
Pascal Vizeli
efcfc1f841 Watchdog for Add-ons (#1970)
* Watchdog for Add-ons

* Run task

* Extend appliaction watchdog

* fix spell

* Add running tasks

* Add tests

* Fix states

* Update supervisor/misc/tasks.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update tests/test_validate.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Adjust timeout

* change timeout

* Modify tasker

* slots the task object

* fix typing

* Add tests

* fix lint

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-08-26 22:20:35 +02:00
Joakim Sørensen
8dea50ce83 Update frontend to c1a4b27 (#1974) 2020-08-26 18:24:22 +02:00
Joakim Sørensen
7a5a01bdcc Add network to host suppported features (#1973) 2020-08-26 14:11:21 +02:00
Joakim Sørensen
bd1450a682 Update frontend to 04df6c3 (#1972) 2020-08-26 09:42:34 +02:00
dependabot[bot]
c538c1ce7f Bump getsentry/action-release from v1.0.0 to v1.0.1 (#1971)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-26 08:37:45 +02:00
Pascal Vizeli
b6d59c4f64 Fix long waiting time on first boot (#1968) 2020-08-25 10:37:11 +02:00
dependabot[bot]
a758ccaf5c Bump sentry-sdk from 0.16.5 to 0.17.0 (#1966)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.16.5 to 0.17.0.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.16.5...0.17.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-25 09:41:56 +02:00
Joakim Sørensen
e8b04cc20a Update frontend to 6599351 (#1965) 2020-08-24 22:51:40 +02:00
Joakim Sørensen
9bcb15dbc0 MVP: Add Network Manager context (#1937)
Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-08-24 16:58:02 +02:00
Pascal Vizeli
1e953167b6 Update stale.yml 2020-08-24 13:44:34 +02:00
dependabot[bot]
979586cdb2 Bump pylint from 2.5.3 to 2.6.0 (#1962)
* Bump pylint from 2.5.3 to 2.6.0

Bumps [pylint](https://github.com/PyCQA/pylint) from 2.5.3 to 2.6.0.
- [Release notes](https://github.com/PyCQA/pylint/releases)
- [Changelog](https://github.com/PyCQA/pylint/blob/master/ChangeLog)
- [Commits](https://github.com/PyCQA/pylint/compare/pylint-2.5.3...pylint-2.6.0)

Signed-off-by: dependabot[bot] <support@github.com>

* Address lint issues

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-08-24 10:16:50 +02:00
dependabot[bot]
cd31fad56d Bump pre-commit from 2.6.0 to 2.7.1 (#1961)
Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 2.6.0 to 2.7.1.
- [Release notes](https://github.com/pre-commit/pre-commit/releases)
- [Changelog](https://github.com/pre-commit/pre-commit/blob/master/CHANGELOG.md)
- [Commits](https://github.com/pre-commit/pre-commit/compare/v2.6.0...v2.7.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-24 10:10:33 +02:00
dependabot[bot]
ff57d88e2a Bump codecov from 2.1.8 to 2.1.9 (#1963)
Bumps [codecov](https://github.com/codecov/codecov-python) from 2.1.8 to 2.1.9.
- [Release notes](https://github.com/codecov/codecov-python/releases)
- [Changelog](https://github.com/codecov/codecov-python/blob/master/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-python/compare/2.1.8...v2.1.9)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-24 09:18:14 +02:00
dependabot[bot]
06cb5e171e Bump pydocstyle from 5.0.2 to 5.1.0 (#1959)
Bumps [pydocstyle](https://github.com/PyCQA/pydocstyle) from 5.0.2 to 5.1.0.
- [Release notes](https://github.com/PyCQA/pydocstyle/releases)
- [Changelog](https://github.com/PyCQA/pydocstyle/blob/master/docs/release_notes.rst)
- [Commits](https://github.com/PyCQA/pydocstyle/compare/5.0.2...5.1.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-24 09:16:54 +02:00
dependabot[bot]
a8b70a2e13 Bump docker from 4.3.0 to 4.3.1 (#1960)
Bumps [docker](https://github.com/docker/docker-py) from 4.3.0 to 4.3.1.
- [Release notes](https://github.com/docker/docker-py/releases)
- [Commits](https://github.com/docker/docker-py/compare/4.3.0...4.3.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-24 09:16:35 +02:00
dependabot[bot]
948019ccee Bump debugpy from 1.0.0rc1 to 1.0.0rc2 (#1953)
Bumps [debugpy](https://github.com/microsoft/debugpy) from 1.0.0rc1 to 1.0.0rc2.
- [Release notes](https://github.com/microsoft/debugpy/releases)
- [Commits](https://github.com/microsoft/debugpy/compare/v1.0.0rc1...v1.0.0rc2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-21 09:01:55 +02:00
dependabot[bot]
89ed109505 Bump attrs from 19.3.0 to 20.1.0 (#1954)
Bumps [attrs](https://github.com/python-attrs/attrs) from 19.3.0 to 20.1.0.
- [Release notes](https://github.com/python-attrs/attrs/releases)
- [Changelog](https://github.com/python-attrs/attrs/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/python-attrs/attrs/compare/19.3.0...20.1.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-21 09:01:22 +02:00
Pascal Vizeli
fae246c503 Fix setup module list (#1952)
* Fix setup module list

* Update setup.py

* Update setup.py
2020-08-20 11:35:05 +02:00
Pascal Vizeli
2411b4287d Group all homeassistant/core into a module (#1950)
* Group all homeassistant/core into a module

* fix references

* fix lint

* streamline object property protection

* Fix api
2020-08-20 11:22:04 +02:00
Pascal Vizeli
b3308ecbe0 Fix timeout and reflect s6-overlay (#1947) 2020-08-19 16:46:39 +02:00
Pascal Vizeli
3541cbff5e Remove old dns forwarder (#1945) 2020-08-18 21:40:52 +02:00
Pascal Vizeli
838ba7ff36 Bump version 236 2020-08-18 15:21:25 +02:00
Pascal Vizeli
e9802f92c9 Merge pull request #1944 from home-assistant/dev
Release 235
2020-08-18 15:20:40 +02:00
Pascal Vizeli
016fd24859 Fix hardware serial list check (#1943) 2020-08-18 15:03:30 +02:00
Pascal Vizeli
d315e81ab2 Extend hardware/udev support & usb mapping (#1940)
* Extend hardware/udev support & usb mapping

* Cleanup list

* new style

* Fix tests

* Fix

* use frozen

* add test for usb

* Fix block disks

* Update API.md

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2020-08-18 14:25:07 +02:00
dependabot[bot]
97c38b8534 Bump codecov/codecov-action from v1.0.12 to v1.0.13 (#1942)
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from v1.0.12 to v1.0.13.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Commits](https://github.com/codecov/codecov-action/compare/v1.0.12...6004246f47ab62d32be025ce173b241cd84ac58e)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-18 08:08:09 +02:00
Pascal Vizeli
011e2b3df5 Simplify OS check (#1939) 2020-08-17 16:57:29 +02:00
Pascal Vizeli
e3ee9a299f Send exception why the update fails (#1938) 2020-08-17 15:37:19 +02:00
Pascal Vizeli
d73c10f874 Don't break startup with corrupt docker filesystem (#1936) 2020-08-17 10:44:40 +02:00
dependabot[bot]
9e448b46ba Bump pytest-cov from 2.10.0 to 2.10.1 (#1935)
Bumps [pytest-cov](https://github.com/pytest-dev/pytest-cov) from 2.10.0 to 2.10.1.
- [Release notes](https://github.com/pytest-dev/pytest-cov/releases)
- [Changelog](https://github.com/pytest-dev/pytest-cov/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest-cov/compare/v2.10.0...v2.10.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-17 09:13:36 +02:00
dependabot[bot]
9f09c46789 Bump sentry-sdk from 0.16.4 to 0.16.5 (#1934)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.16.4 to 0.16.5.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.16.4...0.16.5)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-17 09:13:12 +02:00
Pascal Vizeli
fe6634551a Catch requests with docker exceptions (#1926) 2020-08-15 23:01:10 +02:00
Joakim Sørensen
22a7931a7c Update log message for unsupported OS (#1929) 2020-08-15 22:57:38 +02:00
Pascal Vizeli
94f112512f Machine ID for user/sentry & cleanups (#1928)
* Machine ID for user/sentry & cleanups

* Add tests / fix users
2020-08-15 18:26:20 +02:00
Joakim Sørensen
b6509dca1f Split extra info and add more metrics (#1927)
* Split extra

* Restructure and add info

* adjust test

* Move docker version

* Add name and repository for addons

* Test supervisor version

* Use context instead of extra

* adjust test
2020-08-15 16:26:01 +02:00
Franck Nijhof
620234e708 Add Sentry release GitHub Action workflow (#1925) 2020-08-15 10:26:15 +02:00
Pascal Vizeli
d50e866cec Bump version 235 2020-08-14 23:39:49 +02:00
Pascal Vizeli
76ad6dca02 Merge pull request #1924 from home-assistant/dev
Release 234
2020-08-14 23:38:50 +02:00
Pascal Vizeli
cdb1520a63 Fix shutdown process (#1923) 2020-08-14 23:36:07 +02:00
Pascal Vizeli
bbef706a33 Make exeption more useful (#1922) 2020-08-14 23:12:54 +02:00
Pascal Vizeli
835509901f Fix core proy TypeError (#1921) 2020-08-14 22:51:33 +02:00
Joakim Sørensen
b51f9586c4 Fix attribute in sentry data_filter (#1920) 2020-08-14 19:29:10 +02:00
Pascal Vizeli
fc83cb9559 Use lambda for less function stack frames (#1918) 2020-08-14 19:28:38 +02:00
Joakim Sørensen
f5f5f829ac Add test for denylist (#1914)
* Add test for denylist

* Mock API in conftest
2020-08-14 18:09:03 +02:00
Martin Hjelmare
930eed4500 Fix ingress unbound local errors (#1915) 2020-08-14 15:20:36 +02:00
Pascal Vizeli
01a8b58054 Bump version to 234 2020-08-14 14:12:52 +02:00
Pascal Vizeli
eba1d01fc2 Merge pull request #1913 from home-assistant/dev
Release 233
2020-08-14 14:12:11 +02:00
Joakim Sørensen
84755836c9 Filter AddonConfigurationError from sentry (#1912) 2020-08-14 14:06:46 +02:00
Joakim Sørensen
c9585033cb Sanitize event (#1908)
* Sanitise event

* No need to remove supervisor token

* cleanup

* Typo

* Review comments

* Move and test

* Move and use hdr
2020-08-14 13:40:14 +02:00
Joakim Sørensen
2d312c276f Adds image denylist (#1896)
* Adds image denylist

* Move to DockerAPI

* Wording

* Use error instead of critical

* Update supervisor/docker/__init__.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Run in executor

* Add pyouroboros/ouroboros

* Mark as unsupported

* Use set

* Update supervisor/docker/__init__.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Remove duplicate

* Change logging

* Update supervisor/docker/__init__.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Set healthy to False

* small move

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-08-14 09:45:22 +02:00
Joakim Sørensen
3b0d0e9928 Add disk total, used, free to host/info API (#1909) 2020-08-14 09:24:38 +02:00
dependabot[bot]
8307b153e3 Bump sentry-sdk from 0.16.3 to 0.16.4 (#1910)
Bumps [sentry-sdk](https://github.com/getsentry/sentry-python) from 0.16.3 to 0.16.4.
- [Release notes](https://github.com/getsentry/sentry-python/releases)
- [Changelog](https://github.com/getsentry/sentry-python/blob/master/CHANGES.md)
- [Commits](https://github.com/getsentry/sentry-python/compare/0.16.3...0.16.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-14 09:11:09 +02:00
Pascal Vizeli
dfaffe3ec5 Self fix corrupt docker network (#1907) 2020-08-13 17:50:39 +02:00
Pascal Vizeli
8d7b15cbeb Improve supported / healthy handling and more checks (#1905)
Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2020-08-13 16:49:34 +02:00
Joakim Sørensen
00969a67ac Set not supported with wrong docker configuration (#1904)
* set not supported with wrong docker configuration

* Set not supported if no access to udev monitor

* Move flag
2020-08-13 10:44:45 +02:00
Pascal Vizeli
a374d4e817 Make sure we only run ingress with installed add-ons (#1903)
* Make sure we only run ingress with installed add-ons

* Make sure we reload tokens after uninstall

* Optimize token handling

* Fix error
2020-08-13 10:43:36 +02:00
Pascal Vizeli
f5dda39f63 Disable sentry dev (#1902)
* Disable sentry on dev env

* Offload env
2020-08-13 09:39:26 +02:00
Pascal Vizeli
fb5d54d5fe Bump version 233 2020-08-12 18:44:34 +02:00
Pascal Vizeli
d392b35fdd Merge pull request #1901 from home-assistant/dev
Release 232
2020-08-12 18:44:04 +02:00
Pascal Vizeli
3ceec006ac Fix isort 2020-08-12 14:47:09 +00:00
Pascal Vizeli
62a574c6bd Merge branch 'master' into dev 2020-08-12 16:43:18 +02:00
Pascal Vizeli
821c10b2bd Fix connection reset error on ingress (#1899) 2020-08-12 16:11:22 +02:00
Joakim Sørensen
fa3269a098 Update panel to 77b25f5 (#1900) 2020-08-12 15:55:57 +02:00
Pascal Vizeli
a9bdab4b49 Fix validation issue addon options (#1898)
* Fix validation issue addon options

* Add some basic tests

* Update supervisor/addons/validate.py

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2020-08-12 14:49:46 +02:00
Pascal Vizeli
0df5b7d87b Mark installation as unsupported dev on stable (#1897) 2020-08-12 13:43:15 +02:00
dependabot[bot]
4861fc70ce Bump debugpy from 1.0.0b12 to 1.0.0rc1 (#1894)
Bumps [debugpy](https://github.com/microsoft/debugpy) from 1.0.0b12 to 1.0.0rc1.
- [Release notes](https://github.com/microsoft/debugpy/releases)
- [Commits](https://github.com/microsoft/debugpy/compare/1.0.0b12...v1.0.0rc1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-12 12:32:16 +02:00
dependabot[bot]
47c443bb92 Bump actions/upload-artifact from v2.1.3 to v2.1.4 (#1892)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from v2.1.3 to v2.1.4.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v2.1.3...58740802ef971a2d71eff71e63d48ab68d1f5507)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-12 08:31:17 +02:00
dependabot[bot]
9cb4b49597 Bump actions/setup-python from v2.1.1 to v2.1.2 (#1893)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from v2.1.1 to v2.1.2.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](https://github.com/actions/setup-python/compare/v2.1.1...24156c231c5e9d581bde27d0cdbb72715060ea51)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-12 08:30:54 +02:00
Pascal Vizeli
865523fd37 cleanup sentry filter 2020-08-11 19:11:22 +00:00
Pascal Vizeli
1df35a6fe1 fix sentry 2020-08-11 17:42:55 +00:00
Pascal Vizeli
e70c9d8a30 Fix order for more details 2020-08-11 16:07:33 +00:00
Pascal Vizeli
7d6b00ea4a Fix dev outside stable channel (#1891)
* Fix dev outside stable channel

* more friendly

* downgrade logger for sentry

* Show critical on the end
2020-08-11 18:02:25 +02:00
Pascal Vizeli
e5fc985915 Fix sentry message with unsupported (#1890)
* Fix sentry message with unsupported

* filter breadcrumb

* Support add-on errors

* Fix level

* Add logging info
2020-08-11 16:48:58 +02:00
Pascal Vizeli
71ccaa2bd0 Add healthy and supported to API (#1889)
* Add healthy and supported to API

* fix protected attributes
2020-08-11 16:00:51 +02:00
Pascal Vizeli
e127f23a08 Bump version 231 2020-08-11 09:07:29 +00:00
Pascal Vizeli
495f9f2373 Bump version to 232 2020-08-11 11:06:57 +02:00
dependabot[bot]
27274286db Bump docker from 4.2.2 to 4.3.0 (#1886)
Bumps [docker](https://github.com/docker/docker-py) from 4.2.2 to 4.3.0.
- [Release notes](https://github.com/docker/docker-py/releases)
- [Commits](https://github.com/docker/docker-py/compare/4.2.2...4.3.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-11 10:58:46 +02:00
Pascal Vizeli
85ba886029 Bump version 231 2020-08-11 10:57:07 +02:00
Pascal Vizeli
2f3a868e42 Merge pull request #1888 from home-assistant/dev
Release 231
2020-08-11 10:56:01 +02:00
Pascal Vizeli
a51b80f456 Tag installation type & more infos (#1887)
* Tag installation type & more infos

* fix black

* Make sure dbus is available for reports

* HassOS warning -> info

* Fix installation type name

* fix correct ADR

* change name

* make message more friendly
2020-08-11 10:52:33 +02:00
Greg Rapp
f27a426879 Allow all addons to access /host/info endpoint (#1885) 2020-08-10 23:45:05 +02:00
Pascal Vizeli
19ca485c28 Allow Core access to dbus for bluetooth (#1883) 2020-08-10 15:18:32 +02:00
Pascal Vizeli
7deed55c2d Make plugin more robust (#1881) 2020-08-10 13:23:50 +02:00
Joakim Sørensen
4c5c6f072c Updates panel to dec1f99 (#1880) 2020-08-10 10:52:41 +02:00
Pascal Vizeli
f174e08ad6 Merge pull request #1879 from home-assistant/dev
Release 230
2020-08-07 22:25:21 +02:00
Pascal Vizeli
2658f95347 Fix sentry logging (#1878)
* Fix sentry logging

* fix level
2020-08-07 22:16:07 +02:00
Pascal Vizeli
311c981d1a Small cleanup to be more robust (#1876) 2020-08-07 21:43:03 +02:00
Pascal Vizeli
d6d3bf0583 Make udev more robust (#1875) 2020-08-07 14:03:55 +02:00
Joakim Sørensen
a1a601a4d3 Update panel to c17ebfd (#1874) 2020-08-07 08:18:41 +02:00
Pascal Vizeli
14776eae76 Fix issues with dev version (#1873) 2020-08-05 18:19:57 +02:00
Pascal Vizeli
bef4034ab8 Replace debuger with debugpy (#1872) 2020-08-05 15:24:53 +02:00
Pascal Vizeli
ad988f2a24 Add diagnostics support (#1870)
* Add diagnostics support

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* add aditional data

* Fix handling

* Better states

* Fix opt

* Update supervisor/bootstrap.py

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>

* Only events on supported systems

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2020-08-05 14:54:03 +02:00
dependabot[bot]
6599ae0ee0 Bump actions/upload-artifact from v2.1.2 to v2.1.3 (#1871)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from v2.1.2 to v2.1.3.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v2.1.2...268d7547644ab8a9d0c1163299e59a1f5d93f39b)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-05 11:33:29 +02:00
Martin Hjelmare
4f1ed690cd Add free disk space log on docker install error (#1868)
* Add free disk space info

* Log available space on docker image install error

* Add unit to log message

* Add 404 check and better log message

* Set default path to supervisor data path

* Clean up attribute access

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>

* Move free space helper to hardware

* Add hardware test

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-08-03 15:00:07 +02:00
Joakim Sørensen
4ffaee6013 Make a copy of the logfile before rollback (#1867)
* Make a copy of the logfile before rollback

* Review changes and add log about the log file
2020-08-03 14:28:54 +02:00
Joakim Sørensen
e1ce19547e Use "stale" instead of "wontfix" (#1864) 2020-08-03 11:01:36 +02:00
dependabot[bot]
039040b972 Bump actions/upload-artifact from v2.1.1 to v2.1.2 (#1863)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from v2.1.1 to v2.1.2.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v2.1.1...c8879bf5aef7bef66f9b82b197f34c4eeeb1731b)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-08-03 10:08:28 +02:00
dependabot[bot]
7a1af3d346 Bump pytest from 6.0.0 to 6.0.1 (#1862)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 6.0.0 to 6.0.1.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/6.0.0...6.0.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-31 08:14:12 +02:00
dependabot[bot]
1e98774b62 Bump pytest from 5.4.3 to 6.0.0 (#1861)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.4.3 to 6.0.0.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.4.3...6.0.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-29 20:46:02 +02:00
Pascal Vizeli
4b4d6c6866 Update LICENSE 2020-07-29 14:45:37 +02:00
dependabot[bot]
65ff83d359 Bump actions/upload-artifact from 2.1.0 to v2.1.1 (#1860)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 2.1.0 to v2.1.1.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/2.1.0...5f948bc1f0a251f88bb4c9b1c3dfa6cbd1327dc5)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-28 10:04:50 +02:00
Pascal Vizeli
e509c804ae Add missing debug information (#1859) 2020-07-27 15:37:26 +02:00
Pascal Vizeli
992827e225 use lowlevel file handling, avoid additional buffers (#1858)
* Small tarfile improvments

* use lowlevel file handling, avoid additional buffers

* Fix lowlevel closing

* fix cbc

* Fix name
2020-07-27 15:21:54 +02:00
dependabot[bot]
083e97add8 Bump coverage from 5.2 to 5.2.1 (#1857)
Bumps [coverage](https://github.com/nedbat/coveragepy) from 5.2 to 5.2.1.
- [Release notes](https://github.com/nedbat/coveragepy/releases)
- [Changelog](https://github.com/nedbat/coveragepy/blob/master/CHANGES.rst)
- [Commits](https://github.com/nedbat/coveragepy/compare/coverage-5.2...coverage-5.2.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-27 12:55:38 +02:00
dependabot[bot]
05378d18c0 Bump pyupgrade from 2.7.1 to 2.7.2 (#1856)
Bumps [pyupgrade](https://github.com/asottile/pyupgrade) from 2.7.1 to 2.7.2.
- [Release notes](https://github.com/asottile/pyupgrade/releases)
- [Commits](https://github.com/asottile/pyupgrade/compare/v2.7.1...v2.7.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-27 12:55:28 +02:00
dependabot[bot]
3dd465acc9 Bump colorlog from 4.1.0 to 4.2.1 (#1854)
Bumps [colorlog](https://github.com/borntyping/python-colorlog) from 4.1.0 to 4.2.1.
- [Release notes](https://github.com/borntyping/python-colorlog/releases)
- [Commits](https://github.com/borntyping/python-colorlog/compare/v4.1.0...v4.2.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-24 13:21:02 +02:00
Pascal Vizeli
8f6e36f781 Fix rollback timeout on new versions with early stage UI (#1852)
* Fix rollback timeout on new versions with early stage UI

* order code

* Add debug

* order code

* Update supervisor/homeassistant.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update supervisor/homeassistant.py

Co-authored-by: Joakim Sørensen <joasoe@gmail.com>

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Joakim Sørensen <joasoe@gmail.com>
2020-07-23 21:47:49 +02:00
dependabot[bot]
85fe56db57 Bump codecov/codecov-action from v1.0.11 to v1.0.12 (#1851)
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from v1.0.11 to v1.0.12.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Commits](https://github.com/codecov/codecov-action/compare/v1.0.11...07127fde53bc3ccd346d47ab2f14c390161ad108)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-23 13:17:59 +02:00
dependabot[bot]
8e07429e47 Bump actions/setup-python from v2 to v2.1.1 (#1848)
Bumps [actions/setup-python](https://github.com/actions/setup-python) from v2 to v2.1.1.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](https://github.com/actions/setup-python/compare/v2...0c28554988f6ccf1a4e2818e703679796e41a214)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-21 11:37:50 +02:00
dependabot[bot]
ced6d702b9 Bump cryptography from 2.9.2 to 3.0 (#1847)
Bumps [cryptography](https://github.com/pyca/cryptography) from 2.9.2 to 3.0.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/2.9.2...3.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-21 11:37:25 +02:00
dependabot[bot]
25d7de4dfa Bump codecov/codecov-action from v1.0.10 to v1.0.11 (#1844)
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from v1.0.10 to v1.0.11.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Commits](https://github.com/codecov/codecov-action/compare/v1.0.10...6d208f5b527841fb050f92f778e86cb808dacdcb)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-20 11:48:28 +02:00
dependabot[bot]
82754c0dfe Bump pyupgrade from 2.7.0 to 2.7.1 (#1840)
Bumps [pyupgrade](https://github.com/asottile/pyupgrade) from 2.7.0 to 2.7.1.
- [Release notes](https://github.com/asottile/pyupgrade/releases)
- [Commits](https://github.com/asottile/pyupgrade/compare/v2.7.0...v2.7.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-17 13:43:53 +02:00
dependabot[bot]
e604b022ee Bump aiohttp from 3.6.1 to 3.6.2 (#1831)
Bumps [aiohttp](https://github.com/aio-libs/aiohttp) from 3.6.1 to 3.6.2.
- [Release notes](https://github.com/aio-libs/aiohttp/releases)
- [Changelog](https://github.com/aio-libs/aiohttp/blob/master/CHANGES.rst)
- [Commits](https://github.com/aio-libs/aiohttp/compare/v3.6.1...v3.6.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-16 15:51:49 +02:00
Pascal Vizeli
6b29022822 Update azure-pipelines-wheels.yml 2020-07-16 15:51:14 +02:00
dependabot[bot]
2e671cc5ee Bump codecov from 2.1.7 to 2.1.8 (#1838)
Bumps [codecov](https://github.com/codecov/codecov-python) from 2.1.7 to 2.1.8.
- [Release notes](https://github.com/codecov/codecov-python/releases)
- [Changelog](https://github.com/codecov/codecov-python/blob/master/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-python/compare/v2.1.7...2.1.8)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-16 09:12:04 +02:00
dependabot[bot]
f25692b98c Bump pytest-timeout from 1.4.1 to 1.4.2 (#1839)
Bumps [pytest-timeout](https://github.com/pytest-dev/pytest-timeout) from 1.4.1 to 1.4.2.
- [Release notes](https://github.com/pytest-dev/pytest-timeout/releases)
- [Commits](https://github.com/pytest-dev/pytest-timeout/compare/1.4.1...1.4.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-16 09:11:51 +02:00
Franck Nijhof
c4a011b261 Don't reuse venv cache when Python version changes (#1837) 2020-07-15 15:03:53 +02:00
Pascal Vizeli
a935bac20b Bump version to 230 2020-07-15 15:03:01 +02:00
Pascal Vizeli
0a3a98cb42 Merge pull request #1836 from home-assistant/dev
Release 229
2020-07-15 15:02:18 +02:00
Pascal Vizeli
adb39ca93f Support to exclude machine (#1835)
* Support to exclude machine

* add tests
2020-07-15 14:53:44 +02:00
Pascal Vizeli
5fdc340e58 Streamline version (#1834)
* More streamline version handling

* Strict it up

* update tests
2020-07-15 13:05:11 +02:00
Pascal Vizeli
bb64dca6e6 Fix symlink snapshot (#1833)
* Fix symbolic link issue with snapshot

* Add tests

* fix symlink

* add encrypted test

* Modify x
2020-07-14 15:39:03 +02:00
dependabot[bot]
685788bcdf Bump gitpython from 3.1.3 to 3.1.7 (#1830)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.1.3 to 3.1.7.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.1.3...3.1.7)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-14 15:12:04 +02:00
dependabot[bot]
e949aa35f3 Bump actions/upload-artifact from v1 to 2.1.0 (#1829)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from v1 to 2.1.0.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v1...ebad382c0953e8c6b4039e8d30dfd19ee7b2a862)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-14 13:58:21 +02:00
dependabot[bot]
fc80bf0df4 Bump codecov/codecov-action from v1 to v1.0.10 (#1828)
Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from v1 to v1.0.10.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Commits](https://github.com/codecov/codecov-action/compare/v1...f3570723ef743f6942b6a480461ed0cd6c0f9baa)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-14 13:55:26 +02:00
dependabot-preview[bot]
bd9740e866 Create Dependabot config file (#1826)
* Create Dependabot config file

* ✏️ Tweak

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Franck Nijhof <git@frenck.dev>
2020-07-14 12:02:44 +02:00
Pascal Vizeli
3a260a8fd9 Fix terminal 2020-07-14 10:00:27 +00:00
Paulus Schoutsen
c87e6a5a42 Drop last references 3.7 (#1825) 2020-07-14 02:48:57 +02:00
Pascal Vizeli
8bc3319523 Update release-drafter.yml 2020-07-13 22:27:57 +02:00
Pascal Vizeli
bdfcf1a2df Migrate to python 3.8 (#1824)
* Migrate to python 3.8

* Fix tests on Py38

* cleanup tests

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2020-07-13 22:26:41 +02:00
dependabot-preview[bot]
7f4284f2af Bump pyupgrade from 2.6.2 to 2.7.0 (#1822)
Bumps [pyupgrade](https://github.com/asottile/pyupgrade) from 2.6.2 to 2.7.0.
- [Release notes](https://github.com/asottile/pyupgrade/releases)
- [Commits](https://github.com/asottile/pyupgrade/compare/v2.6.2...v2.7.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-07-13 17:04:13 +02:00
dependabot-preview[bot]
fd69120aa6 Bump coverage from 5.1 to 5.2 (#1820)
Bumps [coverage](https://github.com/nedbat/coveragepy) from 5.1 to 5.2.
- [Release notes](https://github.com/nedbat/coveragepy/releases)
- [Changelog](https://github.com/nedbat/coveragepy/blob/master/CHANGES.rst)
- [Commits](https://github.com/nedbat/coveragepy/compare/coverage-5.1...coverage-5.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-07-08 13:39:38 +02:00
dependabot-preview[bot]
5df60b17e8 Bump codecov from 2.1.0 to 2.1.7 (#1817)
Bumps [codecov](https://github.com/codecov/codecov-python) from 2.1.0 to 2.1.7.
- [Release notes](https://github.com/codecov/codecov-python/releases)
- [Changelog](https://github.com/codecov/codecov-python/blob/master/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-python/commits/v2.1.7)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-07-07 11:32:50 +02:00
Joakim Sørensen
cb835b5ae6 Update frontend to a674ce3 (#1816) 2020-07-05 21:27:39 +02:00
Franck Nijhof
9eab92513a Add QA/CI to Supervisor (#1814) 2020-07-05 20:20:29 +02:00
dependabot-preview[bot]
29e8f50ab8 Bump docker from 4.2.1 to 4.2.2 (#1809)
Bumps [docker](https://github.com/docker/docker-py) from 4.2.1 to 4.2.2.
- [Release notes](https://github.com/docker/docker-py/releases)
- [Commits](https://github.com/docker/docker-py/compare/4.2.1...4.2.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-07-03 11:52:08 +02:00
Sean Mooney
aa0496b236 Update Issue Template (#1812)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-07-02 15:09:50 -07:00
Joakim Sørensen
06e9cec21a Update frontend panel to 750e7b (#1811)
* Update frontend to 750e7b1

* Remove files

* Fix cleanup in frontend update script
2020-07-02 19:35:43 +02:00
Pascal Vizeli
0fe27088df add pylance 2020-07-01 09:29:58 +00:00
Pascal Vizeli
54d226116d Bump version to 229 2020-06-28 11:29:18 +02:00
Pascal Vizeli
4b37e30680 Merge pull request #1804 from home-assistant/dev
Release 228
2020-06-28 11:28:10 +02:00
Pascal Vizeli
7c5f710deb Slowdown snapshots to make it faster on slow IO (#1803)
* Slowdown snapshots to make it faster on slow IO

* Fix error handling

* fix lint
2020-06-28 10:58:13 +02:00
Paulus Schoutsen
5a3ebaf683 Remove old panel files (#1802) 2020-06-28 10:48:04 +02:00
Pascal Vizeli
233da0e48f defcontainer update 2020-06-27 20:52:59 +00:00
Maximilian Bösing
96380d8d28 When calling atomic_contents_add recursively, pass the Path object instead of the posix path (#1801)
Fixes #1800

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>
2020-06-27 22:44:34 +02:00
Pascal Vizeli
c84a0edf20 Update panel for new style (#1799)
Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-06-27 11:56:26 +02:00
Maximilian Bösing
a3cf445c93 Bugfix: No such file or directory: '/data/homeassistant/home-assistant_v2.db-shm' (#1795)
* Do not use `tar_file.add` to recursively add backup folder

As the folders might contain files which are being removed temporarily (e.g. shared memory file of sqlite database), relying on `tar_file.add` becomes problematic as it crashes the whole backup process if a file does not exist anymore.
This becomes annoying, if the file which causes the error should be excluded by the filter.

To workaround this issue, we manually iterating over the files/directories and apply filters before passing the file or directory to the `tar_file.add` method. As per [documentation](https://docs.python.org/3/library/pathlib.html#pure-paths), pure path does not access the file system.

Fixes #779

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Remove unused import

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Applied code review suggestions

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Applied codestyle

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Remove `pathlib` util and move `is_excluded_by_filter` into `tar` utils

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Rename method

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Rename `origin_dir` to `origin_path` and apply `Path` typehint

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Codestyle

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Add comment why we add the directory even if we are iterating over all its items

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Use `atomic_contents_add` from tar utils to archive addon data

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Remove unused function `exclude_filter`

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Remove unsecure default list value

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Some more codestyle

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Lowercase method name `Path.joinpath`

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Fix codestyle and use proper variable

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Add test for `_is_excluded_by_filter`

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>

* Update addon.py

Co-authored-by: Pascal Vizeli <pascal.vizeli@syshack.ch>
2020-06-26 11:36:49 +02:00
dependabot-preview[bot]
3f31979f66 Bump pytest-timeout from 1.4.0 to 1.4.1 (#1798)
Bumps [pytest-timeout](https://github.com/pytest-dev/pytest-timeout) from 1.4.0 to 1.4.1.
- [Release notes](https://github.com/pytest-dev/pytest-timeout/releases)
- [Commits](https://github.com/pytest-dev/pytest-timeout/compare/1.4.0...1.4.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-19 15:12:46 +02:00
Franck Nijhof
44416edfd2 Collection of minor changes (#1793)
* Collection of minor changes

* Process smaller comments

* Fix HA version handling

* More type hints

* Review comment from Martin

* Add protection against TypeError in version parsing
2020-06-18 11:41:13 +02:00
Pascal Vizeli
351c45da75 Add the current supervisor version as default (#1791)
* Add the current supervisor version as default

* Fix lint

* Improve new version handling
2020-06-15 14:47:27 +02:00
dependabot-preview[bot]
e27c5dad15 Bump pytest-timeout from 1.3.4 to 1.4.0 (#1792)
Bumps [pytest-timeout](https://github.com/pytest-dev/pytest-timeout) from 1.3.4 to 1.4.0.
- [Release notes](https://github.com/pytest-dev/pytest-timeout/releases)
- [Commits](https://github.com/pytest-dev/pytest-timeout/compare/1.3.4...1.4.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-15 14:43:02 +02:00
dependabot-preview[bot]
dc510f22ac Bump flake8 from 3.8.2 to 3.8.3 (#1787)
Bumps [flake8](https://gitlab.com/pycqa/flake8) from 3.8.2 to 3.8.3.
- [Release notes](https://gitlab.com/pycqa/flake8/tags)
- [Commits](https://gitlab.com/pycqa/flake8/compare/3.8.2...3.8.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-09 14:48:44 +02:00
dependabot-preview[bot]
1b78011f8b Bump pylint from 2.5.2 to 2.5.3 (#1785)
Bumps [pylint](https://github.com/PyCQA/pylint) from 2.5.2 to 2.5.3.
- [Release notes](https://github.com/PyCQA/pylint/releases)
- [Changelog](https://github.com/PyCQA/pylint/blob/master/ChangeLog)
- [Commits](https://github.com/PyCQA/pylint/compare/pylint-2.5.2...pylint-2.5.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-08 13:28:34 +02:00
Pascal Vizeli
a908828bf4 Bump version to 228 2020-06-04 14:05:43 +02:00
Pascal Vizeli
55b7eb62f6 Merge pull request #1778 from home-assistant/dev
Release 227
2020-06-04 14:05:16 +02:00
Paulus Schoutsen
10e8fcf3b9 Remove complete frontend dir on rebuild and update frontend (#1777) 2020-06-04 08:58:12 +02:00
dependabot-preview[bot]
f1b0c05447 Bump pytest from 5.4.2 to 5.4.3 (#1776)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.4.2 to 5.4.3.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.4.2...5.4.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-03 13:31:24 +02:00
dependabot-preview[bot]
de22bd688e Bump docker from 4.2.0 to 4.2.1 (#1775)
Bumps [docker](https://github.com/docker/docker-py) from 4.2.0 to 4.2.1.
- [Release notes](https://github.com/docker/docker-py/releases)
- [Commits](https://github.com/docker/docker-py/compare/4.2.0...4.2.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-03 13:31:10 +02:00
Franck Nijhof
9fe35b4fb5 Improve type hinting for add-ons (#1769)
* Improve type hinting for add-ons

* Split installed vs AnyAddons extraction
2020-06-03 09:28:02 +02:00
Franck Nijhof
f13d08d37a Fix additional parameter on exception (#1774) 2020-06-02 22:57:47 +02:00
Pascal Vizeli
a0ecb46584 Bump version to 227 2020-06-02 15:36:20 +02:00
Pascal Vizeli
0c57df0c8e Merge pull request #1773 from home-assistant/dev
Release 226
2020-06-02 15:35:11 +02:00
Pascal Vizeli
9c902c5c69 Expose all services/discovery with possible add-ons (#1772) 2020-06-02 15:17:24 +02:00
Pascal Vizeli
af412c3105 Handle new API / Frontend early boot (#1770)
* Handle new API / Frontend early boot

* Adjust part 2

* fix hanging landingpage

* Fix catch error

* Fix watchdog
2020-06-02 14:53:57 +02:00
Franck Nijhof
ec43448163 Make addon model abstract (#1768) 2020-06-02 12:08:03 +02:00
Franck Nijhof
9f7e0ecd55 Docs string and exception message improvements (#1767) 2020-06-02 11:26:33 +02:00
Pascal Vizeli
e50515a17c Slowdown docker stop/start to avoid issue on slow IO (#1763)
* Slowdown docker stop/start to avoid issue on slow IO

* Fix lint

* Address comments

* Fix restore logic & Style

* Fix type

* Slow plugins
2020-06-02 11:26:10 +02:00
dependabot-preview[bot]
7c345db6fe Bump gitpython from 3.1.2 to 3.1.3 (#1764)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.1.2 to 3.1.3.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.1.2...3.1.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-06-01 15:05:40 +02:00
Michal
51c2268c1e Fix typo in discovery log message (#1761)
typo
2020-05-30 13:37:08 +02:00
Pascal Vizeli
51feca05a5 Bump version to 226 2020-05-28 14:38:31 +02:00
Pascal Vizeli
3889504292 Merge pull request #1758 from home-assistant/dev
Release 255
2020-05-28 14:37:30 +02:00
Pascal Vizeli
7bd6ff374a Fix watchdog & scheduler (#1757)
* Fix watchdog & scheduler

* Update supervisor/misc/scheduler.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Fix callback

* hmm

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-05-28 14:25:36 +02:00
Sergey Morozik
44fa34203a Ingress skip incorrect session (#1755)
* ingress skip invalid timestamps

* ingress skip invalid timestamp: comment

* Use lazy string instead of f-string

* skip incorrect timestamp in validate_session
2020-05-28 09:30:15 +02:00
Pascal Vizeli
ff351c7f6d HA landing page retry 30sec (#1756) 2020-05-28 09:27:48 +02:00
Pascal Vizeli
960b00d85a Detect lxc (#1754)
* Detect LXC on health check

* fix lint

* Update supervisor/core.py

Co-authored-by: Franck Nijhof <git@frenck.dev>

* fix black

Co-authored-by: Franck Nijhof <git@frenck.dev>
2020-05-26 14:12:19 +02:00
dependabot-preview[bot]
18e3eacd7f Bump flake8 from 3.8.1 to 3.8.2 (#1753)
Bumps [flake8](https://gitlab.com/pycqa/flake8) from 3.8.1 to 3.8.2.
- [Release notes](https://gitlab.com/pycqa/flake8/tags)
- [Commits](https://gitlab.com/pycqa/flake8/compare/3.8.1...3.8.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-25 13:22:13 +02:00
dependabot-preview[bot]
f4a1da33c4 Bump pulsectl from 20.5.0 to 20.5.1 (#1752)
Bumps [pulsectl](https://github.com/mk-fg/python-pulse-control) from 20.5.0 to 20.5.1.
- [Release notes](https://github.com/mk-fg/python-pulse-control/releases)
- [Changelog](https://github.com/mk-fg/python-pulse-control/blob/master/CHANGES.rst)
- [Commits](https://github.com/mk-fg/python-pulse-control/commits)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-25 13:21:59 +02:00
Franck Nijhof
49de5be44e Collection of type hinting fixes (#1747) 2020-05-23 13:19:53 +02:00
Pascal Vizeli
383657e8ce Bump version 225 2020-05-22 17:25:14 +02:00
Pascal Vizeli
3af970ead6 Merge pull request #1746 from home-assistant/dev
Release 224
2020-05-22 17:23:40 +02:00
Franck Nijhof
6caec79958 Complete typehinting in CoreSys (#1745)
* Complete typehinting in CoreSys

* Improve Addon model abstraction, solving Pylint warning
2020-05-22 17:05:40 +02:00
Franck Nijhof
33bbd92d9b Fix S6 supervisor not listening in finish script (#1741) 2020-05-22 16:42:35 +02:00
Pascal Vizeli
9dba78fbcd Improve version handling (#1744)
* version handling helper

* Improve version handling

* Fix bug
2020-05-22 14:21:47 +02:00
Franck Nijhof
630d85ec78 Use f-strings where possible (#1740) 2020-05-22 13:41:14 +02:00
Franck Nijhof
f0d46e8671 Improve flake8 configuration and pydocstyle fixes (#1742) 2020-05-22 13:38:57 +02:00
Franck Nijhof
db0593f0b2 Fix YAML & JSON styling (#1743) 2020-05-22 13:38:05 +02:00
Franck Nijhof
1d83c0c77a Update isort configuration and sorts imports in codebase (#1739)
* Add known first party to isort configuration

* Run isort on supervisor and tests folder
2020-05-21 13:30:54 +02:00
Pascal Vizeli
5e5fd3a79b Bump version 224 2020-05-21 12:09:15 +02:00
Pascal Vizeli
c61995aab8 Merge pull request #1738 from home-assistant/dev
Release 223
2020-05-21 12:08:36 +02:00
Franck Nijhof
37c393f857 Add mypy cache files to .gitignore (#1737) 2020-05-21 12:07:20 +02:00
Pascal Vizeli
8e043a01c1 Add Docker info & check (#1736)
* Add Docker info & check

* Add checks

* Fix logging

* fix lint
2020-05-21 12:06:27 +02:00
Franck Nijhof
c7b6b2ddb3 Cleanup and speedup pylint (#1735) 2020-05-21 12:01:43 +02:00
Franck Nijhof
522f68bf68 Remove passing in deprecated loop arguments (#1733) 2020-05-21 12:01:21 +02:00
Franck Nijhof
7d4866234f Replace Logger.fatal by Logger.critical (#1734) 2020-05-21 12:00:52 +02:00
Pascal Vizeli
7aa5bcfc7c Update panel for markdown fixes (#1732)
Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-05-20 17:51:24 +02:00
dependabot-preview[bot]
04b59f0896 Bump pulsectl from 20.4.3 to 20.5.0 (#1731)
Bumps [pulsectl](https://github.com/mk-fg/python-pulse-control) from 20.4.3 to 20.5.0.
- [Release notes](https://github.com/mk-fg/python-pulse-control/releases)
- [Changelog](https://github.com/mk-fg/python-pulse-control/blob/master/CHANGES.rst)
- [Commits](https://github.com/mk-fg/python-pulse-control/commits)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-20 14:42:23 +02:00
Pascal Vizeli
796f9a203e Rename zwave_mqtt to ozw (#1729) 2020-05-19 16:54:50 +02:00
dependabot-preview[bot]
22c8cda0d7 Bump packaging from 20.3 to 20.4 (#1728)
Bumps [packaging](https://github.com/pypa/packaging) from 20.3 to 20.4.
- [Release notes](https://github.com/pypa/packaging/releases)
- [Changelog](https://github.com/pypa/packaging/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pypa/packaging/compare/20.3...20.4)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-19 16:33:31 +02:00
Klaudiusz Staniek
1cf534ccc5 Fix config version setter (#1716)
Co-authored-by: Klaudiusz Staniek <klstanie@cisco.com>
2020-05-18 11:23:45 +02:00
dependabot-preview[bot]
6d8c821148 Bump flake8 from 3.7.9 to 3.8.1 (#1722)
Bumps [flake8](https://gitlab.com/pycqa/flake8) from 3.7.9 to 3.8.1.
- [Release notes](https://gitlab.com/pycqa/flake8/tags)
- [Commits](https://gitlab.com/pycqa/flake8/compare/3.7.9...3.8.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-18 10:58:43 +02:00
Martin Hjelmare
264e9665b0 Lint tests during tox (#1721) 2020-05-18 10:06:07 +02:00
Martin Hjelmare
53fa8e48c0 Delint tests (#1720)
* Delint tarfile test

* Delint tests
2020-05-11 20:41:09 +02:00
Martin Hjelmare
e406aa4144 Fix vscode tasks supervisor dir (#1719) 2020-05-11 18:22:01 +02:00
dependabot-preview[bot]
4953ba5077 Bump pytest from 5.4.1 to 5.4.2 (#1717) 2020-05-11 14:02:31 +02:00
Pascal Vizeli
0a97ac0578 Bump version 223 2020-05-08 16:25:34 +02:00
Pascal Vizeli
56af4752f4 Merge pull request #1712 from home-assistant/dev
Release 222
2020-05-08 16:24:18 +02:00
Pascal Vizeli
81413d08ed Prevent boot loop (#1711)
* Prevent boot loop

* sort
2020-05-08 16:13:36 +02:00
Bram Kragten
2bc2a476d9 Bump forntend (#1710) 2020-05-08 13:58:20 +02:00
Pascal Vizeli
4d070a65c6 Bump version 222 2020-05-07 19:16:27 +02:00
Pascal Vizeli
6185fbaf26 Merge pull request #1704 from home-assistant/dev
Fix panel
2020-05-07 19:15:59 +02:00
Pascal Vizeli
698a126b93 Fix panel
Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-05-07 17:14:52 +00:00
Pascal Vizeli
acf921f55d Merge pull request #1703 from home-assistant/dev
Release 221
2020-05-07 19:02:31 +02:00
Bram Kragten
f5a78c88f8 Bump supervisor panel (#1702) 2020-05-07 17:41:10 +02:00
dependabot-preview[bot]
206ece1575 Bump pylint from 2.5.0 to 2.5.2 (#1700)
Bumps [pylint](https://github.com/PyCQA/pylint) from 2.5.0 to 2.5.2.
- [Release notes](https://github.com/PyCQA/pylint/releases)
- [Changelog](https://github.com/PyCQA/pylint/blob/master/ChangeLog)
- [Commits](https://github.com/PyCQA/pylint/compare/pylint-2.5.0...pylint-2.5.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-07 17:04:08 +02:00
dependabot-preview[bot]
a8028dbe10 Bump gitpython from 3.1.1 to 3.1.2 (#1697)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.1.1 to 3.1.2.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.1.1...3.1.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-05-07 17:04:00 +02:00
Pascal Vizeli
c605af6ccc Add discovery support for new ozw integration (#1701) 2020-05-07 08:32:10 +02:00
Pascal Vizeli
b7b8e6c40e Bump version 221 2020-05-01 18:11:58 +02:00
Pascal Vizeli
3fcb1de419 Merge pull request #1692 from home-assistant/dev
Release 220
2020-05-01 18:07:35 +02:00
Pascal Vizeli
12034fe5fc Update panel with new tabs (#1691)
Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-05-01 17:51:35 +02:00
dependabot-preview[bot]
56959d781a Bump pylint from 2.4.4 to 2.5.0 (#1684)
* Bump pylint from 2.4.4 to 2.5.0

Bumps [pylint](https://github.com/PyCQA/pylint) from 2.4.4 to 2.5.0.
- [Release notes](https://github.com/PyCQA/pylint/releases)
- [Changelog](https://github.com/PyCQA/pylint/blob/master/ChangeLog)
- [Commits](https://github.com/PyCQA/pylint/compare/pylint-2.4.4...pylint-2.5.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

* fix lint

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-05-01 15:34:12 +02:00
Pascal Vizeli
9a2f025646 Add support for homematic (#1690) 2020-05-01 15:23:56 +02:00
Pascal Vizeli
12cc163058 New addon panel (#1689)
* Update add-on pages

* update panel
2020-05-01 14:23:54 +02:00
dependabot-preview[bot]
74971d9753 Bump pytz from 2019.3 to 2020.1 (#1686)
Bumps [pytz](https://github.com/stub42/pytz) from 2019.3 to 2020.1.
- [Release notes](https://github.com/stub42/pytz/releases)
- [Commits](https://github.com/stub42/pytz/compare/release_2019.3...release_2020.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-04-29 12:15:31 +02:00
Franck Nijhof
a9157e3a9f Fix possible Ingress port collisions (#1682)
* Fix possible Ingress port collisions

* Cleanup dynamic port assignment on uninstall

* Check port against gateway address

* gateway address is already of type IPv4Address

* Update supervisor/ingress.py

Co-Authored-By: Pascal Vizeli <pvizeli@syshack.ch>

Co-authored-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-04-26 11:21:56 +02:00
dependabot-preview[bot]
b96697b708 Bump cryptography from 2.9.1 to 2.9.2 (#1676)
Bumps [cryptography](https://github.com/pyca/cryptography) from 2.9.1 to 2.9.2.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/2.9.1...2.9.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-04-23 18:44:32 +02:00
dependabot-preview[bot]
81e6896391 Bump cryptography from 2.9 to 2.9.1 (#1673)
Bumps [cryptography](https://github.com/pyca/cryptography) from 2.9 to 2.9.1.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/2.9...2.9.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-04-22 14:23:00 +02:00
dependabot-preview[bot]
2dcaa3608d Bump pulsectl from 20.2.4 to 20.4.3 (#1674)
Bumps [pulsectl](https://github.com/mk-fg/python-pulse-control) from 20.2.4 to 20.4.3.
- [Release notes](https://github.com/mk-fg/python-pulse-control/releases)
- [Changelog](https://github.com/mk-fg/python-pulse-control/blob/master/CHANGES.rst)
- [Commits](https://github.com/mk-fg/python-pulse-control/commits)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-04-22 13:14:54 +02:00
Pascal Vizeli
e21671ec5e Bump version to 220 2020-04-22 11:32:13 +02:00
Pascal Vizeli
7841f14163 Merge pull request #1671 from home-assistant/dev
Release 219
2020-04-22 11:31:50 +02:00
Pascal Vizeli
cc9f594ab4 Better initial image load handling (#1672) 2020-04-22 11:26:53 +02:00
Pascal Vizeli
ebfaaeaa6b Improve the flow with fallback if there is a network issue (#1670) 2020-04-22 11:06:59 +02:00
Pascal Vizeli
ffa91e150d Fix handling with reset/default on json (#1669)
* Fix handling with reset/default on json

* black
2020-04-22 11:06:49 +02:00
Pascal Vizeli
06fa9f9a9e Bump version to 219 2020-04-21 20:15:15 +02:00
Pascal Vizeli
9f203c42ec Merge pull request #1668 from home-assistant/dev
Release 218
2020-04-21 20:14:44 +02:00
Pascal Vizeli
5d0d34a4af Fix version detection 2020-04-21 15:32:20 +00:00
Pascal Vizeli
c2cfc0d3d4 Allow moving registry for supervisor (#1667)
* Allow moving registry for supervisor

* fix

* Filter number
2020-04-21 16:59:28 +02:00
Pascal Vizeli
0f4810d41f Add debug 2020-04-21 13:09:52 +00:00
Pascal Vizeli
175848f2a8 Fix update order (#1666) 2020-04-21 14:41:44 +02:00
Fabian Affolter
472bd66f4d Update README (#1662) 2020-04-14 13:38:00 +02:00
dependabot-preview[bot]
168ea32d2c Bump jinja2 from 2.11.1 to 2.11.2 (#1663)
Bumps [jinja2](https://github.com/pallets/jinja) from 2.11.1 to 2.11.2.
- [Release notes](https://github.com/pallets/jinja/releases)
- [Changelog](https://github.com/pallets/jinja/blob/master/CHANGES.rst)
- [Commits](https://github.com/pallets/jinja/compare/2.11.1...2.11.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-04-14 13:37:49 +02:00
Fabian Affolter
e82d6b1ea4 Minor re-work (#1661)
* Minor re-work

* Fix typo
2020-04-14 10:27:10 +02:00
dependabot-preview[bot]
6c60ca088c Bump gitpython from 3.1.0 to 3.1.1 (#1659)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.1.0 to 3.1.1.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.1.0...3.1.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-04-14 10:25:59 +02:00
Fabian Affolter
83e8f935fd Remove duoble DNS section (#1660) 2020-04-14 10:25:38 +02:00
Pascal Vizeli
71867302a4 Bump version to 218 2020-04-12 12:00:53 +02:00
Pascal Vizeli
8bcc402c5f Merge pull request #1656 from home-assistant/dev
Release 217
2020-04-12 12:00:16 +02:00
Pascal Vizeli
72b7d2a123 Fix restore on older snapshots (#1655) 2020-04-12 11:56:37 +02:00
Aidan Timson
20c1183450 Remove Azure CI badge (#1648)
* Fix azure ci badge

* Remove Azure CI badge
2020-04-11 14:07:19 +02:00
Pascal Vizeli
0bbfbd2544 Readd audio api 2020-04-11 13:35:26 +02:00
Pascal Vizeli
350bd9c32f Bump version to 217 2020-04-11 11:16:31 +02:00
Pascal Vizeli
dcca8b0a9a Merge pull request #1652 from home-assistant/dev
Release 216
2020-04-11 11:15:57 +02:00
Pascal Vizeli
f77b479e45 Add timeout for clean shutdown (#1650)
* Fix overlay

* Update Dockerfile
2020-04-10 23:31:24 +02:00
Pascal Vizeli
216565affb Give a bit more time to update apparmor (#1647) 2020-04-10 01:15:47 +02:00
Pascal Vizeli
6f235c2a11 force dns plugin v9 2020-04-09 16:45:10 +02:00
Pascal Vizeli
27a770bd1d force dns plugin v7 2020-04-08 23:39:18 +02:00
Pascal Vizeli
ef15b67571 Bump version to 216 2020-04-08 14:44:10 +02:00
Pascal Vizeli
6aad966c52 Merge pull request #1644 from home-assistant/dev
Release 215
2020-04-08 14:43:37 +02:00
Pascal Vizeli
9811f11859 Force plugin: cli v25 - dns v6 2020-04-08 12:34:42 +00:00
Pascal Vizeli
13148ec7fb Filter add-ons in the store based on advanced mode (#1643)
* Filter add-ons in the store based on advanced mode

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>

* Filter add-ons in the store based on advanced mode p2

Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-04-08 14:29:43 +02:00
Pascal Vizeli
b2d7464790 Fix multicast API for logs (#1642) 2020-04-08 14:08:09 +02:00
Joakim Sørensen
ce84e185ad Restore repositories with partial snapshot (#1641)
* Restore repositories with partial snapshot

* Run black
2020-04-08 13:44:03 +02:00
Franck Nijhof
c3f5ee43b6 Add missing multicast/logs endpoint to API docs (#1640) 2020-04-08 12:11:59 +02:00
Pascal Vizeli
e2dc1a4471 Support plugin requirements & mdns (#1638)
* Support plugin requirements & mdns

* better error handling

* Use debug from LogLevel

* fix lint

* fix logger

* fix test env

* Use new style

* fix typo
2020-04-07 12:08:29 +02:00
Pascal Vizeli
e787e59b49 Cleanup network (#1637)
* Cleanup network forward

* Add permission
2020-04-06 14:00:52 +02:00
Pascal Vizeli
f0ed2eba2b Multicast support on Hass.io Network (#1634)
* Add multicast layer to docker

* support network forward

* add pluginmanager

* finish multicast plugin

* fix lint

* Add shutdown for plugins

* Add API

* Add watchdog

* Fix black

* Fix path
2020-04-05 23:26:22 +02:00
Pascal Vizeli
2364e1e652 Remove old authentication (#1635) 2020-04-05 19:16:12 +02:00
Pascal Vizeli
cc56944d75 relicense project 2020-04-05 16:23:52 +02:00
Pascal Vizeli
69cea9fc96 Plugin cleanup (#1632)
* Plugin cleanup

* Fix setup
2020-04-05 01:20:49 +02:00
Pascal Vizeli
fcebc9d1ed Use updater for image data (#1628)
* Use updater for image data

* Fix message

* Fix handling

* Update code

* fix lint

* fix names

* Fix log

* Fix error log

* make it better
2020-04-05 00:47:05 +02:00
Pascal Vizeli
9350e4f961 Store image on local config (#1627)
* Store image on local config

* Fix api validate

* Fix install handling
2020-04-03 17:12:18 +02:00
Pascal Vizeli
387e0ad03e Adjust dbus support for pulse (#1626) 2020-04-03 14:27:30 +02:00
dependabot-preview[bot]
61fec8b290 Bump cryptography from 2.8 to 2.9 (#1625)
Bumps [cryptography](https://github.com/pyca/cryptography) from 2.8 to 2.9.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/2.8...2.9)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-04-03 13:44:03 +02:00
Pascal Vizeli
1228baebf4 Cleanup host groups (#1623) 2020-04-02 18:00:17 +02:00
Pascal Vizeli
a30063e85c Bump version to 215 2020-03-30 12:38:37 +02:00
Pascal Vizeli
524cebac4d Merge pull request #1617 from home-assistant/dev
Release 214
2020-03-30 12:37:45 +02:00
Pascal Vizeli
c94114a566 Update panel (#1616) 2020-03-30 12:34:21 +02:00
Pascal Vizeli
b6ec7a9e64 Bump version to 214 2020-03-29 14:35:55 +02:00
Pascal Vizeli
69be7a6d22 Merge pull request #1611 from home-assistant/dev
Release 213
2020-03-29 14:35:10 +02:00
Pascal Vizeli
58155c35f9 Supervisor use own dns layer (#1610)
* Supervisor use own dns layer

* Add logs
2020-03-29 13:45:46 +02:00
Pascal Vizeli
7b2377291f Fix error handling on tasks (#1608) 2020-03-28 17:05:42 +01:00
Pascal Vizeli
657ee84e39 Bump version to 213 2020-03-28 16:10:22 +01:00
Pascal Vizeli
2e4b545265 Merge pull request #1607 from home-assistant/dev
Release 212
2020-03-28 16:09:49 +01:00
Pascal Vizeli
2de1d35dd1 Get host dmesg as host logs (#1606)
* Get host dmesg as host logs

* fix lint
2020-03-28 15:56:57 +01:00
Pascal Vizeli
2b082b362d Fix cli update (#1605)
* Fix cli update

* fix logging

* Fix
2020-03-28 15:21:32 +01:00
Pascal Vizeli
dfdd0d6b4b Bump version to 212 2020-03-27 22:27:52 +01:00
Pascal Vizeli
a00e81c03f Merge pull request #1604 from home-assistant/dev
Release 211
2020-03-27 22:26:56 +01:00
Pascal Vizeli
776e6bb418 Rename API last/latest (#1603)
* Rename API last/latest

* Update panel

* Fix for HA

* ha need this
2020-03-27 22:07:54 +01:00
Pascal Vizeli
b31fca656e Bump version to 211 2020-03-27 17:48:02 +01:00
Pascal Vizeli
fa783a0d2c Merge pull request #1602 from home-assistant/dev
Release 210
2020-03-27 17:46:51 +01:00
Pascal Vizeli
96c0fbaf10 Cli rebrand (#1601)
* Rebrand CLI

* forward

* Fix startup command

* add cli api

* Add token handling

* Fix security check

* fix repair

* fix lint

* Update for new cli

* Add watchdog

* rename

* use s6
2020-03-27 17:37:48 +01:00
Pascal Vizeli
24f7801ddc Fix wrong function for set profiles (#1600) 2020-03-27 12:32:14 +01:00
Pascal Vizeli
8e83e007e9 DNS loop protection (#1599)
* DNS loop protection

* Update supervisor/dns.py

Co-Authored-By: Franck Nijhof <git@frenck.dev>

* cleanup not needed code

* Fix

Co-authored-by: Franck Nijhof <git@frenck.dev>
2020-03-27 11:54:32 +01:00
Pascal Vizeli
d0db466e67 Use DoT as fallback (#1597)
* Use DoT as fallback / add cache

* Stage

* merge

* fix lint

* Fallback server

* use fallback

* add nxdomain

* Address comments
2020-03-27 00:38:54 +01:00
Franck Nijhof
3010bd4eb6 Remove Home Panel Discovery (#1594)
* Remove Home Panel Discovery

* Remove related tests
2020-03-23 10:32:56 +01:00
Phill (pssc)
069bed8815 Rasie limit on container shutdown for addons usecase tmpfs based mariadb for recorder taking over 2 mins for dump (#1595) 2020-03-23 09:15:35 +01:00
Pascal Vizeli
d2088ae5f8 Update azure-pipelines-wheels.yml for Azure Pipelines 2020-03-21 09:13:13 +01:00
dependabot-preview[bot]
0ca5a241bb Bump cchardet from 2.1.5 to 2.1.6 (#1593)
Bumps [cchardet](https://github.com/PyYoshi/cChardet) from 2.1.5 to 2.1.6.
- [Release notes](https://github.com/PyYoshi/cChardet/releases)
- [Changelog](https://github.com/PyYoshi/cChardet/blob/master/CHANGES.rst)
- [Commits](https://github.com/PyYoshi/cChardet/compare/2.1.5...2.1.6)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-03-18 15:21:12 +01:00
dependabot-preview[bot]
dff32a8e84 Bump pytest from 5.3.5 to 5.4.1 (#1591)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.3.5 to 5.4.1.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.3.5...5.4.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2020-03-16 14:36:11 +01:00
Pascal Vizeli
4a20344652 Log config check (#1583)
* Add more log for config check to debug

* Convert to ascii

* fix comment
2020-03-12 15:16:40 +01:00
Pascal Vizeli
98b969ef06 Bump version to 210 2020-03-06 12:43:11 +01:00
Pascal Vizeli
c8cb8aecf7 Merge pull request #1574 from home-assistant/dev
Release 209
2020-03-06 12:41:56 +01:00
Pascal Vizeli
73e8875018 Fix Issue with pulse folder (#1573)
* Fix Issue with pulse folder

* Fix config check
2020-03-06 12:32:29 +01:00
Pascal Vizeli
02aed9c084 Enforce Pulse client (#1572) 2020-03-05 15:54:23 +01:00
Pascal Vizeli
89148f8fff Bump packaging from 20.1 to 20.3 (#1570)
Bumps [packaging](https://github.com/pypa/packaging) from 20.1 to 20.3.
- [Release notes](https://github.com/pypa/packaging/releases)
- [Changelog](https://github.com/pypa/packaging/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pypa/packaging/compare/20.1...20.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-03-05 13:44:10 +01:00
Pascal Vizeli
6bde527f5c Bump version to 209 2020-03-04 19:09:20 +01:00
Pascal Vizeli
d62aabc01b Merge pull request #1567 from home-assistant/dev
Release 208
2020-03-04 19:08:12 +01:00
Pascal Vizeli
82299a3799 Fix udev error without privileged (#1566)
* Fix udev error without privileged

* Fix udev

* Remove context

* Update supervisor/hwmon.py

Co-Authored-By: Paulus Schoutsen <balloob@gmail.com>

* Update supervisor/hwmon.py

Co-Authored-By: Paulus Schoutsen <balloob@gmail.com>

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-03-04 18:55:07 +01:00
Pascal Vizeli
c02f30dd7e Enforce env check (#1565) 2020-03-04 18:15:10 +01:00
Pascal Vizeli
e91983adb4 Watchdog check in_progress for audio/dns (#1555) 2020-03-03 15:06:09 +01:00
Pascal Vizeli
ff88359429 Bump version to 208 2020-03-02 11:32:01 +01:00
Pascal Vizeli
5a60d5cbe8 Merge pull request #1554 from home-assistant/dev
Release 207
2020-03-02 11:31:26 +01:00
Pascal Vizeli
2b41ffe019 Bump version to 207 2020-03-01 17:52:35 +01:00
Pascal Vizeli
1c23e26f93 Check if SND is loaded (#1552)
* Check if SND is loaded

* add warning
2020-02-29 23:45:37 +01:00
Pascal Vizeli
3d555f951d Fix supervisor update flow with apparmor (#1551) 2020-02-29 23:07:34 +01:00
Bram Kragten
6d39b4d7cd Update audio.py (#1548) 2020-02-29 19:28:52 +01:00
Pascal Vizeli
4fe5d09f01 Bump version to 206 2020-02-29 12:19:42 +01:00
Pascal Vizeli
e52af3bfb4 Merge pull request #1547 from home-assistant/dev
Release 205
2020-02-29 12:18:51 +01:00
Pascal Vizeli
0467b33cd5 Core support audio settings (#1546) 2020-02-29 12:14:03 +01:00
Pascal Vizeli
14167f6e13 Merge pull request #1544 from home-assistant/dev
Release 204
2020-02-29 00:30:16 +01:00
Pascal Vizeli
7a1aba6f81 Fix old alsa format settings (#1543) 2020-02-29 00:25:11 +01:00
Pascal Vizeli
920f7f2ece Support for own init on image (#1542)
* Support for own init on image

* fix params
2020-02-28 23:15:46 +01:00
Pascal Vizeli
06fadbd70f fix lint 2020-02-28 19:25:15 +00:00
Pascal Vizeli
d4f486864f Make audio socket RO and aware of restarts (#1545) 2020-02-29 11:23:36 +01:00
Pascal Vizeli
d3a21303d9 Bump version to 205 2020-02-29 00:31:21 +01:00
Pascal Vizeli
e1cbfdd84b Support mute + applications from pulse (#1541)
* Support mute + applications from pulse

* Fix lint

* Fix application parser

* Fix type

* Add application endpoints

* error handling

* Fix
2020-02-28 17:52:12 +01:00
Pascal Vizeli
87170a4497 Restart add-ons attach to audio with update pulse (#1540) 2020-02-28 14:05:31 +01:00
Pascal Vizeli
ae6f8bd345 Bump version to 203 2020-02-28 10:57:05 +01:00
Pascal Vizeli
b9496e0972 Merge pull request #1539 from home-assistant/dev
Release 203
2020-02-28 10:56:22 +01:00
Pascal Vizeli
c36a6dcd65 Add default asound for pulse (#1538)
* Add default asound for pulse

* fix lint

* fix config
2020-02-28 01:14:43 +01:00
Pascal Vizeli
19ca836b78 Prevent using pulseaudio on event loop (#1536)
* Prevent using pulseaudio on event loop

* Fix name overwrite

* Fix value
2020-02-27 22:01:20 +01:00
Pascal Vizeli
8a6ea7ab50 Use shorter function for soundcard (#1535) 2020-02-27 17:22:12 +01:00
Pascal Vizeli
6721b8f265 Expose sound cards and profiles with endpoint (#1534)
* Expose sound cards and profiles with endpoint

* Fix naming

* Fix issue

* Update API
2020-02-27 16:25:04 +01:00
Pascal Vizeli
9393521f98 Update Panel for audio (#1533) 2020-02-27 13:47:46 +01:00
Pascal Vizeli
398b24e0ab Fix homeassistant config check with overlay-s6 (#1532) 2020-02-27 13:29:42 +01:00
Pascal Vizeli
374bcf8073 Adjust sound reload (#1531)
* Adjust sound reload & remove quirk

* clean info message

* fix hack
2020-02-27 11:58:28 +01:00
Pascal Vizeli
7e3859e2f5 Observe host hardware for realtime actions (#1530)
* Observe host hardware for realtime actions

* Better logging

* fix testenv
2020-02-27 10:31:35 +01:00
Pascal Vizeli
490ec0d462 Bump version to 203 2020-02-26 14:47:38 +01:00
Pascal Vizeli
15bf1ee50e Merge pull request #1528 from home-assistant/dev
Release 202
2020-02-26 14:46:50 +01:00
Pascal Vizeli
6376d92a0d Merge remote-tracking branch 'origin/master' into dev 2020-02-26 13:38:12 +00:00
Pascal Vizeli
10230b0b4c Support profiles on template (#1527) 2020-02-26 14:28:09 +01:00
Pascal Vizeli
2495cda5ec Add Pulse audio control basics (#1525)
* Add Pulse audio control basics

* add functionality

* Fix handling

* Give access to all

* Fix latest issues

* revert docker

* Fix pipeline
2020-02-26 11:48:11 +01:00
Pascal Vizeli
ae8ddca040 Delete entry.sh 2020-02-25 18:38:52 +01:00
Pascal Vizeli
0212d027fb Add Audio layer / PulseAudio (#1523)
* Improve alsa handling

* use default from image

* create alsa folder

* Map config into addon

* Add Audio object

* Fix dbus

* add host group file

* Fix persistent file

* Use new template

* fix lint

* Fix lint

* add API

* Update new base image / build system

* Add audio container

* extend new audio settings

* provide pulse client config

* Adjust files

* Use without auth

* reset did not exists now

* cleanup old alsa layer

* fix tasks

* fix black

* fix lint

* Add dbus support

* add dbus adjustments

* Fixups
2020-02-25 18:37:06 +01:00
dependabot-preview[bot]
a3096153ab Bump gitpython from 3.0.8 to 3.1.0 (#1524)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.0.8 to 3.1.0.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.0.8...3.1.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-02-25 18:30:11 +01:00
dependabot-preview[bot]
7434ca9e99 Bump gitpython from 3.0.8 to 3.1.0 (#1524)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.0.8 to 3.1.0.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.0.8...3.1.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-02-25 18:29:44 +01:00
Pascal Vizeli
4ac7f7dcf0 Rename Hass.io -> Supervisor (#1522)
* Rename Hass.io -> Supervisor

* part 2

* fix lint

* fix auth name
2020-02-21 17:55:41 +01:00
Pascal Vizeli
e9f5b13aa5 Fix wrong last boot (#1521)
* Protect overwrite last boot uptime

* Fix naming

* Fix lint
2020-02-20 21:37:59 +01:00
Pascal Vizeli
1fbb6d46ea Fix webui option (#1519) 2020-02-20 09:17:53 +01:00
Pascal Vizeli
8dbfea75b1 Extend video & add tests (#1518) 2020-02-20 00:29:48 +01:00
zewelor
3b3840c087 Update hardware.py (#1516)
Allow to pass video* devices to containers. Should allow to use usb webcams / uvc tuners.
2020-02-19 09:08:11 +01:00
dependabot-preview[bot]
a21353909d Bump gitpython from 3.0.7 to 3.0.8 (#1513)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.0.7 to 3.0.8.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.0.7...3.0.8)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-02-17 16:58:00 +01:00
Pascal Vizeli
5497ed885a Bump version to 202 2020-02-17 11:38:08 +01:00
Pascal Vizeli
39baea759a Merge pull request #1512 from home-assistant/dev
Release 201
2020-02-17 11:37:29 +01:00
Pascal Vizeli
80ddb1d262 Fix startup of dev envoirement 2020-02-14 17:05:03 +00:00
Pascal Vizeli
e24987a610 Fix ingress on panel after restore (#1508)
* Fix ingress on panel after restore

* Supress errors
2020-02-14 15:58:26 +01:00
Pascal Vizeli
9e5c276e3b Home Assistant Core start flow / partial restore (#1507)
* Fix start flow logic

* Add a note

* Fix flow on partial restore
2020-02-14 15:25:43 +01:00
Pascal Vizeli
c33d31996d Set timeout of 10min for download OTA (#1505) 2020-02-13 17:25:37 +01:00
Franck Nijhof
aa1f08fe8a Update API docs to reflect latest changes (#1502) 2020-02-11 23:09:23 +01:00
Pascal Vizeli
d78689554a Cleanup old logic (#1500) 2020-02-10 23:52:22 +01:00
dependabot-preview[bot]
5bee1d851c Bump gitpython from 3.0.5 to 3.0.7 (#1497)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.0.5 to 3.0.7.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.0.5...3.0.7)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-02-10 16:08:56 +01:00
Pascal Vizeli
ddb8eef4d1 Pump version to 201 2020-02-09 22:41:22 +01:00
Pascal Vizeli
da513e7347 Merge pull request #1495 from home-assistant/dev
Release 200
2020-02-09 22:38:08 +01:00
Pascal Vizeli
4279d7fd16 Check if HA is running (#1494) 2020-02-09 22:15:34 +01:00
Pascal Vizeli
934eab2e8c Fix operating-system url for OTA updates (#1493) 2020-02-09 21:42:22 +01:00
Pascal Vizeli
2a31edc768 Guard addon self lookup (#1492) 2020-02-08 23:56:24 +01:00
Pascal Vizeli
fcdd66dc6e Fix Hardware list (#1490) 2020-02-07 18:30:39 +01:00
dependabot-preview[bot]
a65d3222b9 Bump docker from 4.1.0 to 4.2.0 (#1485)
Bumps [docker](https://github.com/docker/docker-py) from 4.1.0 to 4.2.0.
- [Release notes](https://github.com/docker/docker-py/releases)
- [Commits](https://github.com/docker/docker-py/compare/4.1.0...4.2.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-02-07 16:07:00 +01:00
Pascal Vizeli
36179596a0 Fix HA instance 2020-02-06 10:25:37 +00:00
Pascal Vizeli
c083c850c1 Bump version to 200 2020-02-06 11:20:45 +01:00
Pascal Vizeli
ff903d7b5a Merge pull request #1484 from home-assistant/dev
Release 199
2020-02-06 11:20:17 +01:00
Pascal Vizeli
dd603e1ec2 Support basic video mapping (#1483)
* Support basic video mapping

* Fix regex
2020-02-06 10:48:27 +01:00
Pascal Vizeli
a2f06b1553 VSCode: cleanup homeassistant on shutdown (#1481) 2020-02-06 09:41:22 +01:00
Pascal Vizeli
8115d2b3d3 Show landingpage soon as possible (#1480) 2020-02-06 09:31:52 +01:00
Pascal Vizeli
4f97bb9e0b Fix overwrite authorization / ingress (#1479) 2020-02-06 08:30:27 +01:00
Pascal Vizeli
84d24a2c4d [skip ci] fix dev builds 2020-02-05 11:01:35 +01:00
Pascal Vizeli
b709061656 Bump version to 199 2020-02-05 10:59:38 +01:00
Pascal Vizeli
cd9034b3f1 Merge pull request #1478 from home-assistant/dev
Release 198
2020-02-05 10:58:59 +01:00
Pascal Vizeli
25d324c73a First clean renaming for smooth migration (#1476)
* First clean renaming for smooth migration

* Update security

* fix lint

* Update hassio/const.py

Co-Authored-By: Franck Nijhof <git@frenck.dev>

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2020-02-05 10:57:57 +01:00
Bram Kragten
3a834d1a73 Update frontend (#1477) 2020-02-05 10:08:39 +01:00
Bram Kragten
e9fecb817d Update frontend (#1475) 2020-02-05 09:55:24 +01:00
Bram Kragten
56e70d7ec4 Update frontend (#1473) 2020-02-04 11:18:59 -08:00
Pascal Vizeli
2e73a85aa9 Bump version to 198 2020-02-04 17:55:52 +01:00
Pascal Vizeli
1e119e9c03 Merge pull request #1472 from home-assistant/dev
Release 197
2020-02-04 17:55:12 +01:00
Pascal Vizeli
6f6e5c97df [skip ci] fix pipelines 2020-02-04 16:50:06 +00:00
Pascal Vizeli
6ef99974cf Cleanup service (#1471)
* Cleanup services on uninstall

* Fix active list
2020-02-04 17:40:46 +01:00
Bram Kragten
8984b9aef6 Update frontend (#1469) 2020-02-04 16:53:38 +01:00
Pascal Vizeli
63e08b15bc Revert "Change loglevel INFO to use black textcolor (#1459)" (#1467)
This reverts commit 0b44df366c.
2020-02-03 17:07:00 +01:00
dependabot-preview[bot]
319b2b5d4c Bump pytest from 5.3.4 to 5.3.5 (#1463)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.3.4 to 5.3.5.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.3.4...5.3.5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-01-30 17:03:31 +01:00
dependabot-preview[bot]
bae7bb8ce4 Bump pyudev from 0.21.0 to 0.22.0 (#1461)
Bumps [pyudev](https://github.com/pyudev/pyudev) from 0.21.0 to 0.22.0.
- [Release notes](https://github.com/pyudev/pyudev/releases)
- [Changelog](https://github.com/pyudev/pyudev/blob/develop-0.22/CHANGES.rst)
- [Commits](https://github.com/pyudev/pyudev/compare/v0.21.0...v0.22)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-01-29 12:17:33 +01:00
Franck Nijhof
0b44df366c Change loglevel INFO to use black textcolor (#1459) 2020-01-29 08:45:30 +01:00
Pascal Vizeli
f253c797af Add stage flag (#1460)
* Add stage flag

* Add filter

* Remove filter

* Fix lint
2020-01-28 17:58:29 +01:00
Pascal Vizeli
0a8b1c2797 Bump version 197 2020-01-27 21:46:37 +01:00
Pascal Vizeli
3b45fb417b Merge pull request #1457 from home-assistant/dev
Release 196
2020-01-27 21:44:07 +01:00
Pascal Vizeli
2a2d92e3c5 Change rating for ingress add-on (#1451)
* Change rating for ingress add-on

* Fix style
2020-01-27 21:42:58 +01:00
Pascal Vizeli
a320e42ed5 Fix services validation & add tests (#1456) 2020-01-27 21:38:26 +01:00
Pascal Vizeli
fdef712e01 New Panel (#1455)
* Update Hassio Panel

* Fix issues
2020-01-27 21:20:47 +01:00
Pascal Vizeli
5717ac19d7 Update test_env.sh 2020-01-27 20:41:21 +01:00
Franck Nijhof
33d7d76fee Add UniFi discovery service (#1454) 2020-01-27 17:59:06 +01:00
dependabot-preview[bot]
73bdaa623c Bump packaging from 20.0 to 20.1 (#1450)
Bumps [packaging](https://github.com/pypa/packaging) from 20.0 to 20.1.
- [Release notes](https://github.com/pypa/packaging/releases)
- [Changelog](https://github.com/pypa/packaging/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pypa/packaging/compare/20.0...20.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-01-24 13:06:46 +01:00
Pascal Vizeli
8ca8f59a0b Add mysql service to API (#1449) 2020-01-24 12:11:58 +01:00
Franck Nijhof
745af3c039 Add MySQL service support (#1448) 2020-01-23 19:05:13 +01:00
dependabot-preview[bot]
5d17e1011a Bump pytest from 5.3.3 to 5.3.4 (#1447)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.3.3 to 5.3.4.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.3.3...5.3.4)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-01-21 15:47:44 +01:00
Pascal Vizeli
826464c41b Fix builder version / latest 2020-01-20 21:50:29 +00:00
Pascal Vizeli
a643df8cac Update builder 2020-01-20 21:03:09 +00:00
Bram Kragten
24ded99286 Typo (#1444)
* Typo

* Typo test
2020-01-20 17:11:41 +01:00
dependabot-preview[bot]
6646eee504 Bump pytest from 5.3.2 to 5.3.3 (#1440)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.3.2 to 5.3.3.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.3.2...5.3.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-01-20 15:14:18 +01:00
Pascal Vizeli
f55c10914e UI Schema / Addon options (#1441)
* UI schema for add-on options

* Fix lint

* Add tests

* Address comments
2020-01-20 15:13:17 +01:00
Pascal Vizeli
b1e768f69e Add advanced property for HA simple-mode (#1439) 2020-01-20 10:17:14 +01:00
Pascal Vizeli
4702f8bd5e Add docs support to addon (#1438)
* Add docs support to addon

* Fix stale code
2020-01-20 10:01:22 +01:00
Pascal Vizeli
69959b2c97 Password reset (#1433)
* API to reset password

* Fix error handling

* fix lint

* fix typing

* fix await
2020-01-15 18:16:19 +01:00
Franck Nijhof
9d6f4f5392 Remove orangepi-prime, add odroid-n2 to add-on machine validator (#1432) 2020-01-13 16:25:18 +01:00
Pascal Vizeli
36b9a609bf Add dns reset to API (#1428) 2020-01-09 22:27:39 +01:00
Pascal Vizeli
36ae0c82b6 Revert "Update aiohttp to version 3.6.2 again (#1427)" (#1429)
This reverts commit e11011ee51.
2020-01-09 22:22:02 +01:00
Pascal Vizeli
e11011ee51 Update aiohttp to version 3.6.2 again (#1427) 2020-01-09 16:28:15 +01:00
Pascal Vizeli
9125211a57 Bump version 196 2020-01-09 16:25:07 +01:00
Pascal Vizeli
3a4ef6ceb3 Merge pull request #1426 from home-assistant/dev
Release 195
2020-01-09 16:24:00 +01:00
Pascal Vizeli
ca82993278 Update to Alpine3.11 2020-01-09 14:10:36 +00:00
Pascal Vizeli
0925af91e3 Fix snapshot HA / remove API password (#1425)
* Fix snapshot HA / remove API password

* fix lint

* Fix log

* cleanup API

* stale password handling

* fix lint
2020-01-09 14:35:37 +01:00
Franck Nijhof
80bc32243c Add configuration for Lock Threads on closed pull requests (#1424) 2020-01-09 11:40:23 +01:00
Pascal Vizeli
f0d232880d Allow big files on Ingress (#1423)
* Allow big files on Ingress

* Fix style

* Fix

* Cleanup

* Set to 16mb
2020-01-09 10:16:20 +01:00
Pascal Vizeli
7c790dbbd9 Fix issue generic (#1422)
* Fix issue on generic

* Fix style
2020-01-08 23:52:26 +01:00
Pascal Vizeli
899b17e992 Bump version 195 2020-01-07 21:10:40 +01:00
Pascal Vizeli
d1b4521290 Merge pull request #1421 from home-assistant/dev
Release 194
2020-01-07 21:09:50 +01:00
dependabot-preview[bot]
9bb4feef29 Bump pytest-timeout from 1.3.3 to 1.3.4 (#1418)
Bumps [pytest-timeout](https://github.com/pytest-dev/pytest-timeout) from 1.3.3 to 1.3.4.
- [Release notes](https://github.com/pytest-dev/pytest-timeout/releases)
- [Commits](https://github.com/pytest-dev/pytest-timeout/commits)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-01-07 16:07:07 +01:00
dependabot-preview[bot]
4bcdc98a31 Bump packaging from 19.2 to 20.0 (#1419)
Bumps [packaging](https://github.com/pypa/packaging) from 19.2 to 20.0.
- [Release notes](https://github.com/pypa/packaging/releases)
- [Changelog](https://github.com/pypa/packaging/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pypa/packaging/compare/19.2...20.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-01-07 16:06:56 +01:00
Pascal Vizeli
26f8c1df92 Don't reset dns container (#1417)
* Don't reset dns container

* Ignore more exception

* Fix handling
2020-01-06 15:06:57 +01:00
Matt White
a481ad73f3 Prefer admin defined DNS (#1399)
* Prefer admin defined DNS servers

* Remove space

* Update debug log

* Test for customisation of manual DNS servers.

* Warn that manual DNS will be removed on reset in v200

* Remove TODO

* Format with black

* Implement DNS fix for versions <194

* Insert missing docstring

* Add missing docstring

* Remove self.servers == DNS_SERVERS test
2020-01-06 14:22:46 +01:00
Pascal Vizeli
e4ac17fea6 Support Odroid N2 (#1416) 2020-01-06 14:08:30 +01:00
dependabot-preview[bot]
bcd940e95b Bump colorlog from 4.0.2 to 4.1.0 (#1412)
Bumps [colorlog](https://github.com/borntyping/python-colorlog) from 4.0.2 to 4.1.0.
- [Release notes](https://github.com/borntyping/python-colorlog/releases)
- [Commits](https://github.com/borntyping/python-colorlog/commits/v4.1.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-01-06 10:52:43 +01:00
Pascal Vizeli
5365aa4466 Offload rauc logic with partition handling (#1404)
* Offload rauc logic with partition handling

* Fix name

* Fix detection

* Add to API
2019-12-19 16:41:16 +01:00
Pascal Vizeli
a0d106529c Report error correct for rauc (#1403)
* Report error correct

* Use new style
2019-12-18 23:46:42 +01:00
dependabot-preview[bot]
bf1a9ec42d Bump pytest from 5.3.1 to 5.3.2 (#1400)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.3.1 to 5.3.2.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.3.1...5.3.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-12-16 13:34:19 +01:00
Pascal Vizeli
fc5d97562f Dns update (#1393)
* Improvements to DNS validator to include IPv6 (#1312)

* improvements to DNS validator to include IPv6

* fixed the DNS validators

* updated per suggestions

* Update const.py

* Update dns.py

* Update validate.py

* Update validate.py

* Update dns.py

* Update test_validate.py

* Update validate.py

* Cleanup

* Don't set default DNS server as default

* Remove update local resolver

* Fix lint
2019-12-05 21:52:55 +01:00
Issac
f5c171e44f Fix grammatical issue in log message (#1392) 2019-12-05 14:38:28 +01:00
dependabot-preview[bot]
a3c3f15806 Bump pytest from 5.3.0 to 5.3.1 (#1384)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.3.0 to 5.3.1.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.3.0...5.3.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-11-27 12:37:17 +01:00
dependabot-preview[bot]
ef58a219ec Bump pytest from 5.2.4 to 5.3.0 (#1379)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.2.4 to 5.3.0.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.2.4...5.3.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-11-20 12:23:23 +01:00
dependabot-preview[bot]
6708fe36e3 Bump uvloop from 0.13.0 to 0.14.0 (#1363)
Bumps [uvloop](https://github.com/MagicStack/uvloop) from 0.13.0 to 0.14.0.
- [Release notes](https://github.com/MagicStack/uvloop/releases)
- [Commits](https://github.com/MagicStack/uvloop/compare/v0.13.0...v0.14.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-11-18 12:20:21 +01:00
dependabot-preview[bot]
e02fa2824c Bump cchardet from 2.1.4 to 2.1.5 (#1376)
Bumps [cchardet](https://github.com/PyYoshi/cChardet) from 2.1.4 to 2.1.5.
- [Release notes](https://github.com/PyYoshi/cChardet/releases)
- [Changelog](https://github.com/PyYoshi/cChardet/blob/master/CHANGES.rst)
- [Commits](https://github.com/PyYoshi/cChardet/compare/2.1.4...2.1.5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-11-18 12:19:31 +01:00
dependabot-preview[bot]
a20f927082 Bump pytest from 5.2.2 to 5.2.4 (#1375)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.2.2 to 5.2.4.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.2.2...5.2.4)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-11-18 10:46:23 +01:00
dependabot-preview[bot]
6d71e3fe81 Bump pylint from 2.4.3 to 2.4.4 (#1372)
Bumps [pylint](https://github.com/PyCQA/pylint) from 2.4.3 to 2.4.4.
- [Release notes](https://github.com/PyCQA/pylint/releases)
- [Changelog](https://github.com/PyCQA/pylint/blob/master/ChangeLog)
- [Commits](https://github.com/PyCQA/pylint/compare/pylint-2.4.3...pylint-2.4.4)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-11-18 10:22:32 +01:00
dependabot-preview[bot]
4056fcd75d Bump gitpython from 3.0.4 to 3.0.5 (#1371)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.0.4 to 3.0.5.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.0.4...3.0.5)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-11-18 10:22:14 +01:00
Pascal Vizeli
1e723cf0e3 Bump version 194 2019-11-07 16:55:32 +01:00
Pascal Vizeli
ce3f670597 Merge pull request #1364 from home-assistant/dev
Hass.io 193
2019-11-07 16:54:21 +01:00
Pascal Vizeli
ce3d3d58ec Fix name 2019-11-07 15:12:42 +00:00
Pascal Vizeli
a92cab48e0 Support upload streaming (#1362)
* Support upload streaming

* Fix header

* Fix typing
2019-11-06 23:57:51 +01:00
dependabot-preview[bot]
ee76317392 Bump flake8 from 3.7.8 to 3.7.9 (#1352)
Bumps [flake8](https://gitlab.com/pycqa/flake8) from 3.7.8 to 3.7.9.
- [Release notes](https://gitlab.com/pycqa/flake8/tags)
- [Commits](https://gitlab.com/pycqa/flake8/compare/3.7.8...3.7.9)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-10-30 23:19:25 +01:00
Pascal Vizeli
380ca13be1 Pin Black (#1355)
* Pin black version

* fix devcontainer
2019-10-30 23:18:04 +01:00
Pascal Vizeli
93f4c5e207 Real optimize websocket proxy (#1351) 2019-10-28 17:57:03 +01:00
Pascal Vizeli
e438858da0 Better proxy handling (#1350) 2019-10-28 14:34:26 +01:00
Pascal Vizeli
428a4dd849 Bump version 193 2019-10-25 16:55:44 +02:00
Pascal Vizeli
39cc8aaa13 Merge pull request #1349 from home-assistant/dev
Release 192
2019-10-25 16:55:21 +02:00
dependabot-preview[bot]
39a62864de Bump pytest from 5.2.1 to 5.2.2 (#1348)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.2.1 to 5.2.2.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.2.1...5.2.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-10-25 16:46:45 +02:00
Franck Nijhof
71a162a871 Gracefully allow loading duplicate keys in secrets (#1347) 2019-10-25 11:44:03 +02:00
Franck Nijhof
05d7eff09a Fix secrets containing unsupported types (#1345)
* Fix secrets containing unsupported types

* Black

* Cleanup
2019-10-24 18:26:47 +02:00
Pascal Vizeli
7b8ad0782d Update Dockerfile 2019-10-23 16:06:48 +02:00
Pascal Vizeli
df3e9e3a5e Bump version 192 2019-10-23 16:02:42 +02:00
Pascal Vizeli
8cdc769ec8 Merge pull request #1343 from home-assistant/dev
Release 191
2019-10-23 15:59:42 +02:00
Pascal Vizeli
76e1304241 Downgrade aiohttp to 3.6.1 to fix lost connections (#1342) 2019-10-23 15:58:54 +02:00
Pascal Vizeli
eb9b1ff03d Bump version 191 2019-10-22 15:04:04 +02:00
Pascal Vizeli
b3b12d35fd Merge pull request #1341 from home-assistant/dev
Release 190
2019-10-22 14:57:25 +02:00
Pascal Vizeli
74485262e7 Prune network/interface on repair (#1340)
* Prune network/interface on repair

* Force disconnect
2019-10-22 14:30:14 +02:00
Pascal Vizeli
615e68b29b Add discovery support for Almond (#1339)
* Add discovery support for Almond

* Fix docstring
2019-10-22 13:39:46 +02:00
dependabot-preview[bot]
927b4695c9 Bump gitpython from 3.0.3 to 3.0.4 (#1338)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.0.3 to 3.0.4.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.0.3...3.0.4)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-10-22 13:31:14 +02:00
Pascal Vizeli
11811701d0 Add snapshot_exclude option (#1337)
* Add snapshot tar filter

* Add filter to add-on

* Fix bug

* Fix
2019-10-21 14:48:24 +02:00
Pascal Vizeli
05c8022db3 Check path on extractall (#1336)
* Check path on extractall

* code cleanup

* Add logger

* Fix issue

* Add tests
2019-10-21 12:23:00 +02:00
dependabot-preview[bot]
a9ebb147c5 Bump cryptography from 2.7 to 2.8 (#1332)
Bumps [cryptography](https://github.com/pyca/cryptography) from 2.7 to 2.8.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/2.7...2.8)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-10-18 14:54:27 +02:00
dependabot-preview[bot]
ba8ca4d9ee Bump pylint from 2.4.2 to 2.4.3 (#1334)
Bumps [pylint](https://github.com/PyCQA/pylint) from 2.4.2 to 2.4.3.
- [Release notes](https://github.com/PyCQA/pylint/releases)
- [Changelog](https://github.com/PyCQA/pylint/blob/master/ChangeLog)
- [Commits](https://github.com/PyCQA/pylint/compare/pylint-2.4.2...pylint-2.4.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-10-18 14:53:35 +02:00
dependabot-preview[bot]
3574df1385 Bump attrs from 19.1.0 to 19.3.0 (#1329)
* Bump attrs from 19.1.0 to 19.3.0

Bumps [attrs](https://github.com/python-attrs/attrs) from 19.1.0 to 19.3.0.
- [Release notes](https://github.com/python-attrs/attrs/releases)
- [Changelog](https://github.com/python-attrs/attrs/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/python-attrs/attrs/compare/19.1.0...19.3.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

* Fix attr Deprecations
2019-10-17 16:48:06 +02:00
dependabot-preview[bot]
b4497d231b Bump pytz from 2019.2 to 2019.3 (#1323)
Bumps [pytz](https://github.com/stub42/pytz) from 2019.2 to 2019.3.
- [Release notes](https://github.com/stub42/pytz/releases)
- [Commits](https://github.com/stub42/pytz/compare/release_2019.2...release_2019.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-10-14 11:40:50 +02:00
dependabot-preview[bot]
5aa9b0245a Bump pytest from 5.2.0 to 5.2.1 (#1324)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.2.0 to 5.2.1.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.2.0...5.2.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-10-14 11:33:59 +02:00
dependabot-preview[bot]
4c72c3aafc Bump aiohttp from 3.6.1 to 3.6.2 (#1325)
Bumps [aiohttp](https://github.com/aio-libs/aiohttp) from 3.6.1 to 3.6.2.
- [Release notes](https://github.com/aio-libs/aiohttp/releases)
- [Changelog](https://github.com/aio-libs/aiohttp/blob/master/CHANGES.rst)
- [Commits](https://github.com/aio-libs/aiohttp/compare/v3.6.1...v3.6.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-10-14 11:32:45 +02:00
dependabot-preview[bot]
bf4f40f991 Bump docker from 4.0.2 to 4.1.0 (#1321)
Bumps [docker](https://github.com/docker/docker-py) from 4.0.2 to 4.1.0.
- [Release notes](https://github.com/docker/docker-py/releases)
- [Commits](https://github.com/docker/docker-py/compare/4.0.2...4.1.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-10-14 11:31:03 +02:00
Timmo
603334f4f3 Add support for Home Panel discovery (#1327) 2019-10-14 11:30:18 +02:00
dependabot-preview[bot]
46548af165 Bump gitpython from 3.0.2 to 3.0.3 (#1319)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.0.2 to 3.0.3.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.0.2...3.0.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-10-03 13:06:20 +02:00
dependabot-preview[bot]
8ef32b40c8 Bump pylint from 2.4.1 to 2.4.2 (#1314)
Bumps [pylint](https://github.com/PyCQA/pylint) from 2.4.1 to 2.4.2.
- [Release notes](https://github.com/PyCQA/pylint/releases)
- [Changelog](https://github.com/PyCQA/pylint/blob/master/ChangeLog)
- [Commits](https://github.com/PyCQA/pylint/compare/pylint-2.4.1...pylint-2.4.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-30 22:21:00 +02:00
dependabot-preview[bot]
fb25377087 Bump pytest from 5.1.3 to 5.2.0 (#1315)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.1.3 to 5.2.0.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.1.3...5.2.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-30 22:15:12 +02:00
Pascal Vizeli
a75fd2d07e Update devcontainer.json 2019-09-30 11:01:59 +02:00
Pascal Vizeli
e30f39e97e Update devcontainer.json 2019-09-30 11:01:35 +02:00
dependabot-preview[bot]
4818ad7465 Bump pylint from 2.4.0 to 2.4.1 (#1308)
Bumps [pylint](https://github.com/PyCQA/pylint) from 2.4.0 to 2.4.1.
- [Release notes](https://github.com/PyCQA/pylint/releases)
- [Changelog](https://github.com/PyCQA/pylint/blob/master/ChangeLog)
- [Commits](https://github.com/PyCQA/pylint/compare/pylint-2.4.0...pylint-2.4.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-25 18:08:33 +02:00
dependabot-preview[bot]
5e4e9740c7 Bump pylint from 2.3.1 to 2.4.0 (#1307)
* Bump pylint from 2.3.1 to 2.4.0

Bumps [pylint](https://github.com/PyCQA/pylint) from 2.3.1 to 2.4.0.
- [Release notes](https://github.com/PyCQA/pylint/releases)
- [Changelog](https://github.com/PyCQA/pylint/blob/master/ChangeLog)
- [Commits](https://github.com/PyCQA/pylint/compare/pylint-2.3.1...pylint-2.4.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

* Update __main__.py

* Update bootstrap.py

* Update homeassistant.py

* Update __init__.py
2019-09-25 09:41:16 +02:00
Pascal Vizeli
d4e41dbf80 Bump version 190 2019-09-24 15:25:28 +02:00
Pascal Vizeli
cea1a1a15f Merge pull request #1306 from home-assistant/dev
Release 189
2019-09-24 15:24:27 +02:00
dependabot-preview[bot]
c2700b14dc Bump packaging from 19.1 to 19.2 (#1305)
Bumps [packaging](https://github.com/pypa/packaging) from 19.1 to 19.2.
- [Release notes](https://github.com/pypa/packaging/releases)
- [Changelog](https://github.com/pypa/packaging/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pypa/packaging/compare/19.1...19.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-24 10:31:56 +02:00
dependabot-preview[bot]
07d27170db Bump pytest from 5.1.2 to 5.1.3 (#1303)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.1.2 to 5.1.3.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.1.2...5.1.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-24 10:31:13 +02:00
Pascal Vizeli
8eb8c07df6 Update uvloop 0.13.0 (#1302) 2019-09-23 23:00:57 +02:00
Pascal Vizeli
7bee6f884c Update aiohttp 3.6.1 (#1301) 2019-09-23 22:45:02 +02:00
Franck Nijhof
78dd20e314 Fixes accidental string concatenation in classifiers list (#1300) 2019-09-23 12:23:57 +02:00
Pascal Vizeli
2a011b6448 Fix typo to validate list (#1298)
* Fix typo to validate list

* Fix lint

* Add Typo
2019-09-20 17:28:23 +02:00
Pascal Vizeli
5c90370ec8 Bump version 189 2019-09-15 15:08:12 +02:00
Pascal Vizeli
120465b88d Merge pull request #1294 from home-assistant/dev
Release 188
2019-09-15 15:07:39 +02:00
Pascal Vizeli
c77292439a Fix invalid secrets (#1293)
* Fix invalid secrets format

* Fix style
2019-09-15 15:06:22 +02:00
Pascal Vizeli
0a0209f81a Bump version 188 2019-09-12 23:32:20 +02:00
Pascal Vizeli
69a7ed8a5c Merge pull request #1291 from home-assistant/dev
Release 187
2019-09-12 23:30:53 +02:00
Pascal Vizeli
8df35ab488 Fix detection of HA container / image (#1290) 2019-09-12 23:28:55 +02:00
Pascal Vizeli
a12567d0a8 Update secrets handling (#1289)
* Update secrets handling

* Remove start pre_check

* fix lint

* remove tasker
2019-09-12 23:16:56 +02:00
Pascal Vizeli
64fe190119 Bump version 187 2019-09-11 18:29:24 +02:00
Pascal Vizeli
e3ede66943 Merge pull request #1287 from home-assistant/dev
Release 186
2019-09-11 18:26:22 +02:00
Pascal Vizeli
2672b800d4 DNS fallback to docker internal one (#1286)
* DNS fallback to docker internal one

* Fix log

* Fix style

* Fix startup handling
2019-09-11 17:54:16 +02:00
Pascal Vizeli
c60d4bda92 Check supervisor docker permission (#1285)
* Check supervisor docker permission

* Update log message
2019-09-11 17:47:49 +02:00
Pascal Vizeli
db9d0f2639 Fix lint (#1284) 2019-09-11 16:37:49 +02:00
Pascal Vizeli
02d4045ec3 Add secrets support for options (#1283)
* Add secrets API

* Don't expose secrets
2019-09-11 16:29:34 +02:00
Pascal Vizeli
a308ea6927 Update Dockerfile 2019-09-05 14:20:35 +02:00
Pascal Vizeli
edc5e5e812 Update Dockerfile 2019-09-05 12:41:42 +02:00
dependabot-preview[bot]
23b65cb479 Bump pytest from 5.1.1 to 5.1.2 (#1278)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.1.1 to 5.1.2.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.1.1...5.1.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-09-02 23:07:11 +02:00
Pascal Vizeli
e5eabd2143 Fix typing warning / hardware (#1276) 2019-09-02 15:54:37 +02:00
Pascal Vizeli
b0dd043975 Fix typing warning / hardware (#1277) 2019-09-02 15:45:31 +02:00
Pascal Vizeli
435a1096ed Cleanup debug gdbus output (#1275) 2019-09-02 15:08:26 +02:00
Pascal Vizeli
21a9084ca0 Bump version 186 2019-09-02 14:39:56 +02:00
Pascal Vizeli
10d9135d86 Merge pull request #1274 from home-assistant/dev
Release 185
2019-09-02 14:39:17 +02:00
Pascal Vizeli
272d8b29f3 Fix version handling with nightly (#1273)
* Fix version handling with nightly

* fix lint
2019-09-02 14:37:59 +02:00
Pascal Vizeli
3d665b9eec Support for udev device trigger (#1272) 2019-09-02 14:07:09 +02:00
Pascal Vizeli
c563f484c9 Add support for udev trigger 2019-09-02 11:28:49 +00:00
Pascal Vizeli
38268ea4ea Bump version to 185 2019-08-26 10:04:36 +02:00
Pascal Vizeli
c1ad64cddf Merge pull request #1264 from home-assistant/dev
Release 184
2019-08-26 10:03:53 +02:00
Pascal Vizeli
b898cd2a3a Preserve ordering of locals (#1263)
* Preserve ordering of locals

* fix lint
2019-08-26 09:45:10 +02:00
Pascal Vizeli
937b31d845 Bump version 184 2019-08-23 14:22:47 +02:00
Pascal Vizeli
e4e655493b Merge pull request #1259 from home-assistant/dev
Release 183
2019-08-23 14:21:58 +02:00
Pascal Vizeli
387d2dcc2e Add support for gvariant annotations (#1258) 2019-08-23 13:41:17 +02:00
Pascal Vizeli
8abe33d48a Bump version 183 2019-08-22 18:58:02 +02:00
Pascal Vizeli
860442d5c4 Merge pull request #1256 from home-assistant/dev
Release 182
2019-08-22 18:57:38 +02:00
Pascal Vizeli
ce5183ce16 Add support to read Host DNS (#1255)
* Add support to read Host DNS

* Include properties

* Improve host info handling

* Add API

* Better abstraction

* Change prio list

* Address lint

* fix get properties

* Fix nameserver list

* Small cleanups

* Bit more stability

* cleanup
2019-08-22 18:01:49 +02:00
dependabot-preview[bot]
3e69b04b86 Bump gitpython from 3.0.1 to 3.0.2 (#1254)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.0.1 to 3.0.2.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.0.1...3.0.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-08-22 16:20:47 +02:00
Pascal Vizeli
8b9cd4f122 Improve handling with nested objects (#1253) 2019-08-22 14:24:50 +02:00
Pascal Vizeli
c0e3ccdb83 Improve gdbus error handling (#1252)
* Improve gdbus error handling

* Fix logging type

* Detect no dbus

* Fix issue with complex

* Update hassio/dbus/__init__.py

Co-Authored-By: Franck Nijhof <frenck@frenck.nl>

* Update hassio/dbus/hostname.py

Co-Authored-By: Franck Nijhof <frenck@frenck.nl>

* Update hassio/dbus/rauc.py

Co-Authored-By: Franck Nijhof <frenck@frenck.nl>

* Update hassio/dbus/systemd.py

Co-Authored-By: Franck Nijhof <frenck@frenck.nl>

* Fix black
2019-08-22 12:48:02 +02:00
dependabot-preview[bot]
e8cc85c487 Bump pytest from 5.1.0 to 5.1.1 (#1250)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.1.0 to 5.1.1.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.1.0...5.1.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-08-21 23:41:16 +02:00
Pascal Vizeli
b3eff41692 Update devcontainer.json 2019-08-20 17:51:27 +02:00
Pascal Vizeli
1ea63f185c Bump version 182 2019-08-18 21:08:01 +02:00
Pascal Vizeli
a513d5c09a Merge pull request #1247 from home-assistant/dev
Release 181
2019-08-18 21:07:21 +02:00
Pascal Vizeli
fb8216c102 Fix AAAA resolv for nginx (#1246) 2019-08-18 21:05:42 +02:00
Pascal Vizeli
4f381d01df Log coredns errors (#1245) 2019-08-18 17:21:46 +02:00
Pascal Vizeli
de3382226e Update setting on startup (#1244)
* Update setting on startup

* Fix

* fix exception

* Cleanup handling
2019-08-18 17:11:42 +02:00
Pascal Vizeli
77be830b72 Bump version 181 2019-08-18 12:00:31 +02:00
Pascal Vizeli
09c0e1320f Merge pull request #1243 from home-assistant/dev
Release 180
2019-08-18 12:00:01 +02:00
Franck Nijhof
cc4ee59542 Replace Google DNS by Quad9, prefer CloudFlare (#1235) 2019-08-18 11:48:29 +02:00
Pascal Vizeli
1f448744f3 Add restart function / options change (#1242) 2019-08-18 11:46:23 +02:00
Franck Nijhof
ee2c257057 Adjust coredns do not forward local.hass.io (#1237) 2019-08-18 11:08:34 +02:00
Franck Nijhof
be8439d4ac Add localhost to hosts file (#1240) 2019-08-18 11:07:23 +02:00
Franck Nijhof
981f2b193c Adjust coredns to use upstream fowarding server in order (#1238) 2019-08-18 11:06:17 +02:00
Pascal Vizeli
39087e09ce Bump version 180 2019-08-16 20:33:56 +02:00
Pascal Vizeli
59960efb9c Merge pull request #1229 from home-assistant/dev
Release 179
2019-08-16 20:32:34 +02:00
Pascal Vizeli
5a53bb5981 Use hosts as list (#1228)
* Use hosts as list

* Fix

* Clean style

* Fix list remove

* hide warning
2019-08-16 20:29:10 +02:00
dependabot-preview[bot]
a67fe69cbb Bump pytest from 5.0.1 to 5.1.0 (#1227)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 5.0.1 to 5.1.0.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/5.0.1...5.1.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-08-16 17:59:15 +02:00
Pascal Vizeli
9ce2b0765f Bump version 179 2019-08-16 13:27:51 +02:00
Pascal Vizeli
2e53a48504 Merge pull request #1224 from home-assistant/dev
Release 178
2019-08-16 13:26:45 +02:00
Pascal Vizeli
8e4db0c3ec Stripe resolv (#1226) 2019-08-16 13:22:07 +02:00
Pascal Vizeli
4072b06faf Fix issue on isntalled add-ons (#1225) 2019-08-16 13:12:39 +02:00
Pascal Vizeli
a2cf7ece70 Change handling with host files (#1223) 2019-08-16 12:47:32 +02:00
Pascal Vizeli
734fe3afde Bump version 178 2019-08-16 00:15:05 +02:00
Pascal Vizeli
7f3bc91c1d Merge pull request #1222 from home-assistant/dev
Release 177
2019-08-16 00:13:51 +02:00
Pascal Vizeli
9c2c95757d Validate dns better (#1221) 2019-08-15 23:48:14 +02:00
Franck Nijhof
b5ed6c586a Cleanup ingress panel on add-on uninstall (#1220)
* Cleanup ingress panel on add-on uninstall

* Update __init__.py
2019-08-15 23:05:03 +02:00
Franck Nijhof
35033d1f76 Allow manager role to access DNS API (#1219) 2019-08-15 22:38:34 +02:00
Pascal Vizeli
9e41d0c5b0 Bump version 177 2019-08-15 14:51:28 +02:00
Pascal Vizeli
62e92fada9 Merge pull request #1218 from home-assistant/dev
Release 176
2019-08-15 14:50:55 +02:00
dependabot-preview[bot]
ae0a1a657f Bump gitpython from 3.0.0 to 3.0.1 (#1216)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 3.0.0 to 3.0.1.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/3.0.0...3.0.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-08-15 14:46:16 +02:00
Pascal Vizeli
81e511ba8e Fix spell 2019-08-15 12:42:34 +00:00
Pascal Vizeli
d89cb91c8c Revert "Call update of resolv later (#1215)" (#1217)
This reverts commit dc31b6e6fe.
2019-08-15 14:42:05 +02:00
Pascal Vizeli
dc31b6e6fe Call update of resolv later (#1215) 2019-08-15 13:57:44 +02:00
Pascal Vizeli
930a32de1a Fix latest issue (#1214)
* Fix latest issue

* Use also update now

* Fix style
2019-08-15 12:42:21 +02:00
Pascal Vizeli
e40f2ed8e3 Bump version 176 2019-08-15 11:36:47 +02:00
Pascal Vizeli
abbd3d1078 Merge pull request #1213 from home-assistant/dev
Release 175
2019-08-15 11:36:06 +02:00
Pascal Vizeli
63c9948456 Add CoreDNS to update process (#1212) 2019-08-15 11:05:08 +02:00
Pascal Vizeli
b6c81d779a Use own coredns for supervisor 2019-08-15 08:51:42 +00:00
Pascal Vizeli
2480c83169 Fix socat command (#1211) 2019-08-15 10:17:41 +02:00
Pascal Vizeli
334cc66cf6 Bump Version 175 2019-08-14 15:39:44 +02:00
Pascal Vizeli
3cf189ad94 Merge pull request #1209 from home-assistant/dev
Release 174
2019-08-14 15:38:57 +02:00
dependabot-preview[bot]
6ffb94a0f5 Bump ptvsd from 4.3.1 to 4.3.2 (#1207)
Bumps [ptvsd](https://github.com/Microsoft/ptvsd) from 4.3.1 to 4.3.2.
- [Release notes](https://github.com/Microsoft/ptvsd/releases)
- [Commits](https://github.com/Microsoft/ptvsd/compare/v4.3.1...v4.3.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-08-14 14:35:43 +02:00
Pascal Vizeli
3593826441 Fix issue with windows dev env 2019-08-14 10:37:39 +00:00
Pascal Vizeli
0a0a62f238 Addon provide his own udev support (#1206)
* Addon provide his own udev support

* upgrade logger
2019-08-14 12:29:00 +02:00
Pascal Vizeli
41ce9913d2 Stats percent (#1205)
* Fix stats and add Memory percent

* Fix tasks

* round percent
2019-08-14 10:47:11 +02:00
Pascal Vizeli
b77c42384d Add DNS to add-on (#1204) 2019-08-14 09:53:03 +02:00
Pascal Vizeli
138bb12f98 Add debug output to gdbus (#1203) 2019-08-13 21:25:04 +02:00
Pascal Vizeli
4fe2859f4e Rename scripts folder (#1202)
* Rename script folder

* Rename scripts
2019-08-13 14:39:32 +02:00
dependabot-preview[bot]
0768b2b4bc Bump ptvsd from 4.3.0 to 4.3.1 (#1200)
Bumps [ptvsd](https://github.com/Microsoft/ptvsd) from 4.3.0 to 4.3.1.
- [Release notes](https://github.com/Microsoft/ptvsd/releases)
- [Commits](https://github.com/Microsoft/ptvsd/compare/v4.3.0...v4.3.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-08-13 14:35:41 +02:00
dependabot-preview[bot]
e6f1772a93 Bump gitpython from 2.1.13 to 3.0.0 (#1199)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 2.1.13 to 3.0.0.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/2.1.13...3.0.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-08-13 14:35:15 +02:00
dependabot-preview[bot]
5374b2b3b9 Bump voluptuous from 0.11.5 to 0.11.7 (#1201)
Bumps [voluptuous](https://github.com/alecthomas/voluptuous) from 0.11.5 to 0.11.7.
- [Release notes](https://github.com/alecthomas/voluptuous/releases)
- [Changelog](https://github.com/alecthomas/voluptuous/blob/master/CHANGELOG.md)
- [Commits](https://github.com/alecthomas/voluptuous/commits)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-08-13 14:29:33 +02:00
Pascal Vizeli
1196788856 Add CoreDNS as DNS backend (#1195)
* Add CoreDNS / DNS configuration

* Support get version

* add version

* add coresys

* Add more logic

* move forwareder into dns

* Setup docker inside

* add docker to env

* Add more function

* more interface

* Update hosts template

* Add DNS folder

* Fix issues

* Add more logic

* Add handling for hosts

* Fix setting

* fix lint

* Fix some issues

* Fix issue

* Run with no cache

* Fix issue on validate

* Fix bug

* Allow to jump into dev mode

* Fix permission

* Fix issue

* Add dns search

* Add watchdog

* Fix set issues

* add API description

* Add API endpoint

* Add CLI support

* Fix logs + add hostname

* Add/remove DNS entry

* Fix attribute

* Fix style

* Better shutdown

* Remove ha from network mapping

* Add more options

* Fix env shutdown

* Add support for new repair function

* Start coreDNS faster after restart

* remove options

* Fix ha fix
2019-08-13 14:20:42 +02:00
Pascal Vizeli
9f3f47eb80 Bump version 174 2019-08-11 09:59:48 +02:00
Pascal Vizeli
1a90a478f2 Merge pull request #1197 from home-assistant/dev
Release 173
2019-08-11 09:39:17 +02:00
Pascal Vizeli
ee773f3b63 Fix hanging landingpage (#1196) 2019-08-11 09:05:47 +02:00
Pascal Vizeli
5ffc27f60c Bump version 173 2019-08-08 23:24:11 +02:00
Pascal Vizeli
4c13dfb43c Merge pull request #1194 from home-assistant/dev
Release 172
2019-08-08 23:21:26 +02:00
Pascal Vizeli
bc099f0d81 Fix Version detection with exists container (#1193) 2019-08-08 23:20:26 +02:00
Pascal Vizeli
b26dd0af19 Add better log output for repair (#1191) 2019-08-08 10:14:13 +02:00
Pascal Vizeli
0dee5bd763 Fix black formating args 2019-08-08 10:13:44 +02:00
Pascal Vizeli
0765387ad8 Bump version 172 2019-08-07 18:18:09 +02:00
Pascal Vizeli
a07517bd3c Merge pull request #1190 from home-assistant/dev
Release 171
2019-08-07 18:17:30 +02:00
Pascal Vizeli
e5f0d80d96 Start API server before he beform a self update (#1189) 2019-08-07 18:03:56 +02:00
Pascal Vizeli
2fc5e3b7d9 Repair / fixup docker overlayfs issues (#1170)
* Add a repair modus

* Add repair to add-ons

* repair to cli

* Add API call

* fix sync call

* Clean all images

* Fix repair

* Fix supervisor

* Add new function to core

* fix tagging

* better style

* use retag

* new retag function

* Fix lint

* Fix import export
2019-08-07 17:26:32 +02:00
Pascal Vizeli
778bc46848 Don't relay on latest with HA/Addons (#1175)
* Don't relay on latest with HA/Addons

* Fix latest on install

* Revert some options

* Fix attach

* migrate to new version handling

* Fix thread

* Fix is running

* Allow wait

* debug code

* Fix debug value

* Fix list

* Fix regex

* Some better log output

* Fix logic

* Improve cleanup handling

* Fix bug

* Cleanup old code

* Improve version handling

* Fix the way to attach
2019-08-07 09:51:27 +02:00
Pascal Vizeli
882586b246 Fix time adjustments on latest boot (#1187)
* Fix time adjustments on latest boot

* Fix spell
2019-08-06 09:24:22 +02:00
dependabot-preview[bot]
b7c07a2555 Bump pytz from 2019.1 to 2019.2 (#1184)
Bumps [pytz](https://github.com/stub42/pytz) from 2019.1 to 2019.2.
- [Release notes](https://github.com/stub42/pytz/releases)
- [Commits](https://github.com/stub42/pytz/compare/release_2019.1...release_2019.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-08-02 10:32:04 +02:00
dependabot-preview[bot]
814b504fa9 Bump ptvsd from 4.2.10 to 4.3.0 (#1179)
Bumps [ptvsd](https://github.com/Microsoft/ptvsd) from 4.2.10 to 4.3.0.
- [Release notes](https://github.com/Microsoft/ptvsd/releases)
- [Commits](https://github.com/Microsoft/ptvsd/compare/v4.2.10...v4.3.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-07-29 17:01:28 +02:00
dependabot-preview[bot]
7ae430e7a8 Bump gitpython from 2.1.12 to 2.1.13 (#1178)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 2.1.12 to 2.1.13.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/2.1.12...2.1.13)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-07-29 14:53:54 +02:00
dependabot-preview[bot]
0e7e95ba20 Bump gitpython from 2.1.11 to 2.1.12 (#1171)
Bumps [gitpython](https://github.com/gitpython-developers/GitPython) from 2.1.11 to 2.1.12.
- [Release notes](https://github.com/gitpython-developers/GitPython/releases)
- [Changelog](https://github.com/gitpython-developers/GitPython/blob/master/CHANGES)
- [Commits](https://github.com/gitpython-developers/GitPython/compare/2.1.11...2.1.12)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-07-22 14:18:11 +02:00
Pascal Vizeli
e577d8acb2 Bump version 171 2019-07-19 11:49:00 +02:00
Pascal Vizeli
0a76ab5054 Merge pull request #1168 from home-assistant/dev
Release 170
2019-07-19 11:48:28 +02:00
Pascal Vizeli
03c5596e04 Fix machine version (#1167) 2019-07-19 11:47:55 +02:00
Pascal Vizeli
3af4e14e83 Bump version 170 2019-07-16 12:36:05 +02:00
Pascal Vizeli
7c8cf57820 Merge pull request #1164 from home-assistant/dev
Release 169
2019-07-16 12:35:10 +02:00
Pascal Vizeli
8d84a8a62e Update panel & support panel on devcontainer (#1163)
* Update panel & support panel on devcontainer

* small cleanups

* small size
2019-07-16 12:23:03 +02:00
Pascal Vizeli
08c45060bd Add support for RPi4 (#1162) 2019-07-16 10:33:56 +02:00
Pascal Vizeli
7ca8d2811b Update URL for version file (#1161) 2019-07-16 10:26:59 +02:00
Pascal Vizeli
bb6898b032 Update azure-pipelines.yml for Azure Pipelines 2019-07-12 09:57:55 +02:00
Pascal Vizeli
cd86c6814e Update azure-pipelines.yml for Azure Pipelines 2019-07-12 09:42:55 +02:00
Pascal Vizeli
b67e116650 Update azure-pipelines.yml 2019-07-12 09:41:40 +02:00
Pascal Vizeli
57ce411fb6 Update azure-pipelines.yml 2019-07-11 22:11:37 +02:00
Pascal Vizeli
85ed4d9e8d Update Dockerfile 2019-07-11 19:25:07 +02:00
dependabot-preview[bot]
ccb39da569 Bump flake8 from 3.7.7 to 3.7.8 (#1154)
Bumps [flake8](https://gitlab.com/pycqa/flake8) from 3.7.7 to 3.7.8.
- [Release notes](https://gitlab.com/pycqa/flake8/tags)
- [Commits](https://gitlab.com/pycqa/flake8/compare/3.7.7...3.7.8)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-07-09 14:05:43 +02:00
Pascal Vizeli
dd7ba64d32 Bump version 169 2019-07-08 16:03:59 +02:00
Pascal Vizeli
de3edb1654 Merge pull request #1153 from home-assistant/dev
Release 168
2019-07-08 16:02:39 +02:00
dependabot-preview[bot]
d262151727 Bump pytest from 4.6.3 to 5.0.1 (#1148)
* Bump pytest from 4.6.3 to 5.0.1

Bumps [pytest](https://github.com/pytest-dev/pytest) from 4.6.3 to 5.0.1.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/4.6.3...5.0.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>

* Update tox.ini
2019-07-06 18:07:15 +02:00
Pascal Vizeli
a37c90af96 Forward Params (#1150) 2019-07-06 18:06:39 +02:00
Pascal Vizeli
0a3a752b4c Add timezone to info call (#1146) 2019-07-04 18:20:46 +02:00
Pascal Vizeli
0a34f427f8 Fix error on save special permission (#1145) 2019-07-04 17:30:42 +02:00
Pascal Vizeli
157740e374 Update devcontainer.json 2019-07-04 17:28:50 +02:00
Pascal Vizeli
b0e994f3f5 Bump version 168 2019-06-25 17:38:57 +02:00
Pascal Vizeli
f374852801 Merge pull request #1139 from home-assistant/dev
Release 167
2019-06-25 17:34:42 +02:00
Pascal Vizeli
709f034f2e New TimeZone handling (#1138)
* Remove function to get TZ from config file

* Readd old timezone handling

* Fix tests
2019-06-25 17:09:14 +02:00
Pascal Vizeli
6d6deb8c66 Cleanup udev handling (#1137)
* Cleanup udev handling

* Update hardware.py
2019-06-25 16:15:02 +02:00
Pascal Vizeli
5771b417bc sort import 2019-06-25 12:54:45 +00:00
Pascal Vizeli
51efcefdab Compile only hassio 2019-06-24 23:21:15 +00:00
Pascal Vizeli
d31ab5139d compile all 2019-06-24 23:09:08 +00:00
Pascal Vizeli
ce18183daa Allow update discovery messages (#1136)
* Allow update discovery messages

* Update __init__.py

* Update __init__.py

* Update __init__.py

* fix lint

* Fix style
2019-06-24 23:29:42 +02:00
Pascal Vizeli
b8b73cf880 remove diff wheels build 2019-06-24 19:16:26 +02:00
Pascal Vizeli
5291e6c1f3 Use multistage 2019-06-24 19:04:52 +02:00
Pascal Vizeli
626a9f06c4 Update to alpine 3.10 (#1135) 2019-06-24 18:49:43 +02:00
Pascal Vizeli
72338eb5b8 Add devcontainer support (#1134) 2019-06-24 14:48:10 +02:00
Jakub
7bd77c6e99 Append devlinks to serial dev_list (#1131)
* append devlinks to dev_list

* replace eudev-libs with eudev

* include only devlinks starting with /dev/serial/by-id

* add missing package, move udev init to entry.sh

* fix mode on entry.sh

* Update homeassistant.py

* Update homeassistant.py
2019-06-24 09:53:54 +02:00
dependabot-preview[bot]
69151b962a Bump pytest from 4.6.2 to 4.6.3 (#1125)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 4.6.2 to 4.6.3.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/4.6.2...4.6.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-06-21 09:50:42 +02:00
dependabot-preview[bot]
86305d4fe4 Bump docker from 4.0.1 to 4.0.2 (#1133)
Bumps [docker](https://github.com/docker/docker-py) from 4.0.1 to 4.0.2.
- [Release notes](https://github.com/docker/docker-py/releases)
- [Commits](https://github.com/docker/docker-py/compare/4.0.1...4.0.2)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-06-21 09:50:28 +02:00
Pascal Vizeli
d5c3850a3f Don't break on supervisor update (#1118)
* Don't break on supervisor update

* Update core.py

* Fix lint
2019-06-06 10:57:36 +02:00
Pascal Vizeli
3e645b6175 Fix timeout on check port (#1116) 2019-06-05 17:49:05 +02:00
Pascal Vizeli
89dc78bc05 Bump version 167 2019-06-05 17:10:44 +02:00
Pascal Vizeli
164c403d05 Merge pull request #1115 from home-assistant/dev
Release 166
2019-06-05 17:10:14 +02:00
Pascal Vizeli
5e8007453f detect native arch (#1114) 2019-06-05 16:59:43 +02:00
Pascal Vizeli
0a0d97b084 Support pip progress for HA 0.94 (#1113)
* Support pip progress for HA 0.94

* fix black

* add tests

* add test for adguard

* Fix lint
2019-06-05 14:46:03 +02:00
dependabot-preview[bot]
eb604ed92d Bump pytest from 4.6.1 to 4.6.2 (#1112)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 4.6.1 to 4.6.2.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/4.6.1...4.6.2)
2019-06-04 23:47:35 +02:00
dependabot-preview[bot]
c47828dbaa Bump pytest from 4.5.0 to 4.6.1 (#1110)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 4.5.0 to 4.6.1.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/4.5.0...4.6.1)
2019-06-04 14:43:20 +02:00
Pascal Vizeli
ea437dc745 Update azure-pipelines.yml for Azure Pipelines 2019-06-02 14:12:45 +02:00
Franck Nijhof
c16a208b39 Support for AdGuard Home discovery (#1107)
* Support for AdGuard Home discovery

* 👕 Darkened the sky
2019-06-02 07:47:12 +02:00
dependabot-preview[bot]
55d803b2a0 Bump cryptography from 2.6.1 to 2.7 (#1108)
Bumps [cryptography](https://github.com/pyca/cryptography) from 2.6.1 to 2.7.
- [Release notes](https://github.com/pyca/cryptography/releases)
- [Changelog](https://github.com/pyca/cryptography/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pyca/cryptography/compare/2.6.1...2.7)
2019-05-31 17:55:16 +02:00
Pascal Vizeli
611f6f2829 Don't follow requests itself (#1106)
* Don't follow requests itself

* Fix black lint
2019-05-31 13:53:46 +02:00
Pascal Vizeli
b94df76731 Update azure-pipelines.yml for Azure Pipelines 2019-05-31 12:42:37 +02:00
Pascal Vizeli
218619e7f0 Bump version 166 2019-05-31 12:36:06 +02:00
Pascal Vizeli
273eed901a Merge pull request #1105 from home-assistant/dev
Release 165
2019-05-31 12:35:34 +02:00
Pascal Vizeli
8ea712a937 Fix error on comparson (#1104) 2019-05-31 11:46:28 +02:00
Pascal Vizeli
658449a7a0 Update azure-pipelines.yml for Azure Pipelines 2019-05-30 17:43:30 +02:00
Pascal Vizeli
968c471591 Update azure-pipelines.yml for Azure Pipelines 2019-05-30 17:25:47 +02:00
Pascal Vizeli
b4665f3907 Add black support (#1101) 2019-05-27 12:35:06 +02:00
dependabot[bot]
496cee1ec4 Bump ptvsd from 4.2.9 to 4.2.10 (#1096)
Bumps [ptvsd](https://github.com/Microsoft/ptvsd) from 4.2.9 to 4.2.10.
- [Release notes](https://github.com/Microsoft/ptvsd/releases)
- [Commits](https://github.com/Microsoft/ptvsd/compare/v4.2.9...v4.2.10)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-05-22 14:29:57 +02:00
dependabot[bot]
0f8c80f3ba Bump docker from 3.7.2 to 4.0.1 (#1093)
Bumps [docker](https://github.com/docker/docker-py) from 3.7.2 to 4.0.1.
- [Release notes](https://github.com/docker/docker-py/releases)
- [Commits](https://github.com/docker/docker-py/compare/3.7.2...4.0.1)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-05-21 12:07:01 +02:00
Pascal Vizeli
6c28f82239 Bump version 165 2019-05-18 22:39:43 +02:00
Pascal Vizeli
def32abb57 Merge pull request #1090 from home-assistant/dev
Release 164
2019-05-18 22:37:47 +02:00
Pascal Vizeli
f57a241b9e Panel search function (#1089) 2019-05-18 22:31:07 +02:00
Pascal Vizeli
11a7e8b15d Fix error with repository without repository.json (#1088) 2019-05-18 22:17:32 +02:00
Pascal Vizeli
fa4f7697b7 Update azure-pipelines.yml for Azure Pipelines 2019-05-16 09:42:55 +02:00
dependabot[bot]
6098b7de8e Bump pytest from 4.4.2 to 4.5.0 (#1083)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 4.4.2 to 4.5.0.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/4.4.2...4.5.0)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-05-13 23:03:55 +02:00
dependabot[bot]
0a382ce54d Bump ptvsd from 4.2.8 to 4.2.9 (#1081)
Bumps [ptvsd](https://github.com/Microsoft/ptvsd) from 4.2.8 to 4.2.9.
- [Release notes](https://github.com/Microsoft/ptvsd/releases)
- [Commits](https://github.com/Microsoft/ptvsd/compare/v4.2.8...v4.2.9)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-05-10 15:32:29 +02:00
dependabot[bot]
dd53aaa30c Bump pytest from 4.4.1 to 4.4.2 (#1080)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 4.4.1 to 4.4.2.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/4.4.1...4.4.2)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-05-09 14:11:58 +02:00
Pascal Vizeli
31e175a15a Bump version 164 2019-05-09 12:07:57 +02:00
Pascal Vizeli
4c80727bcc Merge pull request #1079 from home-assistant/dev
Release 163
2019-05-09 12:07:22 +02:00
Pascal Vizeli
b2c3157361 Fix device bug (#1078) 2019-05-09 11:41:37 +02:00
Pascal Vizeli
dc4f38ebd0 Update azure-pipelines.yml for Azure Pipelines 2019-05-08 23:46:08 +02:00
Pascal Vizeli
7c9437c6ee Bugfixes / increase Home Assistant timeout (#1077)
* Fix small bugs with new store

* Add more timeout to homeassistant
2019-05-08 22:37:05 +02:00
Pascal Vizeli
9ce9e10dfd WIP: Split add-on store logic (#1067)
* Split add-on store logic

* finish data model

* Cleanup models

* Cleanup imports

* split up store addons

* More cleanup

* Go to stable

* Fix layout

* Cleanup interface

* Fix restore/snapshot

* Fix algo

* Fix reload task

* Fix typing / remove indirect add-on references

* Fix version

* Fix repository data

* Fix addon repo

* Fix api check

* Fix API return

* Fix model

* Temp fix available

* Fix lint

* Fix install

* Fix partial restore

* Fix store restore

* Fix ingress port

* Fix API

* Fix style
2019-05-07 17:27:00 +02:00
carstenschroeder
4e94043bca Fix validation of image and last_version (#1073)
* Fix validation of image and last_vesrion

* use of Maybe
2019-05-05 23:25:56 +02:00
Pascal Vizeli
749d45bf13 Update Dockerfile 2019-05-03 12:18:27 +02:00
Pascal Vizeli
ce99b3e259 Update azure-pipelines.yml for Azure Pipelines 2019-05-03 12:10:21 +02:00
Pascal Vizeli
2c84daefab Debugger (#1070)
* Add debuger to supervisor

* Fix init

* Fix lint
2019-05-03 12:02:32 +02:00
Pascal Vizeli
dc1933fa88 Remove old panels < 0.70 (#1066) 2019-04-29 12:13:31 +02:00
Pascal Vizeli
6970cebf80 Force auto API password (#1065) 2019-04-29 11:43:13 +02:00
dependabot[bot]
a234006de2 Bump pytest from 4.3.0 to 4.4.1 (#1059)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 4.3.0 to 4.4.1.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/4.3.0...4.4.1)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-04-25 17:36:55 +02:00
dependabot[bot]
2484149323 Bump pytz from 2018.9 to 2019.1 (#1058)
Bumps [pytz](https://github.com/stub42/pytz) from 2018.9 to 2019.1.
- [Release notes](https://github.com/stub42/pytz/releases)
- [Commits](https://github.com/stub42/pytz/compare/release_2018.9...release_2019.1)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-04-25 17:36:26 +02:00
dependabot[bot]
778148424c Bump attrs from 18.2.0 to 19.1.0 (#1057)
Bumps [attrs](https://github.com/python-attrs/attrs) from 18.2.0 to 19.1.0.
- [Release notes](https://github.com/python-attrs/attrs/releases)
- [Changelog](https://github.com/python-attrs/attrs/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/python-attrs/attrs/compare/18.2.0...19.1.0)

Signed-off-by: dependabot[bot] <support@dependabot.com>
2019-04-25 17:36:01 +02:00
Pascal Vizeli
55f4a2395e Bump version 163 2019-04-24 11:12:01 +02:00
Pascal Vizeli
5a45d47ed8 Merge pull request #1056 from home-assistant/dev
Release 162
2019-04-24 11:11:36 +02:00
Pascal Vizeli
da601d1483 Bump version 162 2019-04-24 11:05:14 +02:00
Pascal Vizeli
e98a1272e9 Panel small fixes (#1055) 2019-04-24 10:24:16 +02:00
Pascal Vizeli
90e9cf788b Update README.md 2019-04-24 10:04:35 +02:00
Pascal Vizeli
ec387c3010 Rename panel config attributes (#1054) 2019-04-24 09:48:01 +02:00
Fredrik Erlandsson
7e5a960c98 remove potential tag when pulling new image (#1053) 2019-04-24 09:46:58 +02:00
Pascal Vizeli
f1bcbf2416 Merge pull request #1051 from home-assistant/dev
Release 161
2019-04-23 14:41:55 +02:00
Pascal Vizeli
bce144e197 Panel Auto integration (#1050) 2019-04-23 14:28:13 +02:00
Pascal Vizeli
86a3735d83 Downgrade logger for audio to debug (#1049) 2019-04-23 11:29:45 +02:00
Pascal Vizeli
decf254e5f Ingress panel support (#1047)
* Ingress Panel support

* Fix lists

* Allow to set the value

* fix panels

* Update ha realtime

* Fix url

* Fix update
2019-04-23 11:18:04 +02:00
Pascal Vizeli
e10fe16f21 [skip ci] Update azure-pipelines.yml for Azure Pipelines 2019-04-16 13:49:51 +02:00
Pascal Vizeli
996891a740 Create stale.yml 2019-04-16 11:05:26 +02:00
Pascal Vizeli
7385d026ea Bump version 161 2019-04-16 00:00:08 +02:00
Pascal Vizeli
09f43d6f3c Merge pull request #1042 from home-assistant/dev
Release 160
2019-04-15 23:50:57 +02:00
Pascal Vizeli
6906e757dd Update azure-pipelines.yml for Azure Pipelines 2019-04-15 23:22:05 +02:00
Pascal Vizeli
963d242afa Fix handling with Firefox (#1041) 2019-04-15 18:09:13 +02:00
Pascal Vizeli
3ed7cbe2ed Fix: Websocket detection case sensitive (#1040) 2019-04-15 17:03:36 +02:00
Pascal Vizeli
0da924f10b [skip ci] Update azure-pipelines.yml for Azure Pipelines 2019-04-14 17:25:10 +02:00
Pascal Vizeli
76411da0a7 Update azure-pipelines.yml for Azure Pipelines 2019-04-14 01:10:41 +02:00
Pascal Vizeli
ce87a72cf0 Update .hadolint.yaml 2019-04-14 01:06:21 +02:00
Pascal Vizeli
f8c9e2f295 Create .hadolint.yaml 2019-04-14 01:03:25 +02:00
Pascal Vizeli
00af027e51 Update azure-pipelines.yml for Azure Pipelines 2019-04-14 01:01:24 +02:00
Pascal Vizeli
c91fce3281 [skip azurepipelines] Add badge 2019-04-13 13:29:04 +02:00
Pascal Vizeli
fb6df18ce9 Update azure-pipelines.yml for Azure Pipelines
Update parallel builds
2019-04-13 13:00:33 +02:00
Pascal Vizeli
31f5c6f938 Update azure-pipelines.yml for Azure Pipelines
Fix login
2019-04-13 12:50:37 +02:00
Pascal Vizeli
d3a44b2992 Update azure-pipelines.yml for Azure Pipelines 2019-04-13 12:44:47 +02:00
Pascal Vizeli
b537a03e6d [skip azurepipelines] Update azure-pipelines.yml for Azure Pipelines 2019-04-13 12:40:39 +02:00
Pascal Vizeli
46093379e4 Update azure-pipelines.yml for Azure Pipelines 2019-04-13 12:28:25 +02:00
Pascal Vizeli
1b17d90504 Update azure-pipelines.yml for Azure Pipelines 2019-04-13 00:14:33 +02:00
Pascal Vizeli
7d42dd7ac2 Update azure-pipelines.yml for Azure Pipelines (#1037)
* Update azure-pipelines.yml for Azure Pipelines

* Update azure-pipelines.yml for Azure Pipelines
2019-04-13 00:04:43 +02:00
Pascal Vizeli
f35dcfcfd3 Update azure-pipelines.yml for Azure Pipelines 2019-04-12 10:41:19 +02:00
Pascal Vizeli
c4f223c38a Update azure-pipelines.yml for Azure Pipelines 2019-04-12 10:40:24 +02:00
Pascal Vizeli
71362f2c76 Bump version 160 2019-04-12 00:57:40 +02:00
Pascal Vizeli
96beac9fd9 Merge pull request #1036 from home-assistant/dev
Release 159
2019-04-12 00:57:01 +02:00
Pascal Vizeli
608c0e5076 Allow to update logger (#1035)
* Allow to update logger

* Fix bug
2019-04-12 00:48:46 +02:00
Pascal Vizeli
16ef6d82d2 Panel sidebar (#1034) 2019-04-12 00:20:10 +02:00
Pascal Vizeli
51940222be Bump version 159 2019-04-11 11:21:53 +02:00
635 changed files with 39034 additions and 10084 deletions

54
.devcontainer/Dockerfile Normal file
View File

@@ -0,0 +1,54 @@
FROM mcr.microsoft.com/vscode/devcontainers/python:0-3.8
WORKDIR /workspaces
# Set Docker daemon config
RUN \
mkdir -p /etc/docker \
&& echo '{"storage-driver": "vfs"}' > /etc/docker/daemon.json
# Install Node/Yarn for Frontent
RUN apt-get update && apt-get install -y --no-install-recommends \
curl \
git \
apt-utils \
apt-transport-https \
&& curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - \
&& echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list \
&& apt-get update && apt-get install -y --no-install-recommends \
nodejs \
yarn \
&& curl -o - https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.3/install.sh | bash \
&& rm -rf /var/lib/apt/lists/*
ENV NVM_DIR /root/.nvm
# Install docker
# https://docs.docker.com/engine/installation/linux/docker-ce/ubuntu/
RUN apt-get update && apt-get install -y --no-install-recommends \
apt-transport-https \
ca-certificates \
curl \
software-properties-common \
gpg-agent \
&& curl -fsSL https://download.docker.com/linux/debian/gpg | apt-key add - \
&& add-apt-repository "deb https://download.docker.com/linux/debian $(lsb_release -cs) stable" \
&& apt-get update && apt-get install -y --no-install-recommends \
docker-ce \
docker-ce-cli \
containerd.io \
&& rm -rf /var/lib/apt/lists/*
# Install tools
RUN apt-get update && apt-get install -y --no-install-recommends \
jq \
dbus \
network-manager \
libpulse0 \
&& rm -rf /var/lib/apt/lists/*
# Install Python dependencies from requirements.txt if it exists
COPY requirements.txt requirements_tests.txt ./
RUN pip3 install -U setuptools pip \
&& pip3 install -r requirements.txt -r requirements_tests.txt \
&& pip3 install tox \
&& rm -f requirements.txt requirements_tests.txt

View File

@@ -0,0 +1,33 @@
{
"name": "Supervisor dev",
"context": "..",
"dockerFile": "Dockerfile",
"appPort": "9123:8123",
"postCreateCommand": "pre-commit install",
"runArgs": ["-e", "GIT_EDITOR=code --wait", "--privileged"],
"containerEnv": {"NVM_DIR":"/usr/local/share/nvm"},
"extensions": [
"ms-python.python",
"ms-python.vscode-pylance",
"visualstudioexptteam.vscodeintellicode",
"esbenp.prettier-vscode"
],
"settings": {
"terminal.integrated.shell.linux": "/bin/bash",
"editor.formatOnPaste": false,
"editor.formatOnSave": true,
"editor.formatOnType": true,
"files.trimTrailingWhitespace": true,
"python.pythonPath": "/usr/local/bin/python3",
"python.linting.pylintEnabled": true,
"python.linting.enabled": true,
"python.formatting.provider": "black",
"python.formatting.blackArgs": ["--target-version", "py38"],
"python.formatting.blackPath": "/usr/local/bin/black",
"python.linting.banditPath": "/usr/local/bin/bandit",
"python.linting.flake8Path": "/usr/local/bin/flake8",
"python.linting.mypyPath": "/usr/local/bin/mypy",
"python.linting.pylintPath": "/usr/local/bin/pylint",
"python.linting.pydocstylePath": "/usr/local/bin/pydocstyle"
}
}

View File

@@ -1,13 +1,23 @@
# General files
.git
.github
.devcontainer
.vscode
# Test related files
.tox
# Temporary files
**/__pycache__
.pytest_cache
# virtualenv
venv/
ENV/
# Data
home-assistant-polymer/
script/
tests/
# Test ENV
data/

View File

@@ -1,29 +1,69 @@
---
name: Report a bug with the Supervisor on a supported System
about: Report an issue related to the Home Assistant Supervisor.
labels: bug
---
<!-- READ THIS FIRST:
- If you need additional help with this template please refer to https://www.home-assistant.io/help/reporting_issues/
- Make sure you are running the latest version of Home Assistant before reporting an issue: https://github.com/home-assistant/home-assistant/releases
- Do not report issues for components here, plaese refer to https://github.com/home-assistant/home-assistant/issues
- This is for bugs only. Feature and enhancement requests should go in our community forum: https://community.home-assistant.io/c/feature-requests
- Provide as many details as possible. Paste logs, configuration sample and code into the backticks. Do not delete any text from this template!
- If you have a problem with a Add-on, make a issue on there repository.
- If you have a problem with an add-on, make an issue in it's repository.
-->
**Home Assistant release with the issue:**
<!--
- Frontend -> Developer tools -> Info
- Or use this command: hass --version
Important: You can only fill a bug repport for an supported system! If you run an unsupported installation. This report would be closed without comment.
-->
**Operating environment (HassOS/Generic):**
### Describe the issue
<!-- Provide as many details as possible. -->
### Steps to reproduce
<!-- What do you do to encounter the issue. -->
1. ...
2. ...
3. ...
### Enviroment details
<!-- You can find these details in the system tab of the supervisor panel, or by using the `ha` CLI. -->
- **Operating System:**: xxx
- **Supervisor version:**: xxx
- **Home Assistant version**: xxx
### Supervisor logs
<details>
<summary>Supervisor logs</summary>
<!--
Please provide details about your environment.
- Frontend -> Supervisor -> System
- Or use this command: ha supervisor logs
- Logs are more than just errors, even if you don't think it's important, it is.
-->
**Supervisor logs:**
```
Paste supervisor logs here
```
</details>
### System Information
<details>
<summary>System Information</summary>
<!--
- Frontend -> Hass.io -> System
- Or use this command: hassio su logs
- Use this command: ha info
-->
```
Paste system info here
**Description of problem:**
```
</details>

106
.github/ISSUE_TEMPLATE/bug_report.yml vendored Normal file
View File

@@ -0,0 +1,106 @@
name: Bug Report Form
about: Report an issue related to the Home Assistant Supervisor.
labels: bug
title: ""
issue_body: true
body:
- type: markdown
attributes:
value: |
This issue form is for reporting bugs with **supported** setups only!
If you have a feature or enhancement request, please use the [feature request][fr] section of our [Community Forum][fr].
[fr]: https://community.home-assistant.io/c/feature-requests
- type: textarea
validations:
required: true
attributes:
label: Describe the issue you are experiencing
description: Provide a clear and concise description of what the bug is.
- type: markdown
attributes:
value: |
## Environment
- type: input
validations:
required: true
attributes:
label: What is the used version of the Supervisor?
placeholder: supervisor-
description: >
Can be found in the Supervisor panel -> System tab. Starts with
`supervisor-....`.
- type: dropdown
validations:
required: true
attributes:
label: What type of installation are you running?
description: >
If you don't know, you can find it in: Configuration panel -> Info.
options:
- Home Assistant OS
- Home Assistant Supervised
- type: dropdown
validations:
required: true
attributes:
label: Which operating system are you running on?
options:
- Home Assistant Operating System
- Debian
- Other (e.g., Raspbian/Raspberry Pi OS/Fedora)
- type: input
validations:
required: true
attributes:
label: What is the version of your installed operating system?
placeholder: "5.11"
description: Can be found in the Supervisor panel -> System tab.
- type: input
validations:
required: true
attributes:
label: What version of Home Assistant Core is installed?
placeholder: core-
description: >
Can be found in the Supervisor panel -> System tab. Starts with
`core-....`.
- type: markdown
attributes:
value: |
# Details
- type: textarea
validations:
required: true
attributes:
label: Steps to reproduce the issue
description: |
Please tell us exactly how to reproduce your issue.
Provide clear and concise step by step instructions and add code snippets if needed.
value: |
1.
2.
3.
...
- type: textarea
validations:
required: true
attributes:
label: Anything in the Supervisor logs that might be useful for us?
description: >
The Supervisor logs can be found in the Supervisor panel -> System tab.
value: |
```txt
# Put your logs below this line
```
- type: markdown
attributes:
value: |
## Additional information
- type: markdown
attributes:
value: |
If you have any additional information for us, use the field below.
Please note, you can attach screenshots or screen recordings here.

25
.github/ISSUE_TEMPLATE/config.yml vendored Normal file
View File

@@ -0,0 +1,25 @@
blank_issues_enabled: false
contact_links:
- name: Report a bug/issues with an unsupported Supervisor
url: https://community.home-assistant.io
about: The Community guide can help or was updated to solve your issue
- name: Report a bug for the Supervisor panel
url: https://github.com/home-assistant/frontend/issues
about: The Supervisor panel is a part of the Home Assistant frontend
- name: Report incorrect or missing information on our developer documentation
url: https://github.com/home-assistant/developers.home-assistant.io/issues
about: Our documentation has its own issue tracker. Please report issues with the website there.
- name: Request a feature for the Supervisor
url: https://community.home-assistant.io/c/feature-requests
about: Request an new feature for the Supervisor.
- name: I have a question or need support
url: https://www.home-assistant.io/help
about: We use GitHub for tracking bugs, check our website for resources on getting help.
- name: I'm unsure where to go?
url: https://www.home-assistant.io/join-chat
about: If you are unsure where to go, then joining our chat is recommended; Just ask!

68
.github/PULL_REQUEST_TEMPLATE.md vendored Normal file
View File

@@ -0,0 +1,68 @@
<!--
You are amazing! Thanks for contributing to our project!
Please, DO NOT DELETE ANY TEXT from this template! (unless instructed).
-->
## Proposed change
<!--
Describe the big picture of your changes here to communicate to the
maintainers why we should accept this pull request. If it fixes a bug
or resolves a feature request, be sure to link to that issue in the
additional information section.
-->
## Type of change
<!--
What type of change does your PR introduce to Home Assistant?
NOTE: Please, check only 1! box!
If your PR requires multiple boxes to be checked, you'll most likely need to
split it into multiple PRs. This makes things easier and faster to code review.
-->
- [ ] Dependency upgrade
- [ ] Bugfix (non-breaking change which fixes an issue)
- [ ] New feature (which adds functionality to the supervisor)
- [ ] Breaking change (fix/feature causing existing functionality to break)
- [ ] Code quality improvements to existing code or addition of tests
## Additional information
<!--
Details are important, and help maintainers processing your PR.
Please be sure to fill out additional details, if applicable.
-->
- This PR fixes or closes issue: fixes #
- This PR is related to issue:
- Link to documentation pull request:
## Checklist
<!--
Put an `x` in the boxes that apply. You can also fill these out after
creating the PR. If you're unsure about any of them, don't hesitate to ask.
We're here to help! This is simply a reminder of what we are going to look
for before merging your code.
-->
- [ ] The code change is tested and works locally.
- [ ] Local tests pass. **Your PR cannot be merged unless tests pass**
- [ ] There is no commented out code in this PR.
- [ ] I have followed the [development checklist][dev-checklist]
- [ ] The code has been formatted using Black (`black --fast supervisor tests`)
- [ ] Tests have been added to verify that the new code works.
If API endpoints of add-on configuration are added/changed:
- [ ] Documentation added/updated for [developers.home-assistant.io][docs-repository]
<!--
Thank you for contributing <3
Below, some useful links you could explore:
-->
[dev-checklist]: https://developers.home-assistant.io/docs/en/development_checklist.html
[docs-repository]: https://github.com/home-assistant/developers.home-assistant

14
.github/dependabot.yml vendored Normal file
View File

@@ -0,0 +1,14 @@
version: 2
updates:
- package-ecosystem: pip
directory: "/"
schedule:
interval: daily
time: "06:00"
open-pull-requests-limit: 10
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: daily
time: "06:00"
open-pull-requests-limit: 10

View File

@@ -1,4 +1,49 @@
change-template: "- #$NUMBER $TITLE @$AUTHOR"
sort-direction: ascending
categories:
- title: ":boom: Breaking Changes"
label: "breaking-change"
- title: ":wrench: Build"
label: "build"
- title: ":boar: Chore"
label: "chore"
- title: ":sparkles: New Features"
label: "new-feature"
- title: ":zap: Performance"
label: "performance"
- title: ":recycle: Refactor"
label: "refactor"
- title: ":green_heart: CI"
label: "ci"
- title: ":bug: Bug Fixes"
label: "bugfix"
- title: ":white_check_mark: Test"
label: "test"
- title: ":arrow_up: Dependency Updates"
label: "dependencies"
include-labels:
- "breaking-change"
- "build"
- "chore"
- "performance"
- "refactor"
- "new-feature"
- "bugfix"
- "dependencies"
- "test"
- "ci"
template: |
## What's Changed
$CHANGES

215
.github/workflows/builder.yml vendored Normal file
View File

@@ -0,0 +1,215 @@
name: Build supervisor
on:
workflow_dispatch:
inputs:
channel:
description: "Channel"
required: true
default: "dev"
version:
description: "Version"
required: true
publish:
description: "Publish"
required: true
default: "false"
stable:
description: "Stable"
required: true
default: "false"
pull_request:
branches: ["main"]
release:
types: ["published"]
push:
branches: ["main"]
paths:
- "rootfs/**"
- "supervisor/**"
- build.json
- Dockerfile
- requirements.txt
- setup.py
env:
BUILD_NAME: supervisor
BUILD_TYPE: supervisor
WHEELS_TAG: 3.8-alpine3.13
jobs:
init:
name: Initialize build
runs-on: ubuntu-latest
outputs:
architectures: ${{ steps.info.outputs.architectures }}
version: ${{ steps.version.outputs.version }}
channel: ${{ steps.version.outputs.channel }}
publish: ${{ steps.version.outputs.publish }}
requirements: ${{ steps.requirements.outputs.changed }}
steps:
- name: Checkout the repository
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Get information
id: info
uses: home-assistant/actions/helpers/info@master
- name: Get version
id: version
uses: home-assistant/actions/helpers/version@master
with:
type: ${{ env.BUILD_TYPE }}
- name: Get changed files
id: changed_files
if: steps.version.outputs.publish == 'false'
uses: jitterbit/get-changed-files@v1
- name: Check if requirements files changed
id: requirements
run: |
if [[ "${{ steps.changed_files.outputs.all }}" =~ requirements.txt ]]; then
echo "::set-output name=changed::true"
fi
build:
name: Build ${{ matrix.arch }} supervisor
needs: init
runs-on: ubuntu-latest
strategy:
matrix:
arch: ${{ fromJson(needs.init.outputs.architectures) }}
steps:
- name: Checkout the repository
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Build wheels
if: needs.init.outputs.requirements == 'true'
uses: home-assistant/wheels@master
with:
tag: ${{ env.WHEELS_TAG }}
arch: ${{ matrix.arch }}
wheels-host: ${{ secrets.WHEELS_HOST }}
wheels-key: ${{ secrets.WHEELS_KEY }}
wheels-user: wheels
apk: "build-base;libffi-dev;openssl-dev;cargo"
skip-binary: aiohttp
requirements: "requirements.txt"
- name: Set version
if: needs.init.outputs.publish == 'true'
uses: home-assistant/actions/helpers/version@master
with:
type: ${{ env.BUILD_TYPE }}
- name: Login to DockerHub
if: needs.init.outputs.publish == 'true'
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Set build arguments
if: needs.init.outputs.publish == 'false'
run: echo "BUILD_ARGS=--test" >> $GITHUB_ENV
- name: Build supervisor
uses: home-assistant/builder@2021.02.0
with:
args: |
$BUILD_ARGS \
--${{ matrix.arch }} \
--target /data \
--generic ${{ needs.init.outputs.version }}
version:
name: Update version
needs: ["init", "run_supervisor"]
runs-on: ubuntu-latest
steps:
- name: Checkout the repository
if: needs.init.outputs.publish == 'true'
uses: actions/checkout@v2
- name: Initialize git
if: needs.init.outputs.publish == 'true'
uses: home-assistant/actions/helpers/git-init@master
with:
name: ${{ secrets.GIT_NAME }}
email: ${{ secrets.GIT_EMAIL }}
token: ${{ secrets.GIT_TOKEN }}
- name: Update version file
if: needs.init.outputs.publish == 'true'
uses: home-assistant/actions/helpers/version-push@master
with:
key: ${{ env.BUILD_NAME }}
version: ${{ needs.init.outputs.version }}
channel: ${{ needs.init.outputs.channel }}
run_supervisor:
runs-on: ubuntu-latest
name: Run the Supervisor
needs: ["build"]
steps:
- name: Checkout the repository
uses: actions/checkout@v2
- name: Build the Supervisor
uses: home-assistant/builder@2021.02.0
with:
args: |
--test \
--amd64 \
--target /data \
--generic runner
- name: Create the Supervisor
run: |
mkdir -p /tmp/supervisor/data
docker create --name hassio_supervisor \
--privileged \
--security-opt seccomp=unconfined \
--security-opt apparmor:unconfined \
-v /run/docker.sock:/run/docker.sock \
-v /run/dbus:/run/dbus \
-v /tmp/supervisor/data:/data \
-v /etc/machine-id:/etc/machine-id:ro \
-e SUPERVISOR_SHARE="/tmp/supervisor/data" \
-e SUPERVISOR_NAME=hassio_supervisor \
-e SUPERVISOR_DEV=1 \
-e SUPERVISOR_MACHINE="qemux86-64" \
homeassistant/amd64-hassio-supervisor:runner
- name: Start the Supervisor
run: docker start hassio_supervisor
- name: Wait for Supervisor to come up
run: |
SUPERVISOR=$(docker inspect --format='{{.NetworkSettings.IPAddress}}' hassio_supervisor)
ping="error"
while [ "$ping" != "ok" ]; do
ping=$(curl -sSL "http://$SUPERVISOR/supervisor/ping" | jq -r .result)
sleep 5
done
- name: Check the Supervisor
run: |
echo "Checking supervisor info"
test=$(docker exec hassio_cli ha supervisor info --no-progress --raw-json | jq -r .result)
if [ "$test" != "ok" ];then
docker logs hassio_supervisor
exit 1
fi
echo "Checking supervisor network info"
test=$(docker exec hassio_cli ha network info --no-progress --raw-json | jq -r .result)
if [ "$test" != "ok" ];then
docker logs hassio_supervisor
exit 1
fi

19
.github/workflows/check_pr_labels.yml vendored Normal file
View File

@@ -0,0 +1,19 @@
name: Check PR
on:
pull_request:
branches: ["main"]
types: [labeled, unlabeled, synchronize]
jobs:
init:
name: Check labels
runs-on: ubuntu-latest
steps:
- name: Check labels
run: |
labels=$(jq -r '.pull_request.labels[] | .name' ${{github.event_path }})
echo "$labels"
if [ "$labels" == "cla-signed" ]; then
exit 1
fi

431
.github/workflows/ci.yaml vendored Normal file
View File

@@ -0,0 +1,431 @@
name: CI
# yamllint disable-line rule:truthy
on:
push:
branches:
- main
pull_request: ~
env:
DEFAULT_PYTHON: 3.8
PRE_COMMIT_HOME: ~/.cache/pre-commit
jobs:
# Separate job to pre-populate the base dependency cache
# This prevent upcoming jobs to do the same individually
prepare:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.8]
name: Prepare Python ${{ matrix.python-version }} dependencies
steps:
- name: Check out code from GitHub
uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
id: python
uses: actions/setup-python@v2.2.1
with:
python-version: ${{ matrix.python-version }}
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.4
with:
path: venv
key: |
${{ runner.os }}-venv-${{ steps.python.outputs.python-version }}-${{ hashFiles('requirements.txt') }}-${{ hashFiles('requirements_tests.txt') }}
restore-keys: |
${{ runner.os }}-venv-${{ steps.python.outputs.python-version }}-${{ hashFiles('requirements.txt') }}
${{ runner.os }}-venv-${{ steps.python.outputs.python-version }}-
- name: Create Python virtual environment
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
python -m venv venv
. venv/bin/activate
pip install -U pip setuptools
pip install -r requirements.txt -r requirements_tests.txt
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.4
with:
path: ${{ env.PRE_COMMIT_HOME }}
key: |
${{ runner.os }}-pre-commit-${{ hashFiles('.pre-commit-config.yaml') }}
restore-keys: |
${{ runner.os }}-pre-commit-
- name: Install pre-commit dependencies
if: steps.cache-precommit.outputs.cache-hit != 'true'
run: |
. venv/bin/activate
pre-commit install-hooks
lint-black:
name: Check black
runs-on: ubuntu-latest
needs: prepare
steps:
- name: Check out code from GitHub
uses: actions/checkout@v2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v2.2.1
id: python
with:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.4
with:
path: venv
key: |
${{ runner.os }}-venv-${{ steps.python.outputs.python-version }}-${{ hashFiles('requirements.txt') }}-${{ hashFiles('requirements_tests.txt') }}
- name: Fail job if Python cache restore failed
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Run black
run: |
. venv/bin/activate
black --target-version py38 --check supervisor tests setup.py
lint-dockerfile:
name: Check Dockerfile
runs-on: ubuntu-latest
needs: prepare
steps:
- name: Check out code from GitHub
uses: actions/checkout@v2
- name: Register hadolint problem matcher
run: |
echo "::add-matcher::.github/workflows/matchers/hadolint.json"
- name: Check Dockerfile
uses: docker://hadolint/hadolint:v1.18.0
with:
args: hadolint Dockerfile
lint-executable-shebangs:
name: Check executables
runs-on: ubuntu-latest
needs: prepare
steps:
- name: Check out code from GitHub
uses: actions/checkout@v2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v2.2.1
id: python
with:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.4
with:
path: venv
key: |
${{ runner.os }}-venv-${{ steps.python.outputs.python-version }}-${{ hashFiles('requirements.txt') }}-${{ hashFiles('requirements_tests.txt') }}
- name: Fail job if Python cache restore failed
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.4
with:
path: ${{ env.PRE_COMMIT_HOME }}
key: |
${{ runner.os }}-pre-commit-${{ hashFiles('.pre-commit-config.yaml') }}
- name: Fail job if cache restore failed
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Register check executables problem matcher
run: |
echo "::add-matcher::.github/workflows/matchers/check-executables-have-shebangs.json"
- name: Run executables check
run: |
. venv/bin/activate
pre-commit run --hook-stage manual check-executables-have-shebangs --all-files
lint-flake8:
name: Check flake8
runs-on: ubuntu-latest
needs: prepare
steps:
- name: Check out code from GitHub
uses: actions/checkout@v2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v2.2.1
id: python
with:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.4
with:
path: venv
key: |
${{ runner.os }}-venv-${{ steps.python.outputs.python-version }}-${{ hashFiles('requirements.txt') }}-${{ hashFiles('requirements_tests.txt') }}
- name: Fail job if Python cache restore failed
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Register flake8 problem matcher
run: |
echo "::add-matcher::.github/workflows/matchers/flake8.json"
- name: Run flake8
run: |
. venv/bin/activate
flake8 supervisor tests
lint-isort:
name: Check isort
runs-on: ubuntu-latest
needs: prepare
steps:
- name: Check out code from GitHub
uses: actions/checkout@v2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v2.2.1
id: python
with:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.4
with:
path: venv
key: |
${{ runner.os }}-venv-${{ steps.python.outputs.python-version }}-${{ hashFiles('requirements.txt') }}-${{ hashFiles('requirements_tests.txt') }}
- name: Fail job if Python cache restore failed
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.4
with:
path: ${{ env.PRE_COMMIT_HOME }}
key: |
${{ runner.os }}-pre-commit-${{ hashFiles('.pre-commit-config.yaml') }}
- name: Fail job if cache restore failed
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Run isort
run: |
. venv/bin/activate
pre-commit run --hook-stage manual isort --all-files --show-diff-on-failure
lint-json:
name: Check JSON
runs-on: ubuntu-latest
needs: prepare
steps:
- name: Check out code from GitHub
uses: actions/checkout@v2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v2.2.1
id: python
with:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.4
with:
path: venv
key: |
${{ runner.os }}-venv-${{ steps.python.outputs.python-version }}-${{ hashFiles('requirements.txt') }}-${{ hashFiles('requirements_tests.txt') }}
- name: Fail job if Python cache restore failed
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.4
with:
path: ${{ env.PRE_COMMIT_HOME }}
key: |
${{ runner.os }}-pre-commit-${{ hashFiles('.pre-commit-config.yaml') }}
- name: Fail job if cache restore failed
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Register check-json problem matcher
run: |
echo "::add-matcher::.github/workflows/matchers/check-json.json"
- name: Run check-json
run: |
. venv/bin/activate
pre-commit run --hook-stage manual check-json --all-files
lint-pylint:
name: Check pylint
runs-on: ubuntu-latest
needs: prepare
steps:
- name: Check out code from GitHub
uses: actions/checkout@v2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v2.2.1
id: python
with:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.4
with:
path: venv
key: |
${{ runner.os }}-venv-${{ steps.python.outputs.python-version }}-${{ hashFiles('requirements.txt') }}-${{ hashFiles('requirements_tests.txt') }}
- name: Fail job if Python cache restore failed
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Register pylint problem matcher
run: |
echo "::add-matcher::.github/workflows/matchers/pylint.json"
- name: Run pylint
run: |
. venv/bin/activate
pylint supervisor tests
lint-pyupgrade:
name: Check pyupgrade
runs-on: ubuntu-latest
needs: prepare
steps:
- name: Check out code from GitHub
uses: actions/checkout@v2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v2.2.1
id: python
with:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.4
with:
path: venv
key: |
${{ runner.os }}-venv-${{ steps.python.outputs.python-version }}-${{ hashFiles('requirements.txt') }}-${{ hashFiles('requirements_tests.txt') }}
- name: Fail job if Python cache restore failed
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Restore pre-commit environment from cache
id: cache-precommit
uses: actions/cache@v2.1.4
with:
path: ${{ env.PRE_COMMIT_HOME }}
key: |
${{ runner.os }}-pre-commit-${{ hashFiles('.pre-commit-config.yaml') }}
- name: Fail job if cache restore failed
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Run pyupgrade
run: |
. venv/bin/activate
pre-commit run --hook-stage manual pyupgrade --all-files --show-diff-on-failure
pytest:
runs-on: ubuntu-latest
needs: prepare
strategy:
matrix:
python-version: [3.8]
name: Run tests Python ${{ matrix.python-version }}
steps:
- name: Check out code from GitHub
uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2.2.1
id: python
with:
python-version: ${{ matrix.python-version }}
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.4
with:
path: venv
key: |
${{ runner.os }}-venv-${{ steps.python.outputs.python-version }}-${{ hashFiles('requirements.txt') }}-${{ hashFiles('requirements_tests.txt') }}
- name: Fail job if Python cache restore failed
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Install additional system dependencies
run: |
sudo apt-get update
sudo apt-get install -y --no-install-recommends libpulse0 libudev1
- name: Register Python problem matcher
run: |
echo "::add-matcher::.github/workflows/matchers/python.json"
- name: Install Pytest Annotation plugin
run: |
. venv/bin/activate
# Ideally this should be part of our dependencies
# However this plugin is fairly new and doesn't run correctly
# on a non-GitHub environment.
pip install pytest-github-actions-annotate-failures
- name: Run pytest
run: |
. venv/bin/activate
pytest \
-qq \
--timeout=10 \
--durations=10 \
--cov supervisor \
-o console_output_style=count \
tests
- name: Upload coverage artifact
uses: actions/upload-artifact@v2.2.2
with:
name: coverage-${{ matrix.python-version }}
path: .coverage
coverage:
name: Process test coverage
runs-on: ubuntu-latest
needs: pytest
steps:
- name: Check out code from GitHub
uses: actions/checkout@v2
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
uses: actions/setup-python@v2.2.1
id: python
with:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Restore Python virtual environment
id: cache-venv
uses: actions/cache@v2.1.4
with:
path: venv
key: |
${{ runner.os }}-venv-${{ steps.python.outputs.python-version }}-${{ hashFiles('requirements.txt') }}-${{ hashFiles('requirements_tests.txt') }}
- name: Fail job if Python cache restore failed
if: steps.cache-venv.outputs.cache-hit != 'true'
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Download all coverage artifacts
uses: actions/download-artifact@v2
- name: Combine coverage results
run: |
. venv/bin/activate
coverage combine coverage*/.coverage*
coverage report
coverage xml
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1.2.1

20
.github/workflows/lock.yml vendored Normal file
View File

@@ -0,0 +1,20 @@
name: Lock
# yamllint disable-line rule:truthy
on:
schedule:
- cron: "0 0 * * *"
jobs:
lock:
runs-on: ubuntu-latest
steps:
- uses: dessant/lock-threads@v2.0.3
with:
github-token: ${{ github.token }}
issue-lock-inactive-days: "30"
issue-exclude-created-before: "2020-10-01T00:00:00Z"
issue-lock-reason: ""
pr-lock-inactive-days: "1"
pr-exclude-created-before: "2020-11-01T00:00:00Z"
pr-lock-reason: ""

View File

@@ -0,0 +1,14 @@
{
"problemMatcher": [
{
"owner": "check-executables-have-shebangs",
"pattern": [
{
"regexp": "^(.+):\\s(.+)$",
"file": 1,
"message": 2
}
]
}
]
}

View File

@@ -0,0 +1,16 @@
{
"problemMatcher": [
{
"owner": "check-json",
"pattern": [
{
"regexp": "^(.+):\\s(.+\\sline\\s(\\d+)\\scolumn\\s(\\d+).+)$",
"file": 1,
"message": 2,
"line": 3,
"column": 4
}
]
}
]
}

30
.github/workflows/matchers/flake8.json vendored Normal file
View File

@@ -0,0 +1,30 @@
{
"problemMatcher": [
{
"owner": "flake8-error",
"severity": "error",
"pattern": [
{
"regexp": "^(.*):(\\d+):(\\d+):\\s(E\\d{3}\\s.*)$",
"file": 1,
"line": 2,
"column": 3,
"message": 4
}
]
},
{
"owner": "flake8-warning",
"severity": "warning",
"pattern": [
{
"regexp": "^(.*):(\\d+):(\\d+):\\s([CDFNW]\\d{3}\\s.*)$",
"file": 1,
"line": 2,
"column": 3,
"message": 4
}
]
}
]
}

View File

@@ -0,0 +1,16 @@
{
"problemMatcher": [
{
"owner": "hadolint",
"pattern": [
{
"regexp": "^(.+):(\\d+)\\s+((DL\\d{4}).+)$",
"file": 1,
"line": 2,
"message": 3,
"code": 4
}
]
}
]
}

32
.github/workflows/matchers/pylint.json vendored Normal file
View File

@@ -0,0 +1,32 @@
{
"problemMatcher": [
{
"owner": "pylint-error",
"severity": "error",
"pattern": [
{
"regexp": "^(.+):(\\d+):(\\d+):\\s(([EF]\\d{4}):\\s.+)$",
"file": 1,
"line": 2,
"column": 3,
"message": 4,
"code": 5
}
]
},
{
"owner": "pylint-warning",
"severity": "warning",
"pattern": [
{
"regexp": "^(.+):(\\d+):(\\d+):\\s(([CRW]\\d{4}):\\s.+)$",
"file": 1,
"line": 2,
"column": 3,
"message": 4,
"code": 5
}
]
}
]
}

18
.github/workflows/matchers/python.json vendored Normal file
View File

@@ -0,0 +1,18 @@
{
"problemMatcher": [
{
"owner": "python",
"pattern": [
{
"regexp": "^\\s*File\\s\\\"(.*)\\\",\\sline\\s(\\d+),\\sin\\s(.*)$",
"file": 1,
"line": 2
},
{
"regexp": "^\\s*raise\\s(.*)\\(\\'(.*)\\'\\)$",
"message": 2
}
]
}
]
}

44
.github/workflows/release-drafter.yml vendored Normal file
View File

@@ -0,0 +1,44 @@
name: Release Drafter
on:
push:
branches:
- main
jobs:
update_release_draft:
runs-on: ubuntu-latest
name: Release Drafter
steps:
- name: Checkout the repository
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Find Next Version
id: version
run: |
declare -i newpost
latest=$(git describe --tags $(git rev-list --tags --max-count=1))
latestpre=$(echo "$latest" | awk '{split($0,a,"."); print a[1] "." a[2]}')
datepre=$(date --utc '+%Y.%m')
if [[ "$latestpre" == "$datepre" ]]; then
latestpost=$(echo "$latest" | awk '{split($0,a,"."); print a[3]}')
newpost=$latestpost+1
else
newpost=0
fi
echo Current version: $latest
echo New target version: $datepre.$newpost
echo "::set-output name=version::$datepre.$newpost"
- name: Run Release Drafter
uses: release-drafter/release-drafter@v5
with:
tag: ${{ steps.version.outputs.version }}
name: ${{ steps.version.outputs.version }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

21
.github/workflows/sentry.yaml vendored Normal file
View File

@@ -0,0 +1,21 @@
name: Sentry Release
# yamllint disable-line rule:truthy
on:
release:
types: [published, prereleased]
jobs:
createSentryRelease:
runs-on: ubuntu-latest
steps:
- name: Check out code from GitHub
uses: actions/checkout@v2
- name: Sentry Release
uses: getsentry/action-release@v1.1
env:
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
SENTRY_ORG: ${{ secrets.SENTRY_ORG }}
SENTRY_PROJECT: ${{ secrets.SENTRY_PROJECT }}
with:
environment: production

39
.github/workflows/stale.yml vendored Normal file
View File

@@ -0,0 +1,39 @@
name: Stale
# yamllint disable-line rule:truthy
on:
schedule:
- cron: "0 * * * *"
jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v3.0.17
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
days-before-stale: 60
days-before-close: 7
stale-issue-label: "stale"
exempt-issue-labels: "no-stale,Help%20wanted,help-wanted,pinned,rfc,security"
stale-issue-message: >
There hasn't been any activity on this issue recently. Due to the
high number of incoming GitHub notifications, we have to clean some
of the old issues, as many of them have already been resolved with
the latest updates.
Please make sure to update to the latest version and check if that
solves the issue. Let us know if that works for you by
adding a comment 👍
This issue has now been marked as stale and will be closed if no
further activity occurs. Thank you for your contributions.
stale-pr-label: "stale"
exempt-pr-labels: "no-stale,pinned,rfc,security"
stale-pr-message: >
There hasn't been any activity on this pull request recently. This
pull request has been automatically marked as stale because of that
and will be closed if no further activity occurs within 7 days.
Thank you for your contributions.

9
.gitignore vendored
View File

@@ -92,4 +92,11 @@ ENV/
.pylint.d/
# VS Code
.vscode/
.vscode/*
!.vscode/cSpell.json
!.vscode/tasks.json
!.vscode/launch.json
# mypy
/.mypy_cache/*
/.dmypy.json

5
.hadolint.yaml Normal file
View File

@@ -0,0 +1,5 @@
ignored:
- DL3018
- DL3006
- DL3013
- SC2155

34
.pre-commit-config.yaml Normal file
View File

@@ -0,0 +1,34 @@
repos:
- repo: https://github.com/psf/black
rev: 20.8b1
hooks:
- id: black
args:
- --safe
- --quiet
- --target-version
- py38
files: ^((supervisor|tests)/.+)?[^/]+\.py$
- repo: https://gitlab.com/pycqa/flake8
rev: 3.8.3
hooks:
- id: flake8
additional_dependencies:
- flake8-docstrings==1.5.0
- pydocstyle==5.0.2
files: ^(supervisor|script|tests)/.+\.py$
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.1.0
hooks:
- id: check-executables-have-shebangs
stages: [manual]
- id: check-json
- repo: https://github.com/pre-commit/mirrors-isort
rev: v4.3.21
hooks:
- id: isort
- repo: https://github.com/asottile/pyupgrade
rev: v2.6.2
hooks:
- id: pyupgrade
args: [--py37-plus]

18
.vscode/launch.json vendored Normal file
View File

@@ -0,0 +1,18 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Supervisor remote debug",
"type": "python",
"request": "attach",
"port": 33333,
"host": "172.30.32.2",
"pathMappings": [
{
"localRoot": "${workspaceFolder}",
"remoteRoot": "/usr/src/supervisor"
}
]
}
]
}

104
.vscode/tasks.json vendored Normal file
View File

@@ -0,0 +1,104 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "Run Supervisor",
"type": "shell",
"command": "./scripts/run-supervisor.sh",
"group": {
"kind": "test",
"isDefault": true
},
"presentation": {
"reveal": "always",
"panel": "new"
},
"problemMatcher": []
},
{
"label": "Build Supervisor",
"type": "shell",
"command": "./scripts/build-supervisor.sh",
"group": {
"kind": "build",
"isDefault": true
},
"presentation": {
"reveal": "always",
"panel": "new"
},
"problemMatcher": []
},
{
"label": "Run Supervisor CLI",
"type": "shell",
"command": "docker exec -ti hassio_cli /usr/bin/cli.sh",
"group": {
"kind": "test",
"isDefault": true
},
"presentation": {
"reveal": "always",
"panel": "new"
},
"problemMatcher": []
},
{
"label": "Update Supervisor Panel",
"type": "shell",
"command": "./scripts/update-frontend.sh",
"group": {
"kind": "build",
"isDefault": true
},
"presentation": {
"reveal": "always",
"panel": "new"
},
"problemMatcher": []
},
{
"label": "Pytest",
"type": "shell",
"command": "pytest --timeout=10 tests",
"group": {
"kind": "test",
"isDefault": true
},
"presentation": {
"reveal": "always",
"panel": "new"
},
"problemMatcher": []
},
{
"label": "Flake8",
"type": "shell",
"command": "flake8 supervisor tests",
"group": {
"kind": "test",
"isDefault": true
},
"presentation": {
"reveal": "always",
"panel": "new"
},
"problemMatcher": []
},
{
"label": "Pylint",
"type": "shell",
"command": "pylint supervisor",
"dependsOn": ["Install all Requirements"],
"group": {
"kind": "test",
"isDefault": true
},
"presentation": {
"reveal": "always",
"panel": "new"
},
"problemMatcher": []
}
]
}

724
API.md
View File

@@ -1,724 +0,0 @@
# Hass.io
## Hass.io RESTful API
Interface for Home Assistant to control things from supervisor.
On error / Code 400:
```json
{
"result": "error",
"message": ""
}
```
On success / Code 200:
```json
{
"result": "ok",
"data": { }
}
```
For access to API you need set the `X-HASSIO-KEY` they will be available for Add-ons/HomeAssistant with environment `HASSIO_TOKEN`.
### Hass.io
- GET `/supervisor/ping`
This API call don't need a token.
- GET `/supervisor/info`
The addons from `addons` are only installed one.
```json
{
"version": "INSTALL_VERSION",
"last_version": "LAST_VERSION",
"arch": "armhf|aarch64|i386|amd64",
"channel": "stable|beta|dev",
"timezone": "TIMEZONE",
"logging": "debug|info|warning|error|critical",
"ip_address": "ip address",
"wait_boot": "int",
"addons": [
{
"name": "xy bla",
"slug": "xy",
"description": "description",
"repository": "12345678|null",
"version": "LAST_VERSION",
"installed": "INSTALL_VERSION",
"icon": "bool",
"logo": "bool",
"state": "started|stopped",
}
],
"addons_repositories": [
"REPO_URL"
]
}
```
- POST `/supervisor/update`
Optional:
```json
{
"version": "VERSION"
}
```
- POST `/supervisor/options`
```json
{
"channel": "stable|beta|dev",
"timezone": "TIMEZONE",
"wait_boot": "int",
"logging": "debug|info|warning|error|critical",
"addons_repositories": [
"REPO_URL"
]
}
```
- POST `/supervisor/reload`
Reload addons/version.
- GET `/supervisor/logs`
Output is the raw docker log.
- GET `/supervisor/stats`
```json
{
"cpu_percent": 0.0,
"memory_usage": 283123,
"memory_limit": 329392,
"network_tx": 0,
"network_rx": 0,
"blk_read": 0,
"blk_write": 0
}
```
### Snapshot
- GET `/snapshots`
```json
{
"snapshots": [
{
"slug": "SLUG",
"date": "ISO",
"name": "Custom name",
"type": "full|partial",
"protected": "bool"
}
]
}
```
- POST `/snapshots/reload`
- POST `/snapshots/new/upload`
return:
```json
{
"slug": ""
}
```
- POST `/snapshots/new/full`
```json
{
"name": "Optional",
"password": "Optional"
}
```
return:
```json
{
"slug": ""
}
```
- POST `/snapshots/new/partial`
```json
{
"name": "Optional",
"addons": ["ADDON_SLUG"],
"folders": ["FOLDER_NAME"],
"password": "Optional"
}
```
return:
```json
{
"slug": ""
}
```
- POST `/snapshots/reload`
- GET `/snapshots/{slug}/info`
```json
{
"slug": "SNAPSHOT ID",
"type": "full|partial",
"name": "custom snapshot name / description",
"date": "ISO",
"size": "SIZE_IN_MB",
"protected": "bool",
"homeassistant": "version",
"addons": [
{
"slug": "ADDON_SLUG",
"name": "NAME",
"version": "INSTALLED_VERSION",
"size": "SIZE_IN_MB"
}
],
"repositories": ["URL"],
"folders": ["NAME"]
}
```
- POST `/snapshots/{slug}/remove`
- GET `/snapshots/{slug}/download`
- POST `/snapshots/{slug}/restore/full`
```json
{
"password": "Optional"
}
```
- POST `/snapshots/{slug}/restore/partial`
```json
{
"homeassistant": "bool",
"addons": ["ADDON_SLUG"],
"folders": ["FOLDER_NAME"],
"password": "Optional"
}
```
### Host
- POST `/host/reload`
- POST `/host/shutdown`
- POST `/host/reboot`
- GET `/host/info`
```json
{
"hostname": "hostname|null",
"features": ["shutdown", "reboot", "hostname", "services", "hassos"],
"operating_system": "HassOS XY|Ubuntu 16.4|null",
"kernel": "4.15.7|null",
"chassis": "specific|null",
"deployment": "stable|beta|dev|null",
"cpe": "xy|null",
}
```
- POST `/host/options`
```json
{
"hostname": "",
}
```
- POST `/host/reload`
#### Services
- GET `/host/services`
```json
{
"services": [
{
"name": "xy.service",
"description": "XY ...",
"state": "active|"
}
]
}
```
- POST `/host/service/{unit}/stop`
- POST `/host/service/{unit}/start`
- POST `/host/service/{unit}/reload`
### HassOS
- GET `/hassos/info`
```json
{
"version": "2.3",
"version_cli": "7",
"version_latest": "2.4",
"version_cli_latest": "8",
"board": "ova|rpi"
}
```
- POST `/hassos/update`
```json
{
"version": "optional"
}
```
- POST `/hassos/update/cli`
```json
{
"version": "optional"
}
```
- POST `/hassos/config/sync`
Load host configs from a USB stick.
### Hardware
- GET `/hardware/info`
```json
{
"serial": ["/dev/xy"],
"input": ["Input device name"],
"disk": ["/dev/sdax"],
"gpio": ["gpiochip0", "gpiochip100"],
"audio": {
"CARD_ID": {
"name": "xy",
"type": "microphone",
"devices": [
"chan_id": "channel ID",
"chan_type": "type of device"
]
}
}
}
```
- GET `/hardware/audio`
```json
{
"audio": {
"input": {
"0,0": "Mic"
},
"output": {
"1,0": "Jack",
"1,1": "HDMI"
}
}
}
```
### Home Assistant
- GET `/homeassistant/info`
```json
{
"version": "INSTALL_VERSION",
"last_version": "LAST_VERSION",
"arch": "arch",
"machine": "Image machine type",
"ip_address": "ip address",
"image": "str",
"custom": "bool -> if custom image",
"boot": "bool",
"port": 8123,
"ssl": "bool",
"watchdog": "bool",
"wait_boot": 600
}
```
- POST `/homeassistant/update`
Optional:
```json
{
"version": "VERSION"
}
```
- GET `/homeassistant/logs`
Output is the raw Docker log.
- POST `/homeassistant/restart`
- POST `/homeassistant/check`
- POST `/homeassistant/start`
- POST `/homeassistant/stop`
- POST `/homeassistant/rebuild`
- POST `/homeassistant/options`
```json
{
"image": "Optional|null",
"last_version": "Optional for custom image|null",
"port": "port for access hass",
"ssl": "bool",
"password": "",
"refresh_token": "",
"watchdog": "bool",
"wait_boot": 600
}
```
Image with `null` and last_version with `null` reset this options.
- POST/GET `/homeassistant/api`
Proxy to real home-assistant instance.
- GET `/homeassistant/websocket`
Proxy to real websocket instance.
- GET `/homeassistant/stats`
```json
{
"cpu_percent": 0.0,
"memory_usage": 283123,
"memory_limit": 329392,
"network_tx": 0,
"network_rx": 0,
"blk_read": 0,
"blk_write": 0
}
```
### RESTful for API addons
If an add-on will call itself, you can use `/addons/self/...`.
- GET `/addons`
Get all available addons.
```json
{
"addons": [
{
"name": "xy bla",
"slug": "xy",
"description": "description",
"repository": "core|local|REP_ID",
"version": "LAST_VERSION",
"installed": "none|INSTALL_VERSION",
"detached": "bool",
"available": "bool",
"build": "bool",
"url": "null|url",
"icon": "bool",
"logo": "bool"
}
],
"repositories": [
{
"slug": "12345678",
"name": "Repitory Name|unknown",
"source": "URL_OF_REPOSITORY",
"url": "WEBSITE|REPOSITORY",
"maintainer": "BLA BLU <fla@dld.ch>|unknown"
}
]
}
```
- POST `/addons/reload`
- GET `/addons/{addon}/info`
```json
{
"name": "xy bla",
"slug": "xdssd_xybla",
"description": "description",
"long_description": "null|markdown",
"auto_update": "bool",
"url": "null|url of addon",
"detached": "bool",
"available": "bool",
"arch": ["armhf", "aarch64", "i386", "amd64"],
"machine": "[raspberrypi2, tinker]",
"homeassistant": "null|min Home Assistant version",
"repository": "12345678|null",
"version": "null|VERSION_INSTALLED",
"last_version": "LAST_VERSION",
"state": "none|started|stopped",
"boot": "auto|manual",
"build": "bool",
"options": "{}",
"network": "{}|null",
"network_description": "{}|null",
"host_network": "bool",
"host_pid": "bool",
"host_ipc": "bool",
"host_dbus": "bool",
"privileged": ["NET_ADMIN", "SYS_ADMIN"],
"apparmor": "disable|default|profile",
"devices": ["/dev/xy"],
"auto_uart": "bool",
"icon": "bool",
"logo": "bool",
"changelog": "bool",
"hassio_api": "bool",
"hassio_role": "default|homeassistant|manager|admin",
"homeassistant_api": "bool",
"auth_api": "bool",
"full_access": "bool",
"protected": "bool",
"rating": "1-6",
"stdin": "bool",
"webui": "null|http(s)://[HOST]:port/xy/zx",
"gpio": "bool",
"kernel_modules": "bool",
"devicetree": "bool",
"docker_api": "bool",
"audio": "bool",
"audio_input": "null|0,0",
"audio_output": "null|0,0",
"services_role": "['service:access']",
"discovery": "['service']",
"ip_address": "ip address",
"ingress": "bool",
"ingress_entry": "null|/api/hassio_ingress/slug",
"ingress_url": "null|/api/hassio_ingress/slug/entry.html",
"ingress_port": "null|int"
}
```
- GET `/addons/{addon}/icon`
- GET `/addons/{addon}/logo`
- GET `/addons/{addon}/changelog`
- POST `/addons/{addon}/options`
```json
{
"boot": "auto|manual",
"auto_update": "bool",
"network": {
"CONTAINER": "port|[ip, port]"
},
"options": {},
"audio_output": "null|0,0",
"audio_input": "null|0,0"
}
```
Reset custom network/audio/options, set it `null`.
- POST `/addons/{addon}/security`
This function is not callable by itself.
```json
{
"protected": "bool",
}
```
- POST `/addons/{addon}/start`
- POST `/addons/{addon}/stop`
- POST `/addons/{addon}/install`
- POST `/addons/{addon}/uninstall`
- POST `/addons/{addon}/update`
- GET `/addons/{addon}/logs`
Output is the raw Docker log.
- POST `/addons/{addon}/restart`
- POST `/addons/{addon}/rebuild`
Only supported for local build addons
- POST `/addons/{addon}/stdin`
Write data to add-on stdin
- GET `/addons/{addon}/stats`
```json
{
"cpu_percent": 0.0,
"memory_usage": 283123,
"memory_limit": 329392,
"network_tx": 0,
"network_rx": 0,
"blk_read": 0,
"blk_write": 0
}
```
### ingress
- POST `/ingress/session`
Create a new Session for access to ingress service.
```json
{
"session": "token"
}
```
- VIEW `/ingress/{token}`
Ingress WebUI for this Add-on. The addon need support HASS Auth!
Need ingress session as cookie.
### discovery
- GET `/discovery`
```json
{
"discovery": [
{
"addon": "slug",
"service": "name",
"uuid": "uuid",
"config": {}
}
]
}
```
- GET `/discovery/{UUID}`
```json
{
"addon": "slug",
"service": "name",
"uuid": "uuid",
"config": {}
}
```
- POST `/discovery`
```json
{
"service": "name",
"config": {}
}
```
return:
```json
{
"uuid": "uuid"
}
```
- DEL `/discovery/{UUID}`
### Services
- GET `/services`
```json
{
"services": [
{
"slug": "name",
"available": "bool",
"providers": "list"
}
]
}
```
#### MQTT
- GET `/services/mqtt`
```json
{
"addon": "name",
"host": "xy",
"port": "8883",
"ssl": "bool",
"username": "optional",
"password": "optional",
"protocol": "3.1.1"
}
```
- POST `/services/mqtt`
```json
{
"host": "xy",
"port": "8883",
"ssl": "bool|optional",
"username": "optional",
"password": "optional",
"protocol": "3.1.1"
}
```
- DEL `/services/mqtt`
### Misc
- GET `/info`
```json
{
"supervisor": "version",
"homeassistant": "version",
"hassos": "null|version",
"hostname": "name",
"machine": "type",
"arch": "arch",
"supported_arch": ["arch1", "arch2"],
"channel": "stable|beta|dev",
"logging": "debug|info|warning|error|critical"
}
```
### Auth / SSO API
You can use the user system on homeassistant. We handle this auth system on
supervisor.
You can call post `/auth`
We support:
- Json `{ "user|name": "...", "password": "..." }`
- application/x-www-form-urlencoded `user|name=...&password=...`
- BasicAuth

View File

@@ -1,33 +1,40 @@
ARG BUILD_FROM
FROM $BUILD_FROM
ENV \
S6_SERVICES_GRACETIME=10000 \
SUPERVISOR_API=http://localhost
# Install base
RUN apk add --no-cache \
openssl \
libffi \
musl \
git \
socat \
glib \
libstdc++ \
eudev-libs
RUN \
apk add --no-cache \
eudev \
eudev-libs \
git \
glib \
libffi \
libpulse \
musl \
openssl
ARG BUILD_ARCH
WORKDIR /usr/src
# Install requirements
COPY requirements.txt /usr/src/
RUN apk add --no-cache --virtual .build-dependencies \
make \
g++ \
openssl-dev \
libffi-dev \
musl-dev \
&& export MAKEFLAGS="-j$(nproc)" \
&& pip3 install --no-cache-dir -r /usr/src/requirements.txt \
&& apk del .build-dependencies \
&& rm -f /usr/src/requirements.txt
COPY requirements.txt .
RUN \
export MAKEFLAGS="-j$(nproc)" \
&& pip3 install --no-cache-dir --no-index --only-binary=:all: --find-links \
"https://wheels.home-assistant.io/alpine-$(cut -d '.' -f 1-2 < /etc/alpine-release)/${BUILD_ARCH}/" \
-r ./requirements.txt \
&& rm -f requirements.txt
# Install HassIO
COPY . /usr/src/hassio
RUN pip3 install --no-cache-dir /usr/src/hassio \
&& rm -rf /usr/src/hassio
# Install Home Assistant Supervisor
COPY . supervisor
RUN \
pip3 install --no-cache-dir -e ./supervisor \
&& python3 -m compileall ./supervisor/supervisor
CMD [ "python3", "-m", "hassio" ]
WORKDIR /
COPY rootfs /

View File

@@ -178,7 +178,7 @@
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "{}"
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
@@ -186,7 +186,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright 2017 Pascal Vizeli
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.

View File

@@ -1,3 +1,3 @@
include LICENSE.md
graft hassio
graft supervisor
recursive-exclude * *.py[co]

View File

@@ -1,28 +1,32 @@
# Hass.io
# Home Assistant Supervisor
## First private cloud solution for home automation
Hass.io is a Docker-based system for managing your Home Assistant installation
and related applications. The system is controlled via Home Assistant which
communicates with the Supervisor. The Supervisor provides an API to manage the
installation. This includes changing network settings or installing
and updating software.
![](misc/hassio.png?raw=true)
Home Assistant (former Hass.io) is a container-based system for managing your
Home Assistant Core installation and related applications. The system is
controlled via Home Assistant which communicates with the Supervisor. The
Supervisor provides an API to manage the installation. This includes changing
network settings or installing and updating software.
## Installation
Installation instructions can be found at <https://home-assistant.io/hassio>.
Installation instructions can be found at https://home-assistant.io/getting-started.
## Development
The development of the supervisor is a bit tricky. Not difficult but tricky.
For small changes and bugfixes you can just follow this, but for significant changes open a RFC first.
Development instructions can be found [here][development].
- You can use the builder to build your supervisor: https://github.com/home-assistant/hassio-build/tree/master/builder
- Go into a HassOS device or VM and pull your supervisor.
- Set the developer modus on updater.json
- Tag it as `homeassistant/xy-hassio-supervisor:latest`
- Restart the service like `systemctl restart hassos-supervisor | journalctl -fu hassos-supervisor`
- Test your changes
## Release
Small Bugfix or improvements, make a PR. Significant change makes first an RFC.
Releases are done in 3 stages (channels) with this structure:
1. Pull requests are merged to the `main` branch.
2. A new build is pushed to the `dev` stage.
3. Releases are published.
4. A new build is pushed to the `beta` stage.
5. The [`stable.json`][stable] file is updated.
6. The build that was pushed to `beta` will now be pushed to `stable`.
[development]: https://developers.home-assistant.io/docs/supervisor/development
[stable]: https://github.com/home-assistant/version/blob/master/stable.json

View File

@@ -1,45 +0,0 @@
# Python package
# Create and test a Python package on multiple Python versions.
# Add steps that analyze code, save the dist with the build record, publish to a PyPI-compatible index, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/python
trigger:
- master
- dev
pr:
- dev
jobs:
- job: "Tox"
pool:
vmImage: 'ubuntu-16.04'
steps:
- task: UsePythonVersion@0
displayName: 'Use Python $(python.version)'
inputs:
versionSpec: '3.7'
- script: pip install tox
displayName: 'Install Tox'
- script: tox
displayName: 'Run Tox'
- job: "JQ"
pool:
vmImage: 'ubuntu-16.04'
steps:
- script: sudo apt-get install -y jq
displayName: 'Install JQ'
- bash: |
shopt -s globstar
cat **/*.json | jq '.'
displayName: 'Run JQ'

13
build.json Normal file
View File

@@ -0,0 +1,13 @@
{
"image": "homeassistant/{arch}-hassio-supervisor",
"build_from": {
"aarch64": "homeassistant/aarch64-base-python:3.8-alpine3.13",
"armhf": "homeassistant/armhf-base-python:3.8-alpine3.13",
"armv7": "homeassistant/armv7-base-python:3.8-alpine3.13",
"amd64": "homeassistant/amd64-base-python:3.8-alpine3.13",
"i386": "homeassistant/i386-base-python:3.8-alpine3.13"
},
"labels": {
"io.hass.type": "supervisor"
}
}

11
codecov.yaml Normal file
View File

@@ -0,0 +1,11 @@
codecov:
branch: dev
coverage:
status:
project:
default:
target: 40
threshold: 0.09
comment: false
github_checks:
annotations: false

View File

@@ -1 +0,0 @@
"""Init file for Hass.io."""

View File

@@ -1,60 +0,0 @@
"""Main file for Hass.io."""
import asyncio
from concurrent.futures import ThreadPoolExecutor
import logging
import sys
from hassio import bootstrap
_LOGGER = logging.getLogger(__name__)
def initialize_event_loop():
"""Attempt to use uvloop."""
try:
import uvloop
uvloop.install()
except ImportError:
pass
return asyncio.get_event_loop()
# pylint: disable=invalid-name
if __name__ == "__main__":
bootstrap.initialize_logging()
# Init async event loop
loop = initialize_event_loop()
# Check if all information are available to setup Hass.io
if not bootstrap.check_environment():
sys.exit(1)
# init executor pool
executor = ThreadPoolExecutor(thread_name_prefix="SyncWorker")
loop.set_default_executor(executor)
_LOGGER.info("Initialize Hass.io setup")
coresys = loop.run_until_complete(bootstrap.initialize_coresys())
bootstrap.migrate_system_env(coresys)
_LOGGER.info("Setup HassIO")
loop.run_until_complete(coresys.core.setup())
loop.call_soon_threadsafe(loop.create_task, coresys.core.start())
loop.call_soon_threadsafe(bootstrap.reg_signal, loop)
try:
_LOGGER.info("Run Hass.io")
loop.run_forever()
finally:
_LOGGER.info("Stopping Hass.io")
loop.run_until_complete(coresys.core.stop())
executor.shutdown(wait=False)
loop.close()
_LOGGER.info("Close Hass.io")
sys.exit(0)

View File

@@ -1,158 +0,0 @@
"""Init file for Hass.io add-ons."""
import asyncio
import logging
from .addon import Addon
from .repository import Repository
from .data import AddonsData
from ..const import REPOSITORY_CORE, REPOSITORY_LOCAL, BOOT_AUTO, STATE_STARTED
from ..coresys import CoreSysAttributes
_LOGGER = logging.getLogger(__name__)
BUILTIN_REPOSITORIES = set((REPOSITORY_CORE, REPOSITORY_LOCAL))
class AddonManager(CoreSysAttributes):
"""Manage add-ons inside Hass.io."""
def __init__(self, coresys):
"""Initialize Docker base wrapper."""
self.coresys = coresys
self.data = AddonsData(coresys)
self.addons_obj = {}
self.repositories_obj = {}
@property
def list_addons(self):
"""Return a list of all add-ons."""
return list(self.addons_obj.values())
@property
def list_installed(self):
"""Return a list of installed add-ons."""
return [addon for addon in self.addons_obj.values()
if addon.is_installed]
@property
def list_repositories(self):
"""Return list of add-on repositories."""
return list(self.repositories_obj.values())
def get(self, addon_slug):
"""Return an add-on from slug."""
return self.addons_obj.get(addon_slug)
def from_token(self, token):
"""Return an add-on from Hass.io token."""
for addon in self.list_addons:
if addon.is_installed and token == addon.hassio_token:
return addon
return None
async def load(self):
"""Start up add-on management."""
self.data.reload()
# Init Hass.io built-in repositories
repositories = \
set(self.sys_config.addons_repositories) | BUILTIN_REPOSITORIES
# Init custom repositories and load add-ons
await self.load_repositories(repositories)
async def reload(self):
"""Update add-ons from repository and reload list."""
tasks = [repository.update() for repository in
self.repositories_obj.values()]
if tasks:
await asyncio.wait(tasks)
# read data from repositories
self.data.reload()
# update addons
await self.load_addons()
async def load_repositories(self, list_repositories):
"""Add a new custom repository."""
new_rep = set(list_repositories)
old_rep = set(self.repositories_obj)
# add new repository
async def _add_repository(url):
"""Helper function to async add repository."""
repository = Repository(self.coresys, url)
if not await repository.load():
_LOGGER.error("Can't load from repository %s", url)
return
self.repositories_obj[url] = repository
# don't add built-in repository to config
if url not in BUILTIN_REPOSITORIES:
self.sys_config.add_addon_repository(url)
tasks = [_add_repository(url) for url in new_rep - old_rep]
if tasks:
await asyncio.wait(tasks)
# del new repository
for url in old_rep - new_rep - BUILTIN_REPOSITORIES:
self.repositories_obj.pop(url).remove()
self.sys_config.drop_addon_repository(url)
# update data
self.data.reload()
await self.load_addons()
async def load_addons(self):
"""Update/add internal add-on store."""
all_addons = set(self.data.system) | set(self.data.cache)
# calc diff
add_addons = all_addons - set(self.addons_obj)
del_addons = set(self.addons_obj) - all_addons
_LOGGER.info("Load add-ons: %d all - %d new - %d remove",
len(all_addons), len(add_addons), len(del_addons))
# new addons
tasks = []
for addon_slug in add_addons:
addon = Addon(self.coresys, addon_slug)
tasks.append(addon.load())
self.addons_obj[addon_slug] = addon
if tasks:
await asyncio.wait(tasks)
# remove
for addon_slug in del_addons:
self.addons_obj.pop(addon_slug)
async def boot(self, stage):
"""Boot add-ons with mode auto."""
tasks = []
for addon in self.addons_obj.values():
if addon.is_installed and addon.boot == BOOT_AUTO and \
addon.startup == stage:
tasks.append(addon.start())
_LOGGER.info("Startup %s run %d add-ons", stage, len(tasks))
if tasks:
await asyncio.wait(tasks)
await asyncio.sleep(self.sys_config.wait_boot)
async def shutdown(self, stage):
"""Shutdown addons."""
tasks = []
for addon in self.addons_obj.values():
if addon.is_installed and \
await addon.state() == STATE_STARTED and \
addon.startup == stage:
tasks.append(addon.stop())
_LOGGER.info("Shutdown %s stop %d add-ons", stage, len(tasks))
if tasks:
await asyncio.wait(tasks)

File diff suppressed because it is too large Load Diff

View File

@@ -1,82 +0,0 @@
"""Hass.io add-on build environment."""
from __future__ import annotations
from pathlib import Path
from typing import TYPE_CHECKING, Dict
from ..const import ATTR_ARGS, ATTR_BUILD_FROM, ATTR_SQUASH, META_ADDON
from ..coresys import CoreSys, CoreSysAttributes
from ..utils.json import JsonConfig
from .validate import SCHEMA_BUILD_CONFIG
if TYPE_CHECKING:
from .addon import Addon
class AddonBuild(JsonConfig, CoreSysAttributes):
"""Handle build options for add-ons."""
def __init__(self, coresys: CoreSys, slug: str) -> None:
"""Initialize Hass.io add-on builder."""
self.coresys: CoreSys = coresys
self._id: str = slug
super().__init__(
Path(self.addon.path_location, 'build.json'), SCHEMA_BUILD_CONFIG)
def save_data(self):
"""Ignore save function."""
@property
def addon(self) -> Addon:
"""Return add-on of build data."""
return self.sys_addons.get(self._id)
@property
def base_image(self) -> str:
"""Base images for this add-on."""
return self._data[ATTR_BUILD_FROM].get(
self.sys_arch.default,
f"homeassistant/{self.sys_arch.default}-base:latest")
@property
def squash(self) -> bool:
"""Return True or False if squash is active."""
return self._data[ATTR_SQUASH]
@property
def additional_args(self) -> Dict[str, str]:
"""Return additional Docker build arguments."""
return self._data[ATTR_ARGS]
def get_docker_args(self, version):
"""Create a dict with Docker build arguments."""
args = {
'path': str(self.addon.path_location),
'tag': f"{self.addon.image}:{version}",
'pull': True,
'forcerm': True,
'squash': self.squash,
'labels': {
'io.hass.version': version,
'io.hass.arch': self.sys_arch.default,
'io.hass.type': META_ADDON,
'io.hass.name': self._fix_label('name'),
'io.hass.description': self._fix_label('description'),
},
'buildargs': {
'BUILD_FROM': self.base_image,
'BUILD_VERSION': version,
'BUILD_ARCH': self.sys_arch.default,
**self.additional_args,
}
}
if self.addon.url:
args['labels']['io.hass.url'] = self.addon.url
return args
def _fix_label(self, label_name: str) -> str:
"""Remove characters they are not supported."""
label = getattr(self.addon, label_name, "")
return label.replace("'", "")

View File

@@ -1,136 +0,0 @@
"""Init file for Hass.io add-on data."""
import logging
from pathlib import Path
import voluptuous as vol
from voluptuous.humanize import humanize_error
from ..const import (
ATTR_LOCATON,
ATTR_REPOSITORY,
ATTR_SLUG,
ATTR_SYSTEM,
ATTR_USER,
FILE_HASSIO_ADDONS,
REPOSITORY_CORE,
REPOSITORY_LOCAL,
)
from ..coresys import CoreSysAttributes
from ..exceptions import JsonFileError
from ..utils.json import JsonConfig, read_json_file
from .utils import extract_hash_from_path
from .validate import SCHEMA_ADDON_CONFIG, SCHEMA_ADDONS_FILE, SCHEMA_REPOSITORY_CONFIG
_LOGGER = logging.getLogger(__name__)
class AddonsData(JsonConfig, CoreSysAttributes):
"""Hold data for Add-ons inside Hass.io."""
def __init__(self, coresys):
"""Initialize data holder."""
super().__init__(FILE_HASSIO_ADDONS, SCHEMA_ADDONS_FILE)
self.coresys = coresys
self._repositories = {}
self._cache = {}
@property
def user(self):
"""Return local add-on user data."""
return self._data[ATTR_USER]
@property
def system(self):
"""Return local add-on data."""
return self._data[ATTR_SYSTEM]
@property
def cache(self):
"""Return add-on data from cache/repositories."""
return self._cache
@property
def repositories(self):
"""Return add-on data from repositories."""
return self._repositories
def reload(self):
"""Read data from add-on repository."""
self._cache = {}
self._repositories = {}
# read core repository
self._read_addons_folder(self.sys_config.path_addons_core, REPOSITORY_CORE)
# read local repository
self._read_addons_folder(self.sys_config.path_addons_local, REPOSITORY_LOCAL)
# add built-in repositories information
self._set_builtin_repositories()
# read custom git repositories
for repository_element in self.sys_config.path_addons_git.iterdir():
if repository_element.is_dir():
self._read_git_repository(repository_element)
def _read_git_repository(self, path):
"""Process a custom repository folder."""
slug = extract_hash_from_path(path)
# exists repository json
repository_file = Path(path, "repository.json")
try:
repository_info = SCHEMA_REPOSITORY_CONFIG(read_json_file(repository_file))
except JsonFileError:
_LOGGER.warning(
"Can't read repository information from %s", repository_file
)
return
except vol.Invalid:
_LOGGER.warning("Repository parse error %s", repository_file)
return
# process data
self._repositories[slug] = repository_info
self._read_addons_folder(path, slug)
def _read_addons_folder(self, path, repository):
"""Read data from add-ons folder."""
for addon in path.glob("**/config.json"):
try:
addon_config = read_json_file(addon)
except JsonFileError:
_LOGGER.warning("Can't read %s from repository %s", addon, repository)
continue
# validate
try:
addon_config = SCHEMA_ADDON_CONFIG(addon_config)
except vol.Invalid as ex:
_LOGGER.warning(
"Can't read %s: %s", addon, humanize_error(addon_config, ex)
)
continue
# Generate slug
addon_slug = "{}_{}".format(repository, addon_config[ATTR_SLUG])
# store
addon_config[ATTR_REPOSITORY] = repository
addon_config[ATTR_LOCATON] = str(addon.parent)
self._cache[addon_slug] = addon_config
def _set_builtin_repositories(self):
"""Add local built-in repository into dataset."""
try:
builtin_file = Path(__file__).parent.joinpath("built-in.json")
builtin_data = read_json_file(builtin_file)
except JsonFileError:
_LOGGER.warning("Can't read built-in json")
return
# core repository
self._repositories[REPOSITORY_CORE] = builtin_data[REPOSITORY_CORE]
# local repository
self._repositories[REPOSITORY_LOCAL] = builtin_data[REPOSITORY_LOCAL]

View File

@@ -1,155 +0,0 @@
"""Init file for Hass.io add-on Git."""
import asyncio
import logging
import functools as ft
from pathlib import Path
import shutil
import git
from .utils import get_hash_from_repository
from ..const import URL_HASSIO_ADDONS, ATTR_URL, ATTR_BRANCH
from ..coresys import CoreSysAttributes
from ..validate import RE_REPOSITORY
_LOGGER = logging.getLogger(__name__)
class GitRepo(CoreSysAttributes):
"""Manage Add-on Git repository."""
def __init__(self, coresys, path, url):
"""Initialize Git base wrapper."""
self.coresys = coresys
self.repo = None
self.path = path
self.lock = asyncio.Lock(loop=coresys.loop)
self._data = RE_REPOSITORY.match(url).groupdict()
@property
def url(self):
"""Return repository URL."""
return self._data[ATTR_URL]
@property
def branch(self):
"""Return repository branch."""
return self._data[ATTR_BRANCH]
async def load(self):
"""Init Git add-on repository."""
if not self.path.is_dir():
return await self.clone()
async with self.lock:
try:
_LOGGER.info("Load add-on %s repository", self.path)
self.repo = await self.sys_run_in_executor(
git.Repo, str(self.path))
except (git.InvalidGitRepositoryError, git.NoSuchPathError,
git.GitCommandError) as err:
_LOGGER.error("Can't load %s repo: %s.", self.path, err)
self._remove()
return False
return True
async def clone(self):
"""Clone git add-on repository."""
async with self.lock:
git_args = {
attribute: value
for attribute, value in (
('recursive', True),
('branch', self.branch),
('depth', 1),
('shallow-submodules', True)
) if value is not None
}
try:
_LOGGER.info("Clone add-on %s repository", self.url)
self.repo = await self.sys_run_in_executor(ft.partial(
git.Repo.clone_from, self.url, str(self.path),
**git_args
))
except (git.InvalidGitRepositoryError, git.NoSuchPathError,
git.GitCommandError) as err:
_LOGGER.error("Can't clone %s repository: %s.", self.url, err)
self._remove()
return False
return True
async def pull(self):
"""Pull Git add-on repo."""
if self.lock.locked():
_LOGGER.warning("It is already a task in progress")
return False
async with self.lock:
_LOGGER.info("Update add-on %s repository", self.url)
branch = self.repo.active_branch.name
try:
# Download data
await self.sys_run_in_executor(ft.partial(
self.repo.remotes.origin.fetch, **{
'update-shallow': True,
'depth': 1,
}))
# Jump on top of that
await self.sys_run_in_executor(ft.partial(
self.repo.git.reset, f"origin/{branch}", hard=True))
# Cleanup old data
await self.sys_run_in_executor(ft.partial(
self.repo.git.clean, "-xdf"))
except (git.InvalidGitRepositoryError, git.NoSuchPathError,
git.GitCommandError) as err:
_LOGGER.error("Can't update %s repo: %s.", self.url, err)
return False
return True
def _remove(self):
"""Remove a repository."""
if not self.path.is_dir():
return
def log_err(funct, path, _):
"""Log error."""
_LOGGER.warning("Can't remove %s", path)
shutil.rmtree(str(self.path), onerror=log_err)
class GitRepoHassIO(GitRepo):
"""Hass.io add-ons repository."""
def __init__(self, coresys):
"""Initialize Git Hass.io add-on repository."""
super().__init__(
coresys, coresys.config.path_addons_core, URL_HASSIO_ADDONS)
class GitRepoCustom(GitRepo):
"""Custom add-ons repository."""
def __init__(self, coresys, url):
"""Initialize custom Git Hass.io addo-n repository."""
path = Path(
coresys.config.path_addons_git,
get_hash_from_repository(url))
super().__init__(coresys, path, url)
def remove(self):
"""Remove a custom repository."""
_LOGGER.info("Remove custom add-on repository %s", self.url)
self._remove()

View File

@@ -1,73 +0,0 @@
"""Represent a Hass.io repository."""
from .git import GitRepoHassIO, GitRepoCustom
from .utils import get_hash_from_repository
from ..const import (
REPOSITORY_CORE, REPOSITORY_LOCAL, ATTR_NAME, ATTR_URL, ATTR_MAINTAINER)
from ..coresys import CoreSysAttributes
from ..exceptions import APIError
UNKNOWN = 'unknown'
class Repository(CoreSysAttributes):
"""Repository in Hass.io."""
def __init__(self, coresys, repository):
"""Initialize repository object."""
self.coresys = coresys
self.source = None
self.git = None
if repository == REPOSITORY_LOCAL:
self._id = repository
elif repository == REPOSITORY_CORE:
self._id = repository
self.git = GitRepoHassIO(coresys)
else:
self._id = get_hash_from_repository(repository)
self.git = GitRepoCustom(coresys, repository)
self.source = repository
@property
def _mesh(self):
"""Return data struct repository."""
return self.sys_addons.data.repositories.get(self._id, {})
@property
def slug(self):
"""Return slug of repository."""
return self._id
@property
def name(self):
"""Return name of repository."""
return self._mesh.get(ATTR_NAME, UNKNOWN)
@property
def url(self):
"""Return URL of repository."""
return self._mesh.get(ATTR_URL, self.source)
@property
def maintainer(self):
"""Return url of repository."""
return self._mesh.get(ATTR_MAINTAINER, UNKNOWN)
async def load(self):
"""Load addon repository."""
if self.git:
return await self.git.load()
return True
async def update(self):
"""Update add-on repository."""
if self.git:
return await self.git.pull()
return True
def remove(self):
"""Remove add-on repository."""
if self._id in (REPOSITORY_CORE, REPOSITORY_LOCAL):
raise APIError("Can't remove built-in repositories!")
self.git.remove()

View File

@@ -1,131 +0,0 @@
"""Util add-ons functions."""
from __future__ import annotations
import asyncio
import hashlib
import logging
from pathlib import Path
import re
from typing import TYPE_CHECKING
from ..const import (
PRIVILEGED_DAC_READ_SEARCH,
PRIVILEGED_NET_ADMIN,
PRIVILEGED_SYS_ADMIN,
PRIVILEGED_SYS_MODULE,
PRIVILEGED_SYS_PTRACE,
PRIVILEGED_SYS_RAWIO,
ROLE_ADMIN,
ROLE_MANAGER,
SECURITY_DISABLE,
SECURITY_PROFILE,
)
from ..exceptions import AddonsNotSupportedError
if TYPE_CHECKING:
from .addon import Addon
RE_SHA1 = re.compile(r"[a-f0-9]{8}")
_LOGGER = logging.getLogger(__name__)
def rating_security(addon: Addon) -> int:
"""Return 1-6 for security rating.
1 = not secure
6 = high secure
"""
rating = 5
# AppArmor
if addon.apparmor == SECURITY_DISABLE:
rating += -1
elif addon.apparmor == SECURITY_PROFILE:
rating += 1
# Home Assistant Login
if addon.access_auth_api:
rating += 1
# Privileged options
if any(
privilege in addon.privileged
for privilege in (
PRIVILEGED_NET_ADMIN,
PRIVILEGED_SYS_ADMIN,
PRIVILEGED_SYS_RAWIO,
PRIVILEGED_SYS_PTRACE,
PRIVILEGED_SYS_MODULE,
PRIVILEGED_DAC_READ_SEARCH,
)
):
rating += -1
# API Hass.io role
if addon.hassio_role == ROLE_MANAGER:
rating += -1
elif addon.hassio_role == ROLE_ADMIN:
rating += -2
# Not secure Networking
if addon.host_network:
rating += -1
# Insecure PID namespace
if addon.host_pid:
rating += -2
# Full Access
if addon.with_full_access:
rating += -2
# Docker Access
if addon.access_docker_api:
rating = 1
return max(min(6, rating), 1)
def get_hash_from_repository(name: str) -> str:
"""Generate a hash from repository."""
key = name.lower().encode()
return hashlib.sha1(key).hexdigest()[:8]
def extract_hash_from_path(path: Path) -> str:
"""Extract repo id from path."""
repository_dir = path.parts[-1]
if not RE_SHA1.match(repository_dir):
return get_hash_from_repository(repository_dir)
return repository_dir
def check_installed(method):
"""Wrap function with check if add-on is installed."""
async def wrap_check(addon, *args, **kwargs):
"""Return False if not installed or the function."""
if not addon.is_installed:
_LOGGER.error("Addon %s is not installed", addon.slug)
raise AddonsNotSupportedError()
return await method(addon, *args, **kwargs)
return wrap_check
async def remove_data(folder: Path) -> None:
"""Remove folder and reset privileged."""
try:
proc = await asyncio.create_subprocess_exec(
"rm", "-rf", str(folder), stdout=asyncio.subprocess.DEVNULL
)
_, error_msg = await proc.communicate()
except OSError as err:
error_msg = str(err)
else:
if proc.returncode == 0:
return
_LOGGER.error("Can't remove Add-on Data: %s", error_msg)

View File

@@ -1,383 +0,0 @@
"""Validate add-ons options schema."""
import logging
import re
import secrets
import uuid
import voluptuous as vol
from ..const import (
ARCH_ALL,
ATTR_ACCESS_TOKEN,
ATTR_APPARMOR,
ATTR_ARCH,
ATTR_ARGS,
ATTR_AUDIO,
ATTR_AUDIO_INPUT,
ATTR_AUDIO_OUTPUT,
ATTR_AUTH_API,
ATTR_AUTO_UART,
ATTR_AUTO_UPDATE,
ATTR_BOOT,
ATTR_BUILD_FROM,
ATTR_DESCRIPTON,
ATTR_DEVICES,
ATTR_DEVICETREE,
ATTR_DISCOVERY,
ATTR_DOCKER_API,
ATTR_ENVIRONMENT,
ATTR_FULL_ACCESS,
ATTR_GPIO,
ATTR_HASSIO_API,
ATTR_HASSIO_ROLE,
ATTR_HOMEASSISTANT,
ATTR_HOMEASSISTANT_API,
ATTR_HOST_DBUS,
ATTR_HOST_IPC,
ATTR_HOST_NETWORK,
ATTR_HOST_PID,
ATTR_IMAGE,
ATTR_INGRESS,
ATTR_INGRESS_ENTRY,
ATTR_INGRESS_PORT,
ATTR_INGRESS_TOKEN,
ATTR_KERNEL_MODULES,
ATTR_LEGACY,
ATTR_LOCATON,
ATTR_MACHINE,
ATTR_MAINTAINER,
ATTR_MAP,
ATTR_NAME,
ATTR_NETWORK,
ATTR_OPTIONS,
ATTR_PORTS,
ATTR_PORTS_DESCRIPTION,
ATTR_PRIVILEGED,
ATTR_PROTECTED,
ATTR_REPOSITORY,
ATTR_SCHEMA,
ATTR_SERVICES,
ATTR_SLUG,
ATTR_SQUASH,
ATTR_STARTUP,
ATTR_STATE,
ATTR_STDIN,
ATTR_SYSTEM,
ATTR_TIMEOUT,
ATTR_TMPFS,
ATTR_URL,
ATTR_USER,
ATTR_UUID,
ATTR_VERSION,
ATTR_WEBUI,
BOOT_AUTO,
BOOT_MANUAL,
PRIVILEGED_ALL,
ROLE_ALL,
ROLE_DEFAULT,
STARTUP_ALL,
STARTUP_APPLICATION,
STARTUP_SERVICES,
STATE_STARTED,
STATE_STOPPED,
)
from ..discovery.validate import valid_discovery_service
from ..validate import (
ALSA_DEVICE,
DOCKER_PORTS,
DOCKER_PORTS_DESCRIPTION,
NETWORK_PORT,
TOKEN,
UUID_MATCH,
)
_LOGGER = logging.getLogger(__name__)
RE_VOLUME = re.compile(r"^(config|ssl|addons|backup|share)(?::(rw|ro))?$")
RE_SERVICE = re.compile(r"^(?P<service>mqtt):(?P<rights>provide|want|need)$")
V_STR = 'str'
V_INT = 'int'
V_FLOAT = 'float'
V_BOOL = 'bool'
V_EMAIL = 'email'
V_URL = 'url'
V_PORT = 'port'
V_MATCH = 'match'
RE_SCHEMA_ELEMENT = re.compile(
r"^(?:"
r"|str|bool|email|url|port"
r"|int(?:\((?P<i_min>\d+)?,(?P<i_max>\d+)?\))?"
r"|float(?:\((?P<f_min>[\d\.]+)?,(?P<f_max>[\d\.]+)?\))?"
r"|match\((?P<match>.*)\)"
r")\??$"
)
RE_DOCKER_IMAGE = re.compile(
r"^([a-zA-Z\-\.:\d{}]+/)*?([\-\w{}]+)/([\-\w{}]+)$")
RE_DOCKER_IMAGE_BUILD = re.compile(
r"^([a-zA-Z\-\.:\d{}]+/)*?([\-\w{}]+)/([\-\w{}]+)(:[\.\-\w{}]+)?$")
SCHEMA_ELEMENT = vol.Match(RE_SCHEMA_ELEMENT)
MACHINE_ALL = [
'intel-nuc', 'odroid-c2', 'odroid-xu', 'orangepi-prime', 'qemux86',
'qemux86-64', 'qemuarm', 'qemuarm-64', 'raspberrypi', 'raspberrypi2',
'raspberrypi3', 'raspberrypi3-64', 'tinker',
]
def _simple_startup(value):
"""Simple startup schema."""
if value == "before":
return STARTUP_SERVICES
if value == "after":
return STARTUP_APPLICATION
return value
# pylint: disable=no-value-for-parameter
SCHEMA_ADDON_CONFIG = vol.Schema({
vol.Required(ATTR_NAME): vol.Coerce(str),
vol.Required(ATTR_VERSION): vol.Coerce(str),
vol.Required(ATTR_SLUG): vol.Coerce(str),
vol.Required(ATTR_DESCRIPTON): vol.Coerce(str),
vol.Required(ATTR_ARCH): [vol.In(ARCH_ALL)],
vol.Optional(ATTR_MACHINE): [vol.In(MACHINE_ALL)],
vol.Optional(ATTR_URL): vol.Url(),
vol.Required(ATTR_STARTUP):
vol.All(_simple_startup, vol.In(STARTUP_ALL)),
vol.Required(ATTR_BOOT):
vol.In([BOOT_AUTO, BOOT_MANUAL]),
vol.Optional(ATTR_PORTS): DOCKER_PORTS,
vol.Optional(ATTR_PORTS_DESCRIPTION): DOCKER_PORTS_DESCRIPTION,
vol.Optional(ATTR_WEBUI):
vol.Match(r"^(?:https?|\[PROTO:\w+\]):\/\/\[HOST\]:\[PORT:\d+\].*$"),
vol.Optional(ATTR_INGRESS, default=False): vol.Boolean(),
vol.Optional(ATTR_INGRESS_PORT, default=8099): vol.Any(NETWORK_PORT, vol.Equal(0)),
vol.Optional(ATTR_INGRESS_ENTRY): vol.Coerce(str),
vol.Optional(ATTR_HOMEASSISTANT): vol.Maybe(vol.Coerce(str)),
vol.Optional(ATTR_HOST_NETWORK, default=False): vol.Boolean(),
vol.Optional(ATTR_HOST_PID, default=False): vol.Boolean(),
vol.Optional(ATTR_HOST_IPC, default=False): vol.Boolean(),
vol.Optional(ATTR_HOST_DBUS, default=False): vol.Boolean(),
vol.Optional(ATTR_DEVICES): [vol.Match(r"^(.*):(.*):([rwm]{1,3})$")],
vol.Optional(ATTR_AUTO_UART, default=False): vol.Boolean(),
vol.Optional(ATTR_TMPFS):
vol.Match(r"^size=(\d)*[kmg](,uid=\d{1,4})?(,rw)?$"),
vol.Optional(ATTR_MAP, default=list): [vol.Match(RE_VOLUME)],
vol.Optional(ATTR_ENVIRONMENT): {vol.Match(r"\w*"): vol.Coerce(str)},
vol.Optional(ATTR_PRIVILEGED): [vol.In(PRIVILEGED_ALL)],
vol.Optional(ATTR_APPARMOR, default=True): vol.Boolean(),
vol.Optional(ATTR_FULL_ACCESS, default=False): vol.Boolean(),
vol.Optional(ATTR_AUDIO, default=False): vol.Boolean(),
vol.Optional(ATTR_GPIO, default=False): vol.Boolean(),
vol.Optional(ATTR_DEVICETREE, default=False): vol.Boolean(),
vol.Optional(ATTR_KERNEL_MODULES, default=False): vol.Boolean(),
vol.Optional(ATTR_HASSIO_API, default=False): vol.Boolean(),
vol.Optional(ATTR_HASSIO_ROLE, default=ROLE_DEFAULT): vol.In(ROLE_ALL),
vol.Optional(ATTR_HOMEASSISTANT_API, default=False): vol.Boolean(),
vol.Optional(ATTR_STDIN, default=False): vol.Boolean(),
vol.Optional(ATTR_LEGACY, default=False): vol.Boolean(),
vol.Optional(ATTR_DOCKER_API, default=False): vol.Boolean(),
vol.Optional(ATTR_AUTH_API, default=False): vol.Boolean(),
vol.Optional(ATTR_SERVICES): [vol.Match(RE_SERVICE)],
vol.Optional(ATTR_DISCOVERY): [valid_discovery_service],
vol.Required(ATTR_OPTIONS): dict,
vol.Required(ATTR_SCHEMA): vol.Any(vol.Schema({
vol.Coerce(str): vol.Any(SCHEMA_ELEMENT, [
vol.Any(
SCHEMA_ELEMENT,
{vol.Coerce(str): vol.Any(SCHEMA_ELEMENT, [SCHEMA_ELEMENT])}
),
], vol.Schema({
vol.Coerce(str): vol.Any(SCHEMA_ELEMENT, [SCHEMA_ELEMENT])
}))
}), False),
vol.Optional(ATTR_IMAGE):
vol.Match(RE_DOCKER_IMAGE),
vol.Optional(ATTR_TIMEOUT, default=10):
vol.All(vol.Coerce(int), vol.Range(min=10, max=120)),
}, extra=vol.REMOVE_EXTRA)
# pylint: disable=no-value-for-parameter
SCHEMA_REPOSITORY_CONFIG = vol.Schema({
vol.Required(ATTR_NAME): vol.Coerce(str),
vol.Optional(ATTR_URL): vol.Url(),
vol.Optional(ATTR_MAINTAINER): vol.Coerce(str),
}, extra=vol.REMOVE_EXTRA)
# pylint: disable=no-value-for-parameter
SCHEMA_BUILD_CONFIG = vol.Schema({
vol.Optional(ATTR_BUILD_FROM, default=dict): vol.Schema({
vol.In(ARCH_ALL): vol.Match(RE_DOCKER_IMAGE_BUILD),
}),
vol.Optional(ATTR_SQUASH, default=False): vol.Boolean(),
vol.Optional(ATTR_ARGS, default=dict): vol.Schema({
vol.Coerce(str): vol.Coerce(str)
}),
}, extra=vol.REMOVE_EXTRA)
# pylint: disable=no-value-for-parameter
SCHEMA_ADDON_USER = vol.Schema({
vol.Required(ATTR_VERSION): vol.Coerce(str),
vol.Optional(ATTR_IMAGE): vol.Coerce(str),
vol.Optional(ATTR_UUID, default=lambda: uuid.uuid4().hex): UUID_MATCH,
vol.Optional(ATTR_ACCESS_TOKEN): TOKEN,
vol.Optional(ATTR_INGRESS_TOKEN, default=secrets.token_urlsafe): vol.Coerce(str),
vol.Optional(ATTR_OPTIONS, default=dict): dict,
vol.Optional(ATTR_AUTO_UPDATE, default=False): vol.Boolean(),
vol.Optional(ATTR_BOOT):
vol.In([BOOT_AUTO, BOOT_MANUAL]),
vol.Optional(ATTR_NETWORK): DOCKER_PORTS,
vol.Optional(ATTR_AUDIO_OUTPUT): ALSA_DEVICE,
vol.Optional(ATTR_AUDIO_INPUT): ALSA_DEVICE,
vol.Optional(ATTR_PROTECTED, default=True): vol.Boolean(),
}, extra=vol.REMOVE_EXTRA)
SCHEMA_ADDON_SYSTEM = SCHEMA_ADDON_CONFIG.extend({
vol.Required(ATTR_LOCATON): vol.Coerce(str),
vol.Required(ATTR_REPOSITORY): vol.Coerce(str),
})
SCHEMA_ADDONS_FILE = vol.Schema({
vol.Optional(ATTR_USER, default=dict): {
vol.Coerce(str): SCHEMA_ADDON_USER,
},
vol.Optional(ATTR_SYSTEM, default=dict): {
vol.Coerce(str): SCHEMA_ADDON_SYSTEM,
}
})
SCHEMA_ADDON_SNAPSHOT = vol.Schema({
vol.Required(ATTR_USER): SCHEMA_ADDON_USER,
vol.Required(ATTR_SYSTEM): SCHEMA_ADDON_SYSTEM,
vol.Required(ATTR_STATE): vol.In([STATE_STARTED, STATE_STOPPED]),
vol.Required(ATTR_VERSION): vol.Coerce(str),
}, extra=vol.REMOVE_EXTRA)
def validate_options(raw_schema):
"""Validate schema."""
def validate(struct):
"""Create schema validator for add-ons options."""
options = {}
# read options
for key, value in struct.items():
# Ignore unknown options / remove from list
if key not in raw_schema:
_LOGGER.warning("Unknown options %s", key)
continue
typ = raw_schema[key]
try:
if isinstance(typ, list):
# nested value list
options[key] = _nested_validate_list(typ[0], value, key)
elif isinstance(typ, dict):
# nested value dict
options[key] = _nested_validate_dict(typ, value, key)
else:
# normal value
options[key] = _single_validate(typ, value, key)
except (IndexError, KeyError):
raise vol.Invalid(f"Type error for {key}") from None
_check_missing_options(raw_schema, options, 'root')
return options
return validate
# pylint: disable=no-value-for-parameter
# pylint: disable=inconsistent-return-statements
def _single_validate(typ, value, key):
"""Validate a single element."""
# if required argument
if value is None:
raise vol.Invalid(f"Missing required option '{key}'")
# parse extend data from type
match = RE_SCHEMA_ELEMENT.match(typ)
# prepare range
range_args = {}
for group_name in ('i_min', 'i_max', 'f_min', 'f_max'):
group_value = match.group(group_name)
if group_value:
range_args[group_name[2:]] = float(group_value)
if typ.startswith(V_STR):
return str(value)
elif typ.startswith(V_INT):
return vol.All(vol.Coerce(int), vol.Range(**range_args))(value)
elif typ.startswith(V_FLOAT):
return vol.All(vol.Coerce(float), vol.Range(**range_args))(value)
elif typ.startswith(V_BOOL):
return vol.Boolean()(value)
elif typ.startswith(V_EMAIL):
return vol.Email()(value)
elif typ.startswith(V_URL):
return vol.Url()(value)
elif typ.startswith(V_PORT):
return NETWORK_PORT(value)
elif typ.startswith(V_MATCH):
return vol.Match(match.group('match'))(str(value))
raise vol.Invalid(f"Fatal error for {key} type {typ}")
def _nested_validate_list(typ, data_list, key):
"""Validate nested items."""
options = []
for element in data_list:
# Nested?
if isinstance(typ, dict):
c_options = _nested_validate_dict(typ, element, key)
options.append(c_options)
else:
options.append(_single_validate(typ, element, key))
return options
def _nested_validate_dict(typ, data_dict, key):
"""Validate nested items."""
options = {}
for c_key, c_value in data_dict.items():
# Ignore unknown options / remove from list
if c_key not in typ:
_LOGGER.warning("Unknown options %s", c_key)
continue
# Nested?
if isinstance(typ[c_key], list):
options[c_key] = _nested_validate_list(typ[c_key][0],
c_value, c_key)
else:
options[c_key] = _single_validate(typ[c_key], c_value, c_key)
_check_missing_options(typ, options, key)
return options
def _check_missing_options(origin, exists, root):
"""Check if all options are exists."""
missing = set(origin) - set(exists)
for miss_opt in missing:
if isinstance(origin[miss_opt], str) and \
origin[miss_opt].endswith("?"):
continue
raise vol.Invalid(f"Missing option {miss_opt} in {root}")

View File

@@ -1,296 +0,0 @@
"""Init file for Hass.io RESTful API."""
import logging
from pathlib import Path
from typing import Optional
from aiohttp import web
from ..coresys import CoreSys, CoreSysAttributes
from .addons import APIAddons
from .auth import APIAuth
from .discovery import APIDiscovery
from .hardware import APIHardware
from .hassos import APIHassOS
from .homeassistant import APIHomeAssistant
from .host import APIHost
from .info import APIInfo
from .ingress import APIIngress
from .proxy import APIProxy
from .security import SecurityMiddleware
from .services import APIServices
from .snapshots import APISnapshots
from .supervisor import APISupervisor
_LOGGER = logging.getLogger(__name__)
class RestAPI(CoreSysAttributes):
"""Handle RESTful API for Hass.io."""
def __init__(self, coresys: CoreSys):
"""Initialize Docker base wrapper."""
self.coresys: CoreSys = coresys
self.security: SecurityMiddleware = SecurityMiddleware(coresys)
self.webapp: web.Application = web.Application(
middlewares=[self.security.token_validation])
# service stuff
self._runner: web.AppRunner = web.AppRunner(self.webapp)
self._site: Optional[web.TCPSite] = None
async def load(self) -> None:
"""Register REST API Calls."""
self._register_supervisor()
self._register_host()
self._register_hassos()
self._register_hardware()
self._register_homeassistant()
self._register_proxy()
self._register_panel()
self._register_addons()
self._register_ingress()
self._register_snapshots()
self._register_discovery()
self._register_services()
self._register_info()
self._register_auth()
def _register_host(self) -> None:
"""Register hostcontrol functions."""
api_host = APIHost()
api_host.coresys = self.coresys
self.webapp.add_routes([
web.get('/host/info', api_host.info),
web.post('/host/reboot', api_host.reboot),
web.post('/host/shutdown', api_host.shutdown),
web.post('/host/reload', api_host.reload),
web.post('/host/options', api_host.options),
web.get('/host/services', api_host.services),
web.post('/host/services/{service}/stop', api_host.service_stop),
web.post('/host/services/{service}/start', api_host.service_start),
web.post('/host/services/{service}/restart',
api_host.service_restart),
web.post('/host/services/{service}/reload',
api_host.service_reload),
])
def _register_hassos(self) -> None:
"""Register HassOS functions."""
api_hassos = APIHassOS()
api_hassos.coresys = self.coresys
self.webapp.add_routes([
web.get('/hassos/info', api_hassos.info),
web.post('/hassos/update', api_hassos.update),
web.post('/hassos/update/cli', api_hassos.update_cli),
web.post('/hassos/config/sync', api_hassos.config_sync),
])
def _register_hardware(self) -> None:
"""Register hardware functions."""
api_hardware = APIHardware()
api_hardware.coresys = self.coresys
self.webapp.add_routes([
web.get('/hardware/info', api_hardware.info),
web.get('/hardware/audio', api_hardware.audio),
])
def _register_info(self) -> None:
"""Register info functions."""
api_info = APIInfo()
api_info.coresys = self.coresys
self.webapp.add_routes([
web.get('/info', api_info.info),
])
def _register_auth(self) -> None:
"""Register auth functions."""
api_auth = APIAuth()
api_auth.coresys = self.coresys
self.webapp.add_routes([
web.post('/auth', api_auth.auth),
])
def _register_supervisor(self) -> None:
"""Register Supervisor functions."""
api_supervisor = APISupervisor()
api_supervisor.coresys = self.coresys
self.webapp.add_routes([
web.get('/supervisor/ping', api_supervisor.ping),
web.get('/supervisor/info', api_supervisor.info),
web.get('/supervisor/stats', api_supervisor.stats),
web.get('/supervisor/logs', api_supervisor.logs),
web.post('/supervisor/update', api_supervisor.update),
web.post('/supervisor/reload', api_supervisor.reload),
web.post('/supervisor/options', api_supervisor.options),
])
def _register_homeassistant(self) -> None:
"""Register Home Assistant functions."""
api_hass = APIHomeAssistant()
api_hass.coresys = self.coresys
self.webapp.add_routes([
web.get('/homeassistant/info', api_hass.info),
web.get('/homeassistant/logs', api_hass.logs),
web.get('/homeassistant/stats', api_hass.stats),
web.post('/homeassistant/options', api_hass.options),
web.post('/homeassistant/update', api_hass.update),
web.post('/homeassistant/restart', api_hass.restart),
web.post('/homeassistant/stop', api_hass.stop),
web.post('/homeassistant/start', api_hass.start),
web.post('/homeassistant/check', api_hass.check),
web.post('/homeassistant/rebuild', api_hass.rebuild),
])
def _register_proxy(self) -> None:
"""Register Home Assistant API Proxy."""
api_proxy = APIProxy()
api_proxy.coresys = self.coresys
self.webapp.add_routes([
web.get('/homeassistant/api/websocket', api_proxy.websocket),
web.get('/homeassistant/websocket', api_proxy.websocket),
web.get('/homeassistant/api/stream', api_proxy.stream),
web.post('/homeassistant/api/{path:.+}', api_proxy.api),
web.get('/homeassistant/api/{path:.+}', api_proxy.api),
web.get('/homeassistant/api/', api_proxy.api),
])
def _register_addons(self) -> None:
"""Register Add-on functions."""
api_addons = APIAddons()
api_addons.coresys = self.coresys
self.webapp.add_routes([
web.get('/addons', api_addons.list),
web.post('/addons/reload', api_addons.reload),
web.get('/addons/{addon}/info', api_addons.info),
web.post('/addons/{addon}/install', api_addons.install),
web.post('/addons/{addon}/uninstall', api_addons.uninstall),
web.post('/addons/{addon}/start', api_addons.start),
web.post('/addons/{addon}/stop', api_addons.stop),
web.post('/addons/{addon}/restart', api_addons.restart),
web.post('/addons/{addon}/update', api_addons.update),
web.post('/addons/{addon}/options', api_addons.options),
web.post('/addons/{addon}/rebuild', api_addons.rebuild),
web.get('/addons/{addon}/logs', api_addons.logs),
web.get('/addons/{addon}/icon', api_addons.icon),
web.get('/addons/{addon}/logo', api_addons.logo),
web.get('/addons/{addon}/changelog', api_addons.changelog),
web.post('/addons/{addon}/stdin', api_addons.stdin),
web.post('/addons/{addon}/security', api_addons.security),
web.get('/addons/{addon}/stats', api_addons.stats),
])
def _register_ingress(self) -> None:
"""Register Ingress functions."""
api_ingress = APIIngress()
api_ingress.coresys = self.coresys
self.webapp.add_routes([
web.post('/ingress/session', api_ingress.create_session),
web.view('/ingress/{token}/{path:.*}', api_ingress.handler),
])
def _register_snapshots(self) -> None:
"""Register snapshots functions."""
api_snapshots = APISnapshots()
api_snapshots.coresys = self.coresys
self.webapp.add_routes([
web.get('/snapshots', api_snapshots.list),
web.post('/snapshots/reload', api_snapshots.reload),
web.post('/snapshots/new/full', api_snapshots.snapshot_full),
web.post('/snapshots/new/partial', api_snapshots.snapshot_partial),
web.post('/snapshots/new/upload', api_snapshots.upload),
web.get('/snapshots/{snapshot}/info', api_snapshots.info),
web.post('/snapshots/{snapshot}/remove', api_snapshots.remove),
web.post('/snapshots/{snapshot}/restore/full',
api_snapshots.restore_full),
web.post('/snapshots/{snapshot}/restore/partial',
api_snapshots.restore_partial),
web.get('/snapshots/{snapshot}/download', api_snapshots.download),
])
def _register_services(self) -> None:
"""Register services functions."""
api_services = APIServices()
api_services.coresys = self.coresys
self.webapp.add_routes([
web.get('/services', api_services.list),
web.get('/services/{service}', api_services.get_service),
web.post('/services/{service}', api_services.set_service),
web.delete('/services/{service}', api_services.del_service),
])
def _register_discovery(self) -> None:
"""Register discovery functions."""
api_discovery = APIDiscovery()
api_discovery.coresys = self.coresys
self.webapp.add_routes([
web.get('/discovery', api_discovery.list),
web.get('/discovery/{uuid}', api_discovery.get_discovery),
web.delete('/discovery/{uuid}', api_discovery.del_discovery),
web.post('/discovery', api_discovery.set_discovery),
])
def _register_panel(self) -> None:
"""Register panel for Home Assistant."""
panel_dir = Path(__file__).parent.joinpath("panel")
def create_response(panel_file):
"""Create a function to generate a response."""
path = panel_dir.joinpath(f"{panel_file!s}.html")
return lambda request: web.FileResponse(path)
# This route is for backwards compatibility with HA < 0.58
self.webapp.add_routes(
[web.get('/panel', create_response('hassio-main-es5'))])
# This route is for backwards compatibility with HA 0.58 - 0.61
self.webapp.add_routes([
web.get('/panel_es5', create_response('hassio-main-es5')),
web.get('/panel_latest', create_response('hassio-main-latest')),
])
# This route is for backwards compatibility with HA 0.62 - 0.70
self.webapp.add_routes([
web.get('/app-es5/index.html', create_response('index')),
web.get('/app-es5/hassio-app.html', create_response('hassio-app')),
])
# This route is for HA > 0.70
self.webapp.add_routes([web.static('/app', panel_dir)])
async def start(self) -> None:
"""Run RESTful API webserver."""
await self._runner.setup()
self._site = web.TCPSite(
self._runner, host="0.0.0.0", port=80, shutdown_timeout=5)
try:
await self._site.start()
except OSError as err:
_LOGGER.fatal("Failed to create HTTP server at 0.0.0.0:80 -> %s",
err)
else:
_LOGGER.info("Start API on %s", self.sys_docker.network.supervisor)
async def stop(self) -> None:
"""Stop RESTful API webserver."""
if not self._site:
return
# Shutdown running API
await self._site.stop()
await self._runner.cleanup()
_LOGGER.info("Stop API on %s", self.sys_docker.network.supervisor)

View File

@@ -1,61 +0,0 @@
"""Init file for Hass.io auth/SSO RESTful API."""
import logging
from aiohttp import BasicAuth
from aiohttp.web_exceptions import HTTPUnauthorized
from aiohttp.hdrs import CONTENT_TYPE, AUTHORIZATION, WWW_AUTHENTICATE
from .utils import api_process
from ..const import REQUEST_FROM, CONTENT_TYPE_JSON, CONTENT_TYPE_URL
from ..coresys import CoreSysAttributes
from ..exceptions import APIForbidden
_LOGGER = logging.getLogger(__name__)
class APIAuth(CoreSysAttributes):
"""Handle RESTful API for auth functions."""
def _process_basic(self, request, addon):
"""Process login request with basic auth.
Return a coroutine.
"""
auth = BasicAuth.decode(request.headers[AUTHORIZATION])
return self.sys_auth.check_login(addon, auth.login, auth.password)
def _process_dict(self, request, addon, data):
"""Process login with dict data.
Return a coroutine.
"""
username = data.get('username') or data.get('user')
password = data.get('password')
return self.sys_auth.check_login(addon, username, password)
@api_process
async def auth(self, request):
"""Process login request."""
addon = request[REQUEST_FROM]
if not addon.access_auth_api:
raise APIForbidden("Can't use Home Assistant auth!")
# BasicAuth
if AUTHORIZATION in request.headers:
return await self._process_basic(request, addon)
# Json
if request.headers.get(CONTENT_TYPE) == CONTENT_TYPE_JSON:
data = await request.json()
return await self._process_dict(request, addon, data)
# URL encoded
if request.headers.get(CONTENT_TYPE) == CONTENT_TYPE_URL:
data = await request.post()
return await self._process_dict(request, addon, data)
raise HTTPUnauthorized(headers={
WWW_AUTHENTICATE: "Basic realm=\"Hass.io Authentication\""
})

View File

@@ -1,34 +0,0 @@
"""Init file for Hass.io hardware RESTful API."""
import logging
from .utils import api_process
from ..const import (
ATTR_SERIAL, ATTR_DISK, ATTR_GPIO, ATTR_AUDIO, ATTR_INPUT, ATTR_OUTPUT)
from ..coresys import CoreSysAttributes
_LOGGER = logging.getLogger(__name__)
class APIHardware(CoreSysAttributes):
"""Handle RESTful API for hardware functions."""
@api_process
async def info(self, request):
"""Show hardware info."""
return {
ATTR_SERIAL: list(self.sys_hardware.serial_devices),
ATTR_INPUT: list(self.sys_hardware.input_devices),
ATTR_DISK: list(self.sys_hardware.disk_devices),
ATTR_GPIO: list(self.sys_hardware.gpio_devices),
ATTR_AUDIO: self.sys_hardware.audio_devices,
}
@api_process
async def audio(self, request):
"""Show ALSA audio devices."""
return {
ATTR_AUDIO: {
ATTR_INPUT: self.sys_host.alsa.input_devices,
ATTR_OUTPUT: self.sys_host.alsa.output_devices,
}
}

View File

@@ -1,57 +0,0 @@
"""Init file for Hass.io HassOS RESTful API."""
import asyncio
import logging
from typing import Any, Awaitable, Dict
import voluptuous as vol
from aiohttp import web
from ..const import (
ATTR_BOARD,
ATTR_VERSION,
ATTR_VERSION_CLI,
ATTR_VERSION_CLI_LATEST,
ATTR_VERSION_LATEST,
)
from ..coresys import CoreSysAttributes
from .utils import api_process, api_validate
_LOGGER = logging.getLogger(__name__)
SCHEMA_VERSION = vol.Schema({vol.Optional(ATTR_VERSION): vol.Coerce(str)})
class APIHassOS(CoreSysAttributes):
"""Handle RESTful API for HassOS functions."""
@api_process
async def info(self, request: web.Request) -> Dict[str, Any]:
"""Return HassOS information."""
return {
ATTR_VERSION: self.sys_hassos.version,
ATTR_VERSION_CLI: self.sys_hassos.version_cli,
ATTR_VERSION_LATEST: self.sys_hassos.version_latest,
ATTR_VERSION_CLI_LATEST: self.sys_hassos.version_cli_latest,
ATTR_BOARD: self.sys_hassos.board,
}
@api_process
async def update(self, request: web.Request) -> None:
"""Update HassOS."""
body = await api_validate(SCHEMA_VERSION, request)
version = body.get(ATTR_VERSION, self.sys_hassos.version_latest)
await asyncio.shield(self.sys_hassos.update(version))
@api_process
async def update_cli(self, request: web.Request) -> None:
"""Update HassOS CLI."""
body = await api_validate(SCHEMA_VERSION, request)
version = body.get(ATTR_VERSION, self.sys_hassos.version_cli_latest)
await asyncio.shield(self.sys_hassos.update_cli(version))
@api_process
def config_sync(self, request: web.Request) -> Awaitable[None]:
"""Trigger config reload on HassOS."""
return asyncio.shield(self.sys_hassos.config_sync())

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1 +0,0 @@
(window.webpackJsonp=window.webpackJsonp||[]).push([[7],{102:function(n,r,t){"use strict";t.r(r),t.d(r,"marked",function(){return a}),t.d(r,"filterXSS",function(){return c});var e=t(121),i=t.n(e),o=t(123),u=t.n(o),a=i.a,c=u.a}}]);

File diff suppressed because one or more lines are too long

View File

@@ -1 +0,0 @@
{"version":3,"sources":[],"names":[],"mappings":"","file":"chunk.510634470d399e194ace.js","sourceRoot":""}

File diff suppressed because one or more lines are too long

View File

@@ -1,21 +0,0 @@
/**
@license
Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
This code may only be used under the BSD style license found at
http://polymer.github.io/LICENSE.txt The complete set of authors may be found at
http://polymer.github.io/AUTHORS.txt The complete set of contributors may be
found at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by Google as
part of the polymer project is also subject to an additional IP rights grant
found at http://polymer.github.io/PATENTS.txt
*/
/**
@license
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
This code may only be used under the BSD style license found at
http://polymer.github.io/LICENSE.txt The complete set of authors may be found at
http://polymer.github.io/AUTHORS.txt The complete set of contributors may be
found at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by Google as
part of the polymer project is also subject to an additional IP rights grant
found at http://polymer.github.io/PATENTS.txt
*/

View File

@@ -1 +0,0 @@
{"version":3,"sources":[],"names":[],"mappings":"","file":"chunk.564a2f7b1c38ddaa4ce0.js","sourceRoot":""}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1,32 +0,0 @@
/**
@license
Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
Code distributed by Google as part of the polymer project is also
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
*/
/**
* @fileoverview
* @suppress {checkPrototypalTypes}
* @license Copyright (c) 2017 The Polymer Project Authors. All rights reserved.
* This code may only be used under the BSD style license found at
* http://polymer.github.io/LICENSE.txt The complete set of authors may be found
* at http://polymer.github.io/AUTHORS.txt The complete set of contributors may
* be found at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by
* Google as part of the polymer project is also subject to an additional IP
* rights grant found at http://polymer.github.io/PATENTS.txt
*/
/**
@license
Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
This code may only be used under the BSD style license found at
http://polymer.github.io/LICENSE.txt The complete set of authors may be found at
http://polymer.github.io/AUTHORS.txt The complete set of contributors may be
found at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by Google as
part of the polymer project is also subject to an additional IP rights grant
found at http://polymer.github.io/PATENTS.txt
*/

View File

@@ -1 +0,0 @@
{"version":3,"sources":[],"names":[],"mappings":"","file":"chunk.659084fef4e3b7b66a76.js","sourceRoot":""}

File diff suppressed because one or more lines are too long

View File

@@ -1,31 +0,0 @@
/**
@license
Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
This code may only be used under the BSD style license found at
http://polymer.github.io/LICENSE.txt The complete set of authors may be found at
http://polymer.github.io/AUTHORS.txt The complete set of contributors may be
found at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by Google as
part of the polymer project is also subject to an additional IP rights grant
found at http://polymer.github.io/PATENTS.txt
*/
/**
@license
Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
Code distributed by Google as part of the polymer project is also
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
*/
/**
@license
Copyright (c) 2016 The Polymer Project Authors. All rights reserved.
This code may only be used under the BSD style license found at
http://polymer.github.io/LICENSE.txt The complete set of authors may be found at
http://polymer.github.io/AUTHORS.txt The complete set of contributors may be
found at http://polymer.github.io/CONTRIBUTORS.txt Code distributed by Google as
part of the polymer project is also subject to an additional IP rights grant
found at http://polymer.github.io/PATENTS.txt
*/

View File

@@ -1 +0,0 @@
{"version":3,"sources":[],"names":[],"mappings":"","file":"chunk.6e9c87e51920a9c354e5.js","sourceRoot":""}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1 +0,0 @@
{"version":3,"sources":[],"names":[],"mappings":"","file":"chunk.a7e5fb452cd1b3a5faef.js","sourceRoot":""}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1 +0,0 @@
{"version":3,"sources":[],"names":[],"mappings":"","file":"chunk.f15d7f41c0d302cbbc7a.js","sourceRoot":""}

View File

@@ -1 +0,0 @@
!function(e){function n(n){for(var t,o,a=n[0],i=n[1],c=0,u=[];c<a.length;c++)o=a[c],r[o]&&u.push(r[o][0]),r[o]=0;for(t in i)Object.prototype.hasOwnProperty.call(i,t)&&(e[t]=i[t]);for(f&&f(n);u.length;)u.shift()()}var t={},r={4:0};function o(n){if(t[n])return t[n].exports;var r=t[n]={i:n,l:!1,exports:{}};return e[n].call(r.exports,r,r.exports,o),r.l=!0,r.exports}o.e=function(e){var n=[],t=r[e];if(0!==t)if(t)n.push(t[2]);else{var a=new Promise(function(n,o){t=r[e]=[n,o]});n.push(t[2]=a);var i,c=document.createElement("script");c.charset="utf-8",c.timeout=120,o.nc&&c.setAttribute("nonce",o.nc),c.src=function(e){return o.p+"chunk."+{0:"564a2f7b1c38ddaa4ce0",1:"659084fef4e3b7b66a76",2:"510634470d399e194ace",3:"f15d7f41c0d302cbbc7a",5:"5d31a1778f717ac8b063",6:"0d97375a72c194aae1ac",7:"3a63ad36bccf4ea567fa",8:"a571dfa106202cc57af6",9:"a7e5fb452cd1b3a5faef",10:"b3340b3df270d20af4a1",11:"6e9c87e51920a9c354e5",12:"352e12b12df29c09b455",13:"739b67c99ab56cdbd75d"}[e]+".js"}(e),i=function(n){c.onerror=c.onload=null,clearTimeout(f);var t=r[e];if(0!==t){if(t){var o=n&&("load"===n.type?"missing":n.type),a=n&&n.target&&n.target.src,i=new Error("Loading chunk "+e+" failed.\n("+o+": "+a+")");i.type=o,i.request=a,t[1](i)}r[e]=void 0}};var f=setTimeout(function(){i({type:"timeout",target:c})},12e4);c.onerror=c.onload=i,document.head.appendChild(c)}return Promise.all(n)},o.m=e,o.c=t,o.d=function(e,n,t){o.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:t})},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.t=function(e,n){if(1&n&&(e=o(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var t=Object.create(null);if(o.r(t),Object.defineProperty(t,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var r in e)o.d(t,r,function(n){return e[n]}.bind(null,r));return t},o.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(n,"a",n),n},o.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},o.p="/api/hassio/app/",o.oe=function(e){throw console.error(e),e};var a=window.webpackJsonp=window.webpackJsonp||[],i=a.push.bind(a);a.push=n,a=a.slice();for(var c=0;c<a.length;c++)n(a[c]);var f=i;o(o.s=0)}([function(e,n,t){window.loadES5Adapter().then(function(){Promise.all([t.e(1),t.e(5)]).then(t.bind(null,2)),Promise.all([t.e(1),t.e(9),t.e(6)]).then(t.bind(null,1))});var r=document.createElement("style");r.innerHTML="\nbody {\n font-family: Roboto, sans-serif;\n -moz-osx-font-smoothing: grayscale;\n -webkit-font-smoothing: antialiased;\n font-weight: 400;\n margin: 0;\n padding: 0;\n height: 100vh;\n}\n",document.head.appendChild(r)}]);

Binary file not shown.

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

Binary file not shown.

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1,38 +0,0 @@
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Hass.io</title>
<meta name='viewport' content='width=device-width, user-scalable=no'>
<style>
body {
height: 100vh;
margin: 0;
padding: 0;
}
</style>
<script src='/frontend_es5/custom-elements-es5-adapter.js'></script>
</head>
<body>
<hassio-app></hassio-app>
<script>
function addScript(src) {
var e = document.createElement('script');
e.src = src;
document.write(e.outerHTML);
}
var webComponentsSupported = (
'customElements' in window &&
'import' in document.createElement('link') &&
'content' in document.createElement('template'));
if (!webComponentsSupported) {
addScript('/static/webcomponents-lite.js');
}
</script>
<!--
Disabled while we make Home Assistant able to serve the right files.
<script src="./app.js"></script>
-->
<link rel='import' href='./hassio-app.html'>
</body>
</html>

Binary file not shown.

View File

@@ -1,157 +0,0 @@
"""Init file for Hass.io Supervisor RESTful API."""
import asyncio
import logging
from typing import Any, Awaitable, Dict
from aiohttp import web
import voluptuous as vol
from ..const import (
ATTR_ADDONS,
ATTR_ADDONS_REPOSITORIES,
ATTR_ARCH,
ATTR_BLK_READ,
ATTR_BLK_WRITE,
ATTR_CHANNEL,
ATTR_CPU_PERCENT,
ATTR_DESCRIPTON,
ATTR_ICON,
ATTR_INSTALLED,
ATTR_IP_ADDRESS,
ATTR_LAST_VERSION,
ATTR_LOGGING,
ATTR_LOGO,
ATTR_MEMORY_LIMIT,
ATTR_MEMORY_USAGE,
ATTR_NAME,
ATTR_NETWORK_RX,
ATTR_NETWORK_TX,
ATTR_REPOSITORY,
ATTR_SLUG,
ATTR_STATE,
ATTR_TIMEZONE,
ATTR_VERSION,
ATTR_WAIT_BOOT,
CONTENT_TYPE_BINARY,
HASSIO_VERSION,
)
from ..coresys import CoreSysAttributes
from ..exceptions import APIError
from ..utils.validate import validate_timezone
from ..validate import CHANNELS, LOG_LEVEL, REPOSITORIES, WAIT_BOOT
from .utils import api_process, api_process_raw, api_validate
_LOGGER = logging.getLogger(__name__)
SCHEMA_OPTIONS = vol.Schema(
{
vol.Optional(ATTR_CHANNEL): CHANNELS,
vol.Optional(ATTR_ADDONS_REPOSITORIES): REPOSITORIES,
vol.Optional(ATTR_TIMEZONE): validate_timezone,
vol.Optional(ATTR_WAIT_BOOT): WAIT_BOOT,
vol.Optional(ATTR_LOGGING): LOG_LEVEL,
}
)
SCHEMA_VERSION = vol.Schema({vol.Optional(ATTR_VERSION): vol.Coerce(str)})
class APISupervisor(CoreSysAttributes):
"""Handle RESTful API for Supervisor functions."""
@api_process
async def ping(self, request):
"""Return ok for signal that the API is ready."""
return True
@api_process
async def info(self, request: web.Request) -> Dict[str, Any]:
"""Return host information."""
list_addons = []
for addon in self.sys_addons.list_addons:
if addon.is_installed:
list_addons.append(
{
ATTR_NAME: addon.name,
ATTR_SLUG: addon.slug,
ATTR_DESCRIPTON: addon.description,
ATTR_STATE: await addon.state(),
ATTR_VERSION: addon.latest_version,
ATTR_INSTALLED: addon.version_installed,
ATTR_REPOSITORY: addon.repository,
ATTR_ICON: addon.with_icon,
ATTR_LOGO: addon.with_logo,
}
)
return {
ATTR_VERSION: HASSIO_VERSION,
ATTR_LAST_VERSION: self.sys_updater.version_hassio,
ATTR_CHANNEL: self.sys_updater.channel,
ATTR_ARCH: self.sys_supervisor.arch,
ATTR_IP_ADDRESS: str(self.sys_supervisor.ip_address),
ATTR_WAIT_BOOT: self.sys_config.wait_boot,
ATTR_TIMEZONE: self.sys_config.timezone,
ATTR_LOGGING: self.sys_config.logging,
ATTR_ADDONS: list_addons,
ATTR_ADDONS_REPOSITORIES: self.sys_config.addons_repositories,
}
@api_process
async def options(self, request: web.Request) -> None:
"""Set Supervisor options."""
body = await api_validate(SCHEMA_OPTIONS, request)
if ATTR_CHANNEL in body:
self.sys_updater.channel = body[ATTR_CHANNEL]
if ATTR_TIMEZONE in body:
self.sys_config.timezone = body[ATTR_TIMEZONE]
if ATTR_WAIT_BOOT in body:
self.sys_config.wait_boot = body[ATTR_WAIT_BOOT]
if ATTR_LOGGING in body:
self.sys_config.logging = body[ATTR_LOGGING]
if ATTR_ADDONS_REPOSITORIES in body:
new = set(body[ATTR_ADDONS_REPOSITORIES])
await asyncio.shield(self.sys_addons.load_repositories(new))
self.sys_updater.save_data()
self.sys_config.save_data()
@api_process
async def stats(self, request: web.Request) -> Dict[str, Any]:
"""Return resource information."""
stats = await self.sys_supervisor.stats()
return {
ATTR_CPU_PERCENT: stats.cpu_percent,
ATTR_MEMORY_USAGE: stats.memory_usage,
ATTR_MEMORY_LIMIT: stats.memory_limit,
ATTR_NETWORK_RX: stats.network_rx,
ATTR_NETWORK_TX: stats.network_tx,
ATTR_BLK_READ: stats.blk_read,
ATTR_BLK_WRITE: stats.blk_write,
}
@api_process
async def update(self, request: web.Request) -> None:
"""Update Supervisor OS."""
body = await api_validate(SCHEMA_VERSION, request)
version = body.get(ATTR_VERSION, self.sys_updater.version_hassio)
if version == self.sys_supervisor.version:
raise APIError("Version {} is already in use".format(version))
await asyncio.shield(self.sys_supervisor.update(version))
@api_process
def reload(self, request: web.Request) -> Awaitable[None]:
"""Reload add-ons, configuration, etc."""
return asyncio.shield(self.sys_updater.reload())
@api_process_raw(CONTENT_TYPE_BINARY)
def logs(self, request: web.Request) -> Awaitable[bytes]:
"""Return supervisor Docker logs."""
return self.sys_supervisor.logs()

View File

@@ -1,95 +0,0 @@
"""Init file for Hass.io util for RESTful API."""
import json
import logging
from aiohttp import web
import voluptuous as vol
from voluptuous.humanize import humanize_error
from ..const import (
JSON_RESULT, JSON_DATA, JSON_MESSAGE, RESULT_OK, RESULT_ERROR,
CONTENT_TYPE_BINARY)
from ..exceptions import HassioError, APIError, APIForbidden
_LOGGER = logging.getLogger(__name__)
def json_loads(data):
"""Extract json from string with support for '' and None."""
if not data:
return {}
try:
return json.loads(data)
except json.JSONDecodeError:
raise APIError("Invalid json")
def api_process(method):
"""Wrap function with true/false calls to rest api."""
async def wrap_api(api, *args, **kwargs):
"""Return API information."""
try:
answer = await method(api, *args, **kwargs)
except (APIError, APIForbidden) as err:
return api_return_error(message=str(err))
except HassioError:
return api_return_error(message="Unknown Error, see logs")
if isinstance(answer, dict):
return api_return_ok(data=answer)
if isinstance(answer, web.Response):
return answer
elif isinstance(answer, bool) and not answer:
return api_return_error()
return api_return_ok()
return wrap_api
def api_process_raw(content):
"""Wrap content_type into function."""
def wrap_method(method):
"""Wrap function with raw output to rest api."""
async def wrap_api(api, *args, **kwargs):
"""Return api information."""
try:
msg_data = await method(api, *args, **kwargs)
msg_type = content
except (APIError, APIForbidden) as err:
msg_data = str(err).encode()
msg_type = CONTENT_TYPE_BINARY
except HassioError:
msg_data = b''
msg_type = CONTENT_TYPE_BINARY
return web.Response(body=msg_data, content_type=msg_type)
return wrap_api
return wrap_method
def api_return_error(message=None):
"""Return an API error message."""
return web.json_response({
JSON_RESULT: RESULT_ERROR,
JSON_MESSAGE: message,
}, status=400)
def api_return_ok(data=None):
"""Return an API ok answer."""
return web.json_response({
JSON_RESULT: RESULT_OK,
JSON_DATA: data or {},
})
async def api_validate(schema, request):
"""Validate request data with schema."""
data = await request.json(loads=json_loads)
try:
data = schema(data)
except vol.Invalid as ex:
raise APIError(humanize_error(data, ex)) from None
return data

View File

@@ -1,49 +0,0 @@
{
"raspberrypi": [
"armhf"
],
"raspberrypi2": [
"armv7",
"armhf"
],
"raspberrypi3": [
"armv7",
"armhf"
],
"raspberrypi3-64": [
"aarch64",
"armv7",
"armhf"
],
"tinker": [
"armv7",
"armhf"
],
"odroid-c2": [
"aarch64"
],
"odroid-xu": [
"armv7",
"armhf"
],
"orangepi-prime": [
"aarch64"
],
"qemux86": [
"i386"
],
"qemux86-64": [
"amd64",
"i386"
],
"qemuarm": [
"armhf"
],
"qemuarm-64": [
"aarch64"
],
"intel-nuc": [
"amd64",
"i386"
]
}

View File

@@ -1,95 +0,0 @@
"""Manage SSO for Add-ons with Home Assistant user."""
import logging
import hashlib
from .const import (
FILE_HASSIO_AUTH, ATTR_PASSWORD, ATTR_USERNAME, ATTR_ADDON)
from .coresys import CoreSysAttributes
from .utils.json import JsonConfig
from .validate import SCHEMA_AUTH_CONFIG
from .exceptions import AuthError, HomeAssistantAPIError
_LOGGER = logging.getLogger(__name__)
class Auth(JsonConfig, CoreSysAttributes):
"""Manage SSO for Add-ons with Home Assistant user."""
def __init__(self, coresys):
"""Initialize updater."""
super().__init__(FILE_HASSIO_AUTH, SCHEMA_AUTH_CONFIG)
self.coresys = coresys
def _check_cache(self, username, password):
"""Check password in cache."""
username_h = _rehash(username)
password_h = _rehash(password, username)
if self._data.get(username_h) == password_h:
_LOGGER.info("Cache hit for %s", username)
return True
_LOGGER.warning("No cache hit for %s", username)
return False
def _update_cache(self, username, password):
"""Cache a username, password."""
username_h = _rehash(username)
password_h = _rehash(password, username)
if self._data.get(username_h) == password_h:
return
self._data[username_h] = password_h
self.save_data()
def _dismatch_cache(self, username, password):
"""Remove user from cache."""
username_h = _rehash(username)
password_h = _rehash(password, username)
if self._data.get(username_h) != password_h:
return
self._data.pop(username_h, None)
self.save_data()
async def check_login(self, addon, username, password):
"""Check username login."""
if password is None:
_LOGGER.error("None as password is not supported!")
raise AuthError()
_LOGGER.info("Auth request from %s for %s", addon.slug, username)
# Check API state
if not await self.sys_homeassistant.check_api_state():
_LOGGER.info("Home Assistant not running, check cache")
return self._check_cache(username, password)
try:
async with self.sys_homeassistant.make_request(
'post', 'api/hassio_auth', json={
ATTR_USERNAME: username,
ATTR_PASSWORD: password,
ATTR_ADDON: addon.slug,
}) as req:
if req.status == 200:
_LOGGER.info("Success login from %s", username)
self._update_cache(username, password)
return True
_LOGGER.warning("Wrong login from %s", username)
self._dismatch_cache(username, password)
return False
except HomeAssistantAPIError:
_LOGGER.error("Can't request auth on Home Assistant!")
raise AuthError()
def _rehash(value, salt2=""):
"""Rehash a value."""
for idx in range(1, 20):
value = hashlib.sha256(f"{value}{idx}{salt2}".encode()).hexdigest()
return value

View File

@@ -1,208 +0,0 @@
"""Bootstrap Hass.io."""
import logging
import os
from pathlib import Path
import shutil
import signal
from colorlog import ColoredFormatter
from .addons import AddonManager
from .api import RestAPI
from .arch import CpuArch
from .auth import Auth
from .const import SOCKET_DOCKER
from .core import HassIO
from .coresys import CoreSys
from .dbus import DBusManager
from .discovery import Discovery
from .hassos import HassOS
from .homeassistant import HomeAssistant
from .host import HostManager
from .ingress import Ingress
from .services import ServiceManager
from .snapshots import SnapshotManager
from .supervisor import Supervisor
from .tasks import Tasks
from .updater import Updater
_LOGGER = logging.getLogger(__name__)
ENV_SHARE = "SUPERVISOR_SHARE"
ENV_NAME = "SUPERVISOR_NAME"
ENV_REPO = "HOMEASSISTANT_REPOSITORY"
MACHINE_ID = Path("/etc/machine-id")
async def initialize_coresys():
"""Initialize HassIO coresys/objects."""
coresys = CoreSys()
# Initialize core objects
coresys.core = HassIO(coresys)
coresys.arch = CpuArch(coresys)
coresys.auth = Auth(coresys)
coresys.updater = Updater(coresys)
coresys.api = RestAPI(coresys)
coresys.supervisor = Supervisor(coresys)
coresys.homeassistant = HomeAssistant(coresys)
coresys.addons = AddonManager(coresys)
coresys.snapshots = SnapshotManager(coresys)
coresys.host = HostManager(coresys)
coresys.ingress = Ingress(coresys)
coresys.tasks = Tasks(coresys)
coresys.services = ServiceManager(coresys)
coresys.discovery = Discovery(coresys)
coresys.dbus = DBusManager(coresys)
coresys.hassos = HassOS(coresys)
# bootstrap config
initialize_system_data(coresys)
# Set Machine/Host ID
if MACHINE_ID.exists():
coresys.machine_id = MACHINE_ID.read_text().strip()
return coresys
def initialize_system_data(coresys):
"""Set up the default configuration and create folders."""
config = coresys.config
# Home Assistant configuration folder
if not config.path_homeassistant.is_dir():
_LOGGER.info(
"Create Home Assistant configuration folder %s", config.path_homeassistant
)
config.path_homeassistant.mkdir()
# hassio ssl folder
if not config.path_ssl.is_dir():
_LOGGER.info("Create Hass.io SSL/TLS folder %s", config.path_ssl)
config.path_ssl.mkdir()
# hassio addon data folder
if not config.path_addons_data.is_dir():
_LOGGER.info("Create Hass.io Add-on data folder %s", config.path_addons_data)
config.path_addons_data.mkdir(parents=True)
if not config.path_addons_local.is_dir():
_LOGGER.info(
"Create Hass.io Add-on local repository folder %s", config.path_addons_local
)
config.path_addons_local.mkdir(parents=True)
if not config.path_addons_git.is_dir():
_LOGGER.info(
"Create Hass.io Add-on git repositories folder %s", config.path_addons_git
)
config.path_addons_git.mkdir(parents=True)
# hassio tmp folder
if not config.path_tmp.is_dir():
_LOGGER.info("Create Hass.io temp folder %s", config.path_tmp)
config.path_tmp.mkdir(parents=True)
# hassio backup folder
if not config.path_backup.is_dir():
_LOGGER.info("Create Hass.io backup folder %s", config.path_backup)
config.path_backup.mkdir()
# share folder
if not config.path_share.is_dir():
_LOGGER.info("Create Hass.io share folder %s", config.path_share)
config.path_share.mkdir()
# apparmor folder
if not config.path_apparmor.is_dir():
_LOGGER.info("Create Hass.io Apparmor folder %s", config.path_apparmor)
config.path_apparmor.mkdir()
return config
def migrate_system_env(coresys):
"""Cleanup some stuff after update."""
config = coresys.config
# hass.io 0.37 -> 0.38
old_build = Path(config.path_hassio, "addons/build")
if old_build.is_dir():
try:
old_build.rmdir()
except OSError:
_LOGGER.warning("Can't cleanup old Add-on build directory")
def initialize_logging():
"""Setup the logging."""
logging.basicConfig(level=logging.INFO)
fmt = "%(asctime)s %(levelname)s (%(threadName)s) [%(name)s] %(message)s"
colorfmt = f"%(log_color)s{fmt}%(reset)s"
datefmt = "%y-%m-%d %H:%M:%S"
# suppress overly verbose logs from libraries that aren't helpful
logging.getLogger("aiohttp.access").setLevel(logging.WARNING)
logging.getLogger().handlers[0].setFormatter(
ColoredFormatter(
colorfmt,
datefmt=datefmt,
reset=True,
log_colors={
"DEBUG": "cyan",
"INFO": "green",
"WARNING": "yellow",
"ERROR": "red",
"CRITICAL": "red",
},
)
)
def check_environment():
"""Check if all environment are exists."""
# check environment variables
for key in (ENV_SHARE, ENV_NAME, ENV_REPO):
try:
os.environ[key]
except KeyError:
_LOGGER.fatal("Can't find %s in env!", key)
return False
# check docker socket
if not SOCKET_DOCKER.is_socket():
_LOGGER.fatal("Can't find Docker socket!")
return False
# check socat exec
if not shutil.which("socat"):
_LOGGER.fatal("Can't find socat!")
return False
# check socat exec
if not shutil.which("gdbus"):
_LOGGER.fatal("Can't find gdbus!")
return False
return True
def reg_signal(loop):
"""Register SIGTERM and SIGKILL to stop system."""
try:
loop.add_signal_handler(signal.SIGTERM, lambda: loop.call_soon(loop.stop))
except (ValueError, RuntimeError):
_LOGGER.warning("Could not bind to SIGTERM")
try:
loop.add_signal_handler(signal.SIGHUP, lambda: loop.call_soon(loop.stop))
except (ValueError, RuntimeError):
_LOGGER.warning("Could not bind to SIGHUP")
try:
loop.add_signal_handler(signal.SIGINT, lambda: loop.call_soon(loop.stop))
except (ValueError, RuntimeError):
_LOGGER.warning("Could not bind to SIGINT")

Some files were not shown because too many files have changed in this diff Show More