Commit Graph

66 Commits

Author SHA1 Message Date
Raiford
a3adccafa7 Username and password support for git_pull addon (#217)
* Add user/password support to git pull.

This can be used for private repositories that don't support ssh.
Ex: https://cloud.google.com/source-repositories/docs/

* Remove unnecessary err redirection.

* Bump git_pull version to 3.1

* Update config.json

* Update CHANGELOG.md

* Update CHANGELOG.md

* address commands
2018-01-19 11:56:58 +01:00
Maarten Groeneweg
bf67692f9d new implementation for git pull (#218)
* new implementation for git pull

* implemented review comments: use absolute paths

* fixed linting errors and warnings

* fixed spellcheck hints, and ignored one of them

* Update config.json

* Create CHANGELOG.md

* Update Dockerfile

* Create build.json

* add new cli
2018-01-11 15:09:32 +01:00
Alex Barcelo
ebd0f5931b Fix StrictHostKeyChecking-related failure (#211)
* Fix StrictHostKeyChecking-related failure

For ssh-through git connections, the git pull fails because the host key will not be automatically added to known_hosts.

This should fix that by allowing the key to be put into the known_hosts.

Note that if the remote server ssh key changes, the git operation will fail. That seems a reasonably safe security fallback.

* Update config.json
2017-12-09 22:56:38 +01:00
Julian Kaffke
2bc8d29eb4 git_pull: Prevent plugin from always restarting hass.io even if nothing has changed (#205)
* Prevent git module from always restarting hass.io

`git diff-tree -r --name-only --no-commit-id 'HEAD@{1}' HEAD)` always shows a difference. Getting the commit id prior to pulling is easy and comparing it to the one after pulling makes sure, that checking and restart is only done if ids have changed.

* Forgot to get the OLD_COMMIT id

* Better sorting and further comments

* Pleasing the linter

* Update config.json
2017-12-04 12:44:51 +01:00
Delio Castillo
f07db8dc89 Update config.json (#202)
addresses #198 where some repos addresses such as `gitlab@git.domain.com:group/repo.git` were not matched by the validator.
2017-11-21 16:07:51 +01:00
Delio Castillo
c077c9fb8d Use reflog to calculate diff and allow 'git://' repo addresses (#198)
* use reflog instead of ORIG_HEAD to get the changes

* Allow git:// URLS too

Requiring url in repo only allows for https addresses

* trying to fix the tests and regex match

* fix lint
2017-11-14 11:36:13 +01:00
Alex Barcelo
ea5d7b5920 Adding support for deployment_key for git_pull addon (#196)
* adding support for deployment_key for git_pull addon

* safer usage of bash vars

* fixed $HOME vs ~ typo

* more specific schema for deployment_key_protocol

* adding ssh-client to git pull addon image

* only ...-client package needed

* Pump version to 2.0
2017-10-29 10:22:40 +01:00
Pascal Vizeli
d8597e1c45 fix style 2017-10-06 14:33:50 +02:00
Pascal Vizeli
e939d8783c New build system (#179)
* Update Dockerfile

* Update Dockerfile

* Update Dockerfile

* Update Dockerfile

* Update Dockerfile

* Update Dockerfile

* Update Dockerfile

* Update Dockerfile

* Update Dockerfile

* Create build.json

* Update Dockerfile

* Update Dockerfile

* Create build.json

* Update build.json
2017-09-25 00:12:26 +02:00
Pascal Vizeli
04ad144450 Git_pull check config before restart (#174)
* Update run.sh

* Update config.json

* report invalid config
2017-08-25 15:46:51 +02:00
Thibault Maekelbergh
579d2168df Rename all keys & consts from repositorie to repository (#173)
* Change key repositorie to repository

Patch bump version

* Change const REPOSITORIE to REPOSITORY

* Correct the key interpolation from /data/options.json

* Pump version for config changes

* Update config
2017-08-25 15:28:50 +02:00
Pascal Vizeli
d24aa7d3e4 Migrate ssh/git_pull to new hassio_api feature of 0.51 (#167)
* Update config.json

* Use new API link

* Update config.json

* Update run.sh

* Update config.json
2017-08-09 09:32:38 +02:00
Fabian Affolter
15eb72cb60 Update description 2017-08-04 21:11:58 +02:00
Pascal Vizeli
03adf26d93 Bugfix cleanup config folder git (#166)
* Update run.sh

* Update config.json
2017-08-04 16:25:42 +02:00
Pascal Vizeli
6e872c3b91 add git pull logo 2017-08-03 16:52:20 +02:00
Pascal Vizeli
d85d9b4f54 Add first version of simple git sync (#162)
* Add first version of simple git sync

* fix lint
2017-08-01 00:21:46 +02:00