mirror of
https://github.com/balena-os/balena-supervisor.git
synced 2024-12-19 21:57:54 +00:00
Auto-merge for PR #588 via VersionBot
Fix the check for whether the device is provisioned by correctly get…
This commit is contained in:
commit
a2287dd8b5
@ -4,6 +4,11 @@ All notable changes to this project will be documented in this file
|
||||
automatically by Versionist. DO NOT EDIT THIS FILE MANUALLY!
|
||||
This project adheres to [Semantic Versioning](http://semver.org/).
|
||||
|
||||
## v7.1.13 - 2018-03-15
|
||||
|
||||
* Fix typo passing apiKey to the resin API client when exchanging apikeys #588 [Pablo Carranza Velez]
|
||||
* Fix the check for whether the device is provisioned by correctly getting registered_at and deviceId from config.json into the ApiBinder #588 [Pablo Carranza Velez]
|
||||
|
||||
## v7.1.12 - 2018-03-15
|
||||
|
||||
* Compose: Use the hostname on the host as default hostname for services with host network mode #586 [Pablo Carranza Velez]
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "resin-supervisor",
|
||||
"description": "This is resin.io's Supervisor, a program that runs on IoT devices and has the task of running user Apps (which are Docker containers), and updating them as Resin's API informs it to.",
|
||||
"version": "7.1.12",
|
||||
"version": "7.1.13",
|
||||
"license": "Apache-2.0",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
|
@ -103,13 +103,15 @@ module.exports = class APIBinder
|
||||
return null
|
||||
|
||||
fetchDevice: (uuid, apiKey, timeout) =>
|
||||
@resinApi.get
|
||||
reqOpts = {
|
||||
resource: 'device'
|
||||
options:
|
||||
filter:
|
||||
uuid: uuid
|
||||
passthrough:
|
||||
headers: Authorization: "Bearer: #{apiKey}"
|
||||
headers: Authorization: "Bearer #{apiKey}"
|
||||
}
|
||||
@resinApi.get(reqOpts)
|
||||
.get(0)
|
||||
.catchReturn(null)
|
||||
.timeout(timeout)
|
||||
|
@ -59,6 +59,8 @@ module.exports = class Config extends EventEmitter
|
||||
'deviceType'
|
||||
'resinApiEndpoint'
|
||||
'apiTimeout'
|
||||
'registered_at'
|
||||
'deviceId'
|
||||
]).then (conf) ->
|
||||
return {
|
||||
uuid: conf.uuid
|
||||
@ -69,6 +71,8 @@ module.exports = class Config extends EventEmitter
|
||||
deviceApiKey: conf.deviceApiKey
|
||||
apiEndpoint: conf.resinApiEndpoint
|
||||
apiTimeout: conf.apiTimeout
|
||||
registered_at: conf.registered_at
|
||||
deviceId: conf.deviceId
|
||||
}
|
||||
|
||||
mixpanelHost: =>
|
||||
|
Loading…
Reference in New Issue
Block a user