mirror of
https://github.com/home-assistant/developers.home-assistant.git
synced 2025-07-12 20:06:28 +00:00
Small updates to add-on documentation (#517)
This commit is contained in:
parent
08884e2cca
commit
780d7b1363
@ -27,12 +27,12 @@ All our Images have also [bashio][bashio] installed. It contains a set of common
|
|||||||
When developing your script:
|
When developing your script:
|
||||||
|
|
||||||
- `/data` is a volume for persistent storage.
|
- `/data` is a volume for persistent storage.
|
||||||
- `/data/options.json` contains the user configuration. You can use Bashio or `jq` inside your shell script to parse this data.
|
- `/data/options.json` contains the user configuration. You can use Bashio to parse this data.
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
CONFIG_PATH=/data/options.json
|
CONFIG_PATH=/data/options.json
|
||||||
|
|
||||||
TARGET="$(jq --raw-output '.target' $CONFIG_PATH)"
|
TARGET="$(basio::config 'target')"
|
||||||
```
|
```
|
||||||
|
|
||||||
So if your `options` contain
|
So if your `options` contain
|
||||||
@ -56,7 +56,7 @@ FROM $BUILD_FROM
|
|||||||
ENV LANG C.UTF-8
|
ENV LANG C.UTF-8
|
||||||
|
|
||||||
# Install requirements for add-on
|
# Install requirements for add-on
|
||||||
RUN apk add --no-cache jq
|
RUN apk add --no-cache example_alpine_package
|
||||||
|
|
||||||
# Copy data for add-on
|
# Copy data for add-on
|
||||||
COPY run.sh /
|
COPY run.sh /
|
||||||
@ -214,7 +214,7 @@ We support:
|
|||||||
## Add-on extended build
|
## Add-on extended build
|
||||||
|
|
||||||
Additional build options for an add-on is stored in `build.json`. This file will be read from our build systems.
|
Additional build options for an add-on is stored in `build.json`. This file will be read from our build systems.
|
||||||
You need this only, if you not use the default images or need additionals things.
|
You need this only, if you not use the default images or need additional things.
|
||||||
|
|
||||||
```json
|
```json
|
||||||
{
|
{
|
||||||
|
@ -14,7 +14,7 @@ This file containing the intro is usually referred to as the "README", which is
|
|||||||
|
|
||||||
Good documentation helps the consumer of your add-on to understand its usage, explains configuration options, points users in the right direction in the case they have questions or issues, and contains the license under which the add-on was published.
|
Good documentation helps the consumer of your add-on to understand its usage, explains configuration options, points users in the right direction in the case they have questions or issues, and contains the license under which the add-on was published.
|
||||||
|
|
||||||
This file containing the documentation is usually referred to as the "DOC", which is generally published as the `DOC.md` file.
|
This file containing the documentation is usually referred to as the "DOCS", which is generally published as the `DOCS.md` file.
|
||||||
|
|
||||||
## Add-on icon & logo
|
## Add-on icon & logo
|
||||||
|
|
||||||
|
@ -39,7 +39,7 @@ You need a Docker Hub account to make your own add-ons. You can build your Docke
|
|||||||
For a git repository:
|
For a git repository:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
$ docker run --rm --privileged -v \
|
docker run --rm --privileged -v \
|
||||||
~/.docker:/root/.docker homeassistant/amd64-builder \
|
~/.docker:/root/.docker homeassistant/amd64-builder \
|
||||||
--all -t addon-folder -r https://github.com/xy/addons \
|
--all -t addon-folder -r https://github.com/xy/addons \
|
||||||
-b branchname
|
-b branchname
|
||||||
@ -48,7 +48,7 @@ $ docker run --rm --privileged -v \
|
|||||||
For a local repository:
|
For a local repository:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
$ docker run --rm --privileged -v \
|
docker run --rm --privileged -v \
|
||||||
~/.docker:/root/.docker -v /my_addon:/data homeassistant/amd64-builder \
|
~/.docker:/root/.docker -v /my_addon:/data homeassistant/amd64-builder \
|
||||||
--all -t /data
|
--all -t /data
|
||||||
```
|
```
|
||||||
|
@ -146,7 +146,7 @@ python3 -m http.server 8000
|
|||||||
|
|
||||||
Since we updated the version number in our `config.json`, Home Assistant will show an update button when looking at the add-on details. You might have to refresh your browser or click the refresh button in the add-on store for it to show up. If you did not update the version number, you can also uninstall and install the add-on again. After installing the add-on again, make sure you start it.
|
Since we updated the version number in our `config.json`, Home Assistant will show an update button when looking at the add-on details. You might have to refresh your browser or click the refresh button in the add-on store for it to show up. If you did not update the version number, you can also uninstall and install the add-on again. After installing the add-on again, make sure you start it.
|
||||||
|
|
||||||
Now navigate to [http://hassio.local:8000](http://hassio.local:8000) to see our server in action!
|
Now navigate to [http://homeassistant.local:8000](http://homeassistant.local:8000) to see our server in action!
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user