Skip to content

Commit

Permalink
✏️ Update Readme and move documentation in DOCS.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Sebclem committed Jan 11, 2021
1 parent 7a5aa7b commit eaf8123
Show file tree
Hide file tree
Showing 6 changed files with 114 additions and 113 deletions.
81 changes: 16 additions & 65 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

[![GitHub Release][releases-shield]][releases]
![Project Stage][project-stage-shield]
[![License][license-shield]](LICENSE.md)
[![License][license-shield]](LICENSE)

![Supports aarch64 Architecture][aarch64-shield]
![Supports amd64 Architecture][amd64-shield]
Expand All @@ -23,12 +23,16 @@ Easily backup your Home Assistant snapshots to Nextcloud
## About

Easily backup your Home Assistant snapshots to Nextcloud.

Auto backup can be configured via the web interface.
### Features
- Auto Backup : Configure this add-on to automaticly backup your HassIO instance.
- Auto Clean : You can specify the maximum number of local snapshots and (__ONLY__) auto backuped snapshots.
- Upload backed-up snapshot to Home assistant.
> __Info:__<br>

- __Auto Backup__ : Configure this add-on to automatically backup your HassIO instance
- __Selective Backup__ : You can specify witch folder and add-on you want to backup.
- __Password protected Backup__ : this add-on can use the Home Assistant snapshot encryption.
- __Auto Clean__ : You can specify the maximum number of local snapshots and (__ONLY__) auto backed-up snapshots.
- __Restore__ : Upload backed-up snapshot to Home assistant.
- __Web UI__ : All the configuration is based on an easy-to-use web interface, no yaml needed.
> __Info:__
> Auto Clean is executed after every upload and every day at 00h30
## Installation
Expand All @@ -42,65 +46,10 @@ comparison to installing any other Hass.io add-on.
1. Check the logs of the "Nextcloud Backup" add-on to see if everything went well.
1. Open the web UI for the "Nextcloud Backup" to configure the add-on.

> **NOTE**: Do not add this repository to HassOS, please use: `https://github.com/Sebclem/sebclem-hassio-addon-repository`.
**NOTE**: Do not add this repository to HassOS, please use:
`https://github.com/Sebclem/sebclem-hassio-addon-repository`.


## NextCloud config

Firts, you need to configure all your Nextcloud information.

To do this:
1. Open the add-on Web UI
1. Open NextCloud config menu (Top right gear, and Nexcloud)
1. If your NextCloud instance use `HTTPS`, enable the `SSL` lever
1. Enter the `hostname` of the NextCloud instance. You can specify a custom port by adding `:[port]` at the end of the hostname (`exemple.com:8080`)
1. Now enter the Username that you when this add-on use.
1. For password, we highly recommend to use `App Password`.<br>
>To generate a `App Password`, go into your personal setting into Nextcloud, Security page. You can generate one via the `Devices & sessions` section. Simply entre a name and hit `Create new app password`
## HassOs Configuration

**Note**: _Remember to restart the add-on when the configuration is changed._

Example add-on configuration:

```json
{
"log_level": "info",
}
```

**Note**: _This is just an example, don't copy and paste it! Create your own!_

### Option: `log_level`

The `log_level` option controls the level of log output by the addon and can
be changed to be more or less verbose, which might be useful when you are
dealing with an unknown issue. Possible values are:

- `trace`: Show every detail, like all called internal functions.
- `debug`: Shows detailed debug information.
- `info`: Normal (usually) interesting events.
- `warning`: Exceptional occurrences that are not errors.
- `error`: Runtime errors that do not require immediate action.
- `fatal`: Something went terribly wrong. Add-on becomes unusable.

Please note that each level automatically includes log messages from a
more severe level, e.g., `debug` also shows `info` messages. By default,
the `log_level` is set to `info`, which is the recommended setting unless
you are troubleshooting.

### Option: `leave_front_door_open`

Adding this option to the add-on configuration allows you to disable
authentication on the add-on by setting it to `true` and leaving the
username and password empty.

**Note**: _We STRONGLY suggest, not to use this, even if this add-on is
only exposed to your internal network. USE AT YOUR OWN RISK!_

## Configuration
The configuration documention can be found [here][config_doc]

## Support

Expand Down Expand Up @@ -168,7 +117,7 @@ SOFTWARE.
[forum-shield]: https://img.shields.io/badge/community-forum-brightgreen.svg
[forum]: https://community.home-assistant.io/
[i386-shield]: https://img.shields.io/badge/i386-yes-green.svg
[issue]: https://github.com/hassio-addons/addon-log-viewer/issues
[issue]: https://github.com/Sebclem/hassio-nextcloud-backup/issues
[license-shield]: https://img.shields.io/github/license/Sebclem/hassio-nextcloud-backup.svg
[maintenance-shield]: https://img.shields.io/maintenance/yes/2021.svg
[project-stage-shield]: https://img.shields.io/badge/project%20stage-Beta-red.svg
Expand All @@ -178,3 +127,5 @@ SOFTWARE.
[repository]: https://github.com/Sebclem/sebclem-hassio-addon-repository
[contributors]: https://github.com/Sebclem/hassio-nextcloud-backup/graphs/contributors
[semver]: https://semver.org/spec/v2.0.0.htm
[config_doc]: https://github.com/Sebclem/hassio-nextcloud-backup/blob/master/nextcloud_backuo/DOCS.md

