Important
This is for the maint-v1.0 version of NervesHub. It has been merged into NervesHubCLI going forward.
This is a library for interacting with a NervesHub website programmatically.
See NervesHubCLI for using it
with mix.
Devices do not use this library to connect to a NervesHub server. See NervesHubLink for the reference client.
The package can be installed
by adding nerves_hub_user_api to your list of dependencies in mix.exs:
def deps do
[
{:nerves_hub_user_api, "~> 0.8.0"}
]
endThe docs can be found at HexDocs.
NervesHubUserAPI may be configured using environment variables to simplify
automation. Environment variables take precedence over configuration. The
following variables are available:
NERVES_HUB_SCHEME- NervesHub API endpoint scheme (defaults to https)NERVES_HUB_HOST- NervesHub API endpoint IP address or hostnameNERVES_HUB_PORT- NervesHub API endpoint port (defaults to 443)NERVES_LOG_DISABLE_PROGRESS_BAR- Set to disable the progress bar on file transfers
NervesHubUserAPI may also be configured in the config.exs. It supports the
following keys:
schemeNervesHub API endpoint scheme (defaults tohttps)host- NervesHub API endpoint addressport- NervesHub API endpoint port (defaults to 443)ca_store- A module that exposes a single functionca_certsthat returns certs as a list of DER encoded binaries.