diff --git a/hassio_api/README.md b/hassio_api/README.md new file mode 100644 index 000000000..def589e75 --- /dev/null +++ b/hassio_api/README.md @@ -0,0 +1,20 @@ +# HassIO Server + +## REST API + +### /supervisor + +- GET: Return running version back +- PUT: Read last avilable version and write it to ResinOS config + +### /homeassistant + +- GET: get avilable version +- PUT: performe homeassistant update + +### /addons + +- GET: get list of avilable addons and installed addons back +- PUT: get or performe a update of a addon +- POST: install a addon +- DEL: remove a addon diff --git a/meta-hassio/recipes-containers/docker-disk/docker-resin-supervisor-disk/start-resin-supervisor b/meta-hassio/recipes-containers/docker-disk/docker-resin-supervisor-disk/start-resin-supervisor index 383737783..5afd548da 100644 --- a/meta-hassio/recipes-containers/docker-disk/docker-resin-supervisor-disk/start-resin-supervisor +++ b/meta-hassio/recipes-containers/docker-disk/docker-resin-supervisor-disk/start-resin-supervisor @@ -8,7 +8,6 @@ SUPERVISOR_CONTAINER_IMAGE_ID=$(docker inspect --format='{{.Image}}' resin_super runSupervisor() { docker rm --force resin_supervisor || true docker run --privileged --name resin_supervisor \ - --net=host \ -v /var/run/docker.sock:/var/run/docker.sock \ -v $CONFIG_PATH:/boot/config.json \ -v /resin-data/resin-supervisor:/data \ diff --git a/meta-hassio/recipes-containers/docker-disk/docker-resin-supervisor-disk/update-resin-supervisor b/meta-hassio/recipes-containers/docker-disk/docker-resin-supervisor-disk/update-resin-supervisor index 6f40e30f1..a9e7782e0 100644 --- a/meta-hassio/recipes-containers/docker-disk/docker-resin-supervisor-disk/update-resin-supervisor +++ b/meta-hassio/recipes-containers/docker-disk/docker-resin-supervisor-disk/update-resin-supervisor @@ -78,7 +78,7 @@ else error_handler $LINENO "no container engine detected" fi -request=$(curl $API_ENDPOINT/update_supervisor | jq -e -r '.message') +request=$(curl -X PUT $API_ENDPOINT/supervisor | jq -e -r '.message') if [ request != "ok" ]; then error_handler $LINENO $request fi