32 changes: 9 additions & 23 deletions nextcloud_backup/.README.ejs
Original file line number Diff line number Diff line change
@@ -1,40 +1,26 @@
# Home Assistant Add-ons: Nextcloud Backup
![Nextcloud Backup Logo](logo.png)

[![Release][release-shield]][release] ![Project Stage][project-stage-shield] ![Project Maintenance][maintenance-shield]

[![Community Forum][forum-shield]][forum]

[![Buy me a coffee][buymeacoffee-shield]][buymeacoffee]

## About

Easily backup your Home Assistant snapshots to Nextcloud.
Auto backup can be configure via the Home Assistant web interface.
### Features
- Auto Backup : Configure this add-on to automaticaly backup your HassIO instance.
- Auto Clean : You can specify the maximum number of local snapshots and (__ONLY__) auto backup snapshots.
- Upload backed-up snapshot to Home assistant.
> __Info:__
> Auto Clean is executed after every upload and every day at 00h30


## NextCloud config

First, you need to configure all your Nextcloud information.

To do this:
1. Open the add-on Web UI
1. Open NextCloud config menu (Top right gear, and Nexcloud)
1. If your NextCloud instance use `HTTPS`, enable the `SSL` lever
1. Enter the `hostname` of the NextCloud instance. You can specify a custom port by adding `:[port]` at the end of the hostname (`exemple.com:8080`)
1. Now enter the Nextcloud username that you want this addon to use.
1. For password, we highly recommend using an `App Password`.
### Features
- __Auto Backup__ : Configure this add-on to automatically backup your HassIO instance
- __Selective Backup__ : You can specify witch folder and add-on you want to backup.
- __Password protected Backup__ : this add-on can use the Home Assistant snapshot encryption.
- __Auto Clean__ : You can specify the maximum number of local snapshots and (__ONLY__) auto backed-up snapshots.
- __Restore__ : Upload backed-up snapshot to Home assistant.
- __Web UI__ : All the configuration is based on an easy-to-use web interface, no yaml needed.

>To generate an `App Password`, go into your personal settings in the Nextcloud Security page. You can generate one via the `Devices & sessions` section. Simply enter a name and hit `Create new app password`

[Click here for the full documentation][docs]

![screenshot][image]
![Nextcloud Backup Screenshot][image]

[buymeacoffee-shield]: https://www.buymeacoffee.com/assets/img/guidelines/download-assets-sm-2.svg
[buymeacoffee]: https://www.buymeacoffee.com/seb6596
Expand Down
75 changes: 75 additions & 0 deletions nextcloud_backup/DOCS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
## Installation

The installation of this add-on is pretty straightforward and not different in
comparison to installing any other Hass.io add-on.

1. [Add our Home Assisant add-ons repository][repository] to your HassOS instance.
1. Install the "Nextcloud Backup" add-on.
1. Start the "Nextcloud Backup" add-on
1. Check the logs of the "Nextcloud Backup" add-on to see if everything went well.
1. Open the web UI for the "Nextcloud Backup" to configure the add-on.

> **NOTE**: Do not add this repository to HassOS, please use: `https://github.com/Sebclem/sebclem-hassio-addon-repository`.

## NextCloud config

First, you need to configure all your Nextcloud information.

1. Open the add-on Web UI
1. Open NextCloud config menu (Top right gear, and Nextcloud)
1. If your NextCloud instance uses `HTTPS`, enable the `SSL` lever
1. Enter the `hostname` of the NextCloud instance. You can specify a custom port by adding `:[port]` at the end of the hostname (`exemple.com:8080`)
1. Now enter the Nextcloud username that you would like this add-on to use.
1. For the password, we highly recommend using an `App Password`.

>To generate a `App Password`, go into your personal setting into Nextcloud, Security page. You can generate one via the `Devices & sessions` section. Simply enter a name and hit `Create new app password`.
1. You can change the backup directory in Nextcloud. Default is `/Hassio Backup/`.

## Backup config
You can now configure the automatic backup.

1. Open the add-on Web UI
1. Open Backup config menu (Top right gear, and Backup)
1. Specify the backup naming template, this will define how your backup will be named.
On this field, you can use some variables that are documented [here][variable_doc].
The default value is `{type}-{ha_version}-{date}_{hour}`.
1. If you want to protect your backup with a password, enable `Password Protected` and specify the password.
1. You can now choose witch folder and add-on you want to include in your backup.
1. Now select the backup frequency.
1. You can finally enable Auto clean for Local Snapshot (Snapshot in Home Assistant) and Nextcloud Backups.
If enabled, you can specify how much Local Snapshot and Nextcloud Backup you want to keep before deleting the older one.
> __Info:__
> Auto Clean is executed after every upload and every day at 00h30
## Home Assitant Os Configuration

**Note**: _Remember to restart the add-on when the configuration is changed._

