Giter Club home page Giter Club logo

iotz's People

Contributors

jbobotek avatar microsoftopensource avatar msftgits avatar obastemur avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

iotz's Issues

install fails on Ubuntu 18.04

Hi,

Both myself and my customer have tried to install iotz on Ubuntu 18.04 "fresh" VMs (him locally, and me with a default Canonical Ubuntu 18.04 VM in Azure.)

  • installed docker (18.06.1-ce)
  • added myself to the 'docker' group (so I didn't have to do 'sudo' in front of docker commands).
  • ran 'sudo npm I iotz -g'

Got the error below... Both myself and my customer have the same experience...

should this work?

stevebus@iotzUbuntu:~$ sudo npm i iotz -g
/usr/local/bin/iotz -> /usr/local/lib/node_modules/iotz/index.js

[email protected] postinstall /usr/local/lib/node_modules/iotz
iotz update

  • updating.. (this may take some time)
    Warning: failed to get default registry endpoint from daemon (Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.38/info: dial unix /var/run/docker.sock: connect: permission denied). Using system default: https://index.docker.io/v1/
    Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Post http://%2Fvar%2Frun%2Fdocker.sock/v1.38/images/create?fromImage=azureiot%2Fiotz&tag=latest: dial unix /var/run/docker.sock: connect: permission denied

  • error: update has failed. See the output above.
    npm ERR! Linux 4.15.0-1025-azure
    npm ERR! argv "/usr/bin/node" "/usr/bin/npm" "i" "iotz" "-g"
    npm ERR! node v8.10.0
    npm ERR! npm v3.5.2
    npm ERR! code ELIFECYCLE

npm ERR! [email protected] postinstall: iotz update
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall script 'iotz update'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the iotz package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! iotz update
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs iotz
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls iotz
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR! /home/stevebus/npm-debug.log

iotz init fail saying "Please ensure you have shared the current drive on Docker for Windowsβ€œ

Hi, I was following the README.md tutorial to try out iotz. I ran the following command:

npm i iotz -g
iotz update
iotz create raspberry hello
cd hello
iotz init

And the iotz init fail

$ iotz init
Please ensure you have shared the current drive on Docker for Windows

I was running the command on my C drives, and the C drives has been successfully shared from docker setting UI. I can mount local drive in other docker usage senario.
Now iotz tells me I do not share my local drive which really confuses me. I searched for solution and didn't find some good explaination or solution. Why is this happen and how to resolve it? Thanks!

Platform

Windows 10, 64-bits
Docker version 18.09.0, build 4d60db4

iotz init failing on macOS

Have a problem on my MAC with iotz init - some sort of docker issue with being unable to find a Dockerfile (where is this supposed to come from ?)

az2tf:mxchip_advanced AndyT$ docker version
Client: Docker Engine - Community
Version: 18.09.0
API version: 1.39
Go version: go1.10.4
Git commit: 4d60db4
Built: Wed Nov 7 00:47:43 2018
OS/Arch: darwin/amd64
Experimental: false

Server: Docker Engine - Community
Engine:
Version: 18.09.0
API version: 1.39 (minimum version 1.12)
Go version: go1.10.4
Git commit: 4d60db4
Built: Wed Nov 7 00:55:00 2018
OS/Arch: linux/amd64
Experimental: true
az2tf:mxchip_advanced AndyT$

az2tf:mxchip_advanced AndyT$ npm version
{ npm: '6.4.1',
ares: '1.10.1-DEV',
cldr: '32.0',
http_parser: '2.8.0',
icu: '60.1',
modules: '57',
napi: '3',
nghttp2: '1.32.0',
node: '8.12.0',
openssl: '1.0.2p',
tz: '2017c',
unicode: '10.0',
uv: '1.19.2',
v8: '6.2.414.66',
zlib: '1.2.11' }
az2tf:mxchip_advanced AndyT$

az2tf:mxchip_advanced AndyT$ npm i iotz -g
/usr/local/bin/iotz -> /usr/local/lib/node_modules/iotz/index.js
[email protected]
updated 1 package in 1.087s

az2tf:mxchip_advanced AndyT$ iotz update
updating.. (this may take some time)
latest: Pulling from azureiot/iotz
Digest: sha256:3d46ff59cc96e9915def462e4ce183f1e15cfcd0ebeeedc8a3f7f389541e31f1
Status: Image is up to date for azureiot/iotz:latest
base container update was succesfull
updating extensions
building arduino extension container (it may take some time)

az2tf:mxchip_advanced AndyT$ iotz init
AZ3166:stm32f4:MXCHIP_AZ3166 is selected
unable to prepare context: unable to evaluate symlinks in Dockerfile path: lstat /Users/AndyT/Library/Mobile/Dockerfile: no such file or directory
error: docker couldn't create an image for this path

esp8266 extension

implement esp8266 toolchain extension similar to arduino, mbed etc.

Arduino force -Os

I was experimenting with compiler switches and forcing -Os for IOT central sample saved 4K. Opening this issue in order to track it.

Banana Pi extension

Shall we implement Banana Pi toolchain extension similar to arduino, mbed etc.?

iotc config file is needed

User may want to set && keep;

  • output folder. currently it is hard-coded to BUILD/
  • provide an option to exclude libs and source files etc.
  • set target platform details under config file to keep command line less complicated (optional)
  • more ...

`-a` argument for clean command

clean command naturally doesn't touch to global level containers. Dev doesn't have much option but cleaning the other containers manually.

-a (all) argument might delete each and every iotz container and clean up the extension cache from global config file.

config: additional properties

  • outputPath -> to replace BUILD
  • investiage iotz.json for library type of projects
  • wildcard or array kind toolchain definition support for library projects
  • additional compile / link time definitions?
  • post/pre build etc. commands?
    - how a relative mount path should be? i.e. currently ../<current path> DONE

self bring the deps

Currently, iotz uses mbed-cli to bring the deps. We should implement this to iotz to speed up tests and use it for other extensions.

separate extension containers

ATM, extensions recreate the same local container and add their stuff on it.

Q1: Is there a possibility that ext1 depends on ext2 and has to be under the same container?
Q2: Another reason to keep them together?

This should be taken care of pre making this public

automated base update on each install

When user updates the library using npm, we should update the base container on the first run.

Preferably we should save a state file on $HOME or ~ under .iotc and sync with that.

Can not install iotz properly

$ sudo npm i iotz -g
/usr/local/bin/iotz -> /usr/local/lib/node_modules/iotz/index.js

[email protected] postinstall /usr/local/lib/node_modules/iotz
iotz update

/usr/local/lib/node_modules/iotz/extensions/index.js:174
for (let file of files) {
^^^

SyntaxError: Block-scoped declarations (let, const, function, class) not yet supported outside strict mode
at exports.runInThisContext (vm.js:53:16)
at Module._compile (module.js:404:25)
at Object.Module._extensions..js (module.js:432:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:311:12)
at Module.require (module.js:366:17)
at require (module.js:385:17)
at Object. (/usr/local/lib/node_modules/iotz/src/common.js:12:20)
at Module._compile (module.js:425:26)
at Object.Module._extensions..js (module.js:432:10)
npm ERR! Linux 4.15.0-34-generic
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "i" "iotz" "-g"
npm ERR! node v5.0.0
npm ERR! npm v3.3.6
npm ERR! code ELIFECYCLE

npm ERR! [email protected] postinstall: iotz update
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall script 'iotz update'.
npm ERR! This is most likely a problem with the iotz package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! iotz update
npm ERR! You can get their info via:
npm ERR! npm owner ls iotz
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR! /home/michael/node-v5.0.0/npm-debug.log
michael@michael-linux-work:~/node-v5.0.0$

Any idea?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.