Skip to content

Commit

Permalink
Fix password, improve readme, build2 (#14)
Browse files Browse the repository at this point in the history
* Fix password, improve readme, build2

* Changelog
  • Loading branch information
David Zwart authored Jun 21, 2021
1 parent e0430f3 commit 80e024a
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 13 deletions.
17 changes: 13 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,25 @@

All notable changes to this project will be documented in this file.


## [0.1.0-rc1]

### Added
- Feature: add unique key `device_uuid` to `config.yaml` to recognize the device
- Feature: store backup-excluded unique key `perrsistence_uuid` to data folder to see when backups are restored
- Feature: announce the OctoPrint device to OctoFarm automatically using OpenID Connect with `client_credentials` as auth flow.
- Feature: add settings and navbar templates to OctoPrint under `OctoFarm Companion`

### Changed

### Removed

### Fixed
- #10 README fixed about settings saved to `config.yaml`
- #11 Plugin URL was incorrect
- #12 Password field wasnt hidden


## [0.1.0-rc1]

### Added
- Feature: add unique key `device_uuid` to `config.yaml` to recognize the device
- Feature: store backup-excluded unique key `perrsistence_uuid` to data folder to see when backups are restored
- Feature: announce the OctoPrint device to OctoFarm automatically using OpenID Connect with `client_credentials` as auth flow.
- Feature: add settings and navbar templates to OctoPrint under `OctoFarm Companion`
16 changes: 10 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,12 @@ For more feature requests, bugs, or ideas please head over to https://github.com

## Setup
**!! Work in progress !!**
This plugin is in alpha stage. It requires the plugin system on OctoFarm, which is not released yet.

Install via the bundled [Plugin Manager](https://docs.octoprint.org/en/master/bundledplugins/pluginmanager.html)
or manually using this URL:

https://github.com/OctoFarm/OctoFarm-Companion/archive/master.zip
https://github.com/OctoFarm/OctoFarm-Companion/archive/main.zip

Please configure the plugin completely for one or more printers before checking OctoFarm.

Expand All @@ -28,15 +29,18 @@ Please configure the plugin completely for one or more printers before checking

### Configuration - auto-registration
Configuring the auto-registration properly can massively improve the steps you need to undertake to setup your farm.
- `octofarmHost` the host to reach OctoFarm with (IP, localhost, domain name, etc)
- `octofarmPort` the port to approach the OctoFarm server (number)
- REQUIRED `octofarm_host` the host to reach OctoFarm with (IP, localhost, domain name, etc)
- REQUIRED `octofarm_port` the port to approach the OctoFarm server (number)
- REQUIRED `oidc_client_id` the client id to authenticate with the OctoFarm server using OpenID Connect (string)
- REQUIRED `oidc_client_secret` the client secret key to authenticate with the OctoFarm server using OpenID Connect (string)
- OPTIONAL `port_override` the announced port for how OctoFarm can reach OctoPrint later (default is taken from `server:port`, but this is not always correct in case of Docker or a proxy.)

We understand if you restore OctoPrint backups to install new OctoPrints. For that reason we've introduced two unique ID's (UUID).
- `persistenceUuid` a unique identifier stored in the plugin folder in `device.json`, which is excluded from backups to prevent duplicate printers.
- `deviceUuid` a unique identifier stored in the `config.yaml` at startup.
- AUTOGENERATED `persistence_uuid` a unique identifier stored in the plugin folder in `device.json`, which is excluded from backups to prevent duplicate printers. Dont adjust this, if you dont understand it.
- AUTOGENERATED `device_uuid` a unique identifier stored in the `config.yaml` at startup. Dont adjust this, if you dont understand it.

Periodic updates
- `ping` the time in seconds between each call to OctoFarm (default is 15 * 60, or 15 minutes)
- OPTIONAL `ping` the time in seconds between each call to OctoFarm (default is 15 * 60, or 15 minutes)

The plugin will use `server:host` and `server:port` to give OctoFarm a handle to connect back to this OctoPrint. This is often incorrect, if your OctoPrint is behind a proxy, in a VM, UnRaid, a different device, DMZ, in a docker container or in a VPN.
At this moment this needs to be rectified in OctoFarm. Later we will allow more advanced ways to fix this, but for now we believe this plugin is going to make it much easier already.
2 changes: 1 addition & 1 deletion octofarm_companion/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ def test_octofarm_openid(self):


__plugin_name__ = "OctoFarm Companion"
__plugin_version__ = "0.1.0-rc1"
__plugin_version__ = "0.1.0-rc1-build2"
__plugin_description__ = "The OctoFarm companion plugin for OctoPrint"
__plugin_pythoncompat__ = ">=3,<4"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
</div>
<label class="control-label" for="settings-oidc-client-secret">{{ _('OpenID client secret') }}</label>
<div class="controls">
<input type="text" class="input-block-level"
<input type="password" class="input-block-level"
data-bind="value: settings.plugins.octofarm_companion.oidc_client_secret"
id="settings-oidc-client-secret" placeholder="My OpenID client secret from OctoFarm">
<span class="help-inline">
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
plugin_name = "OctoFarm-Companion"

# The plugin's version. Can be overwritten within OctoPrint's internal data via __plugin_version__ in the plugin module
plugin_version = "0.1.0-rc1"
plugin_version = "0.1.0-rc1-build2"

# The plugin's description. Can be overwritten within OctoPrint's internal data via __plugin_description__ in the plugin
# module
Expand Down

0 comments on commit 80e024a

Please sign in to comment.