Example add-on configuration:

```json
{
"log_level": "info"
}
```

### Option: `log_level`

The `log_level` option controls the level of log output by the addon and can
be changed to be more or less verbose, which might be useful when you are
dealing with an unknown issue. Possible values are:

- `trace`: Show every detail, like all called internal functions.
- `debug`: Shows detailed debug information.
- `info`: Normal (usually) interesting events.
- `warning`: Exceptional occurrences that are not errors.
- `error`: Runtime errors that do not require immediate action.
- `fatal`: Something went terribly wrong. Add-on becomes unusable.

Please note that each level automatically includes log messages from a
more severe level, e.g., `debug` also shows `info` messages. By default,
the `log_level` is set to `info`, which is the recommended setting unless
you are troubleshooting.

[variable_doc]: https://github.com/Sebclem/hassio-nextcloud-backup/blob/master/nextcloud_backup/namin_template.md
[repository]: https://github.com/Sebclem/sebclem-hassio-addon-repository
33 changes: 11 additions & 22 deletions nextcloud_backup/README.md
Original file line number Diff line number Diff line change
@@ -1,39 +1,28 @@
# Home Assistant Add-ons: Nextcloud Backup
![Nextcloud Backup Logo](logo.png)

[![Release][release-shield]][release] ![Project Stage][project-stage-shield] ![Project Maintenance][maintenance-shield]

[![Community Forum][forum-shield]][forum]

[![Buy me a coffee][buymeacoffee-shield]][buymeacoffee]


## About

Easily backup your Home Assistant snapshots to Nextcloud.
Auto backup can be configured via the web interface.
### Features
- Auto Backup : Configure this add-on to automaticly backup your HassIO instance.
- Auto Clean : You can specify the maximum number of local snapshots and (__ONLY__) auto backed-up snapshots.
- Upload backed-up snapshot to Home assistant.
> __Info:__
> Auto Clean is executed after every upload and every day at 00h30

## NextCloud config
- __Auto Backup__ : Configure this add-on to automatically backup your HassIO instance
- __Selective Backup__ : You can specify witch folder and add-on you want to backup.
- __Password protected Backup__ : this add-on can use the Home Assistant snapshot encryption.
- __Auto Clean__ : You can specify the maximum number of local snapshots and (__ONLY__) auto backed-up snapshots.
- __Restore__ : Upload backed-up snapshot to Home assistant.
- __Web UI__ : All the configuration is based on an easy-to-use web interface, no yaml needed.

First, you need to configure all your Nextcloud information.

To do this:
1. Open the add-on Web UI
1. Open NextCloud config menu (Top right gear, and Nexcloud)
1. If your NextCloud instance uses `HTTPS`, enable the `SSL` lever
1. Enter the `hostname` of the NextCloud instance. You can specify a custom port by adding `:[port]` at the end of the hostname (`exemple.com:8080`)
1. Now enter the Nextcloud username that you would like this add-on to use.
1. For password, we highly recommend using an `App Password`.

>To generate a `App Password`, go into your personal setting into Nextcloud, Security page. You can generate one via the `Devices & sessions` section. Simply enter a name and hit `Create new app password`.
[Click here for the full documentation][docs]

![Nextcloud Backup Screenshot](../images/screenshot.png)

[Click here for the full documentation][docs]


[buymeacoffee-shield]: https://www.buymeacoffee.com/assets/img/guidelines/download-assets-sm-2.svg
Expand All @@ -42,6 +31,6 @@ To do this:
[forum-shield]: https://img.shields.io/badge/community-forum-brightgreen.svg
[forum]: https://community.home-assistant.io/
[maintenance-shield]: https://img.shields.io/maintenance/yes/2021.svg
[project-stage-shield]: https://img.shields.io/badge/project%20stage-developpement-yellow.svg
[project-stage-shield]: https://img.shields.io/badge/project%20stage-Beta-red.svg
[release-shield]: https://img.shields.io/github/release/Sebclem/hassio-nextcloud-backup.svg
[release]: https://github.com/Sebclem/hassio-nextcloud-backup/releases
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
<span id="help-template" class="form-text">
You can find all available variables
<a target="_blank"
href="https://github.com/Sebclem/hassio-nextcloud-backup/blob/master/naming_template.md">
href="https://github.com/Sebclem/hassio-nextcloud-backup/blob/master/nextcloud_backup/naming_template.md">
here
</a>
</span>
Expand Down Expand Up @@ -135,13 +135,13 @@
<div class="form-check form-switch">
<input class="form-check-input" id="auto_clean_backup" type="checkbox">
<label class="form-check-label" for="auto_clean_backup">Auto Clean Nextcloud
Snapshots</label>
Backups</label>
</div>
</div>
</div>
<div class="row mt-2">
<div class="col-12">
<label for="backup-snap-keep" class="form-label">Nextcloud snapshot to keep</label>
<label for="backup-snap-keep" class="form-label">Nextcloud Backup to keep</label>
<input type="number" class="form-control" id="backup-snap-keep" min="0">
</div>
</div>
Expand Down

0 comments on commit eaf8123

Please sign in to comment.