mirror of
https://github.com/home-assistant/developers.home-assistant.git
synced 2025-07-10 02:46:29 +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:
|
||||
|
||||
- `/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
|
||||
CONFIG_PATH=/data/options.json
|
||||
|
||||
TARGET="$(jq --raw-output '.target' $CONFIG_PATH)"
|
||||
TARGET="$(basio::config 'target')"
|
||||
```
|
||||
|
||||
So if your `options` contain
|
||||
@ -56,7 +56,7 @@ FROM $BUILD_FROM
|
||||
ENV LANG C.UTF-8
|
||||
|
||||
# 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 run.sh /
|
||||
@ -214,7 +214,7 @@ We support:
|
||||
## 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.
|
||||
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
|
||||
{
|
||||
|
@ -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.
|
||||
|
||||
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
|
||||
|
||||
|
@ -39,18 +39,18 @@ You need a Docker Hub account to make your own add-ons. You can build your Docke
|
||||
For a git repository:
|
||||
|
||||
```shell
|
||||
$ docker run --rm --privileged -v \
|
||||
~/.docker:/root/.docker homeassistant/amd64-builder \
|
||||
--all -t addon-folder -r https://github.com/xy/addons \
|
||||
-b branchname
|
||||
docker run --rm --privileged -v \
|
||||
~/.docker:/root/.docker homeassistant/amd64-builder \
|
||||
--all -t addon-folder -r https://github.com/xy/addons \
|
||||
-b branchname
|
||||
```
|
||||
|
||||
For a local repository:
|
||||
|
||||
```shell
|
||||
$ docker run --rm --privileged -v \
|
||||
~/.docker:/root/.docker -v /my_addon:/data homeassistant/amd64-builder \
|
||||
--all -t /data
|
||||
docker run --rm --privileged -v \
|
||||
~/.docker:/root/.docker -v /my_addon:/data homeassistant/amd64-builder \
|
||||
--all -t /data
|
||||
```
|
||||
|
||||
:::tip
|
||||
|
@ -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.
|
||||
|
||||
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