{"action":"created","issue":{"url":"https://api.github.com/repos/qmsk/e2/issues/5","repository_url":"https://api.github.com/repos/qmsk/e2","labels_url":"https://api.github.com/repos/qmsk/e2/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/qmsk/e2/issues/5/comments","events_url":"https://api.github.com/repos/qmsk/e2/issues/5/events","html_url":"https://github.com/qmsk/e2/issues/5","id":176431974,"number":5,"title":"setting up golang, npm and bower","user":{"login":"dougthebug","id":7497785,"avatar_url":"https://avatars.githubusercontent.com/u/7497785?v=3","gravatar_id":"","url":"https://api.github.com/users/dougthebug","html_url":"https://github.com/dougthebug","followers_url":"https://api.github.com/users/dougthebug/followers","following_url":"https://api.github.com/users/dougthebug/following{/other_user}","gists_url":"https://api.github.com/users/dougthebug/gists{/gist_id}","starred_url":"https://api.github.com/users/dougthebug/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dougthebug/subscriptions","organizations_url":"https://api.github.com/users/dougthebug/orgs","repos_url":"https://api.github.com/users/dougthebug/repos","events_url":"https://api.github.com/users/dougthebug/events{/privacy}","received_events_url":"https://api.github.com/users/dougthebug/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/qmsk/e2/labels/question","name":"question","color":"cc317c"}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-09-12T17:16:20Z","updated_at":"2016-09-12T17:56:37Z","closed_at":"2016-09-12T17:42:48Z","body":"I had some issues getting my environment set up.  I'd like to see some form of these instructions included in the readme, as I believe the audience for this project are not typical developers, but video engineers.  My hope is that by making this software more accessible, it will be adopted and extended to a greater degree by the community.\r\n\r\n# Installing golang and qmsk/e2\r\n\r\nThese instructions are assuming you are using a Raspberry Pi.  As far as I know these instructions apply to all hardware revisions.\r\n\r\nThe following software is required to be installed and configured on a Raspberry Pi to use qmsk/e2:\r\n\r\n1. git - the version control software that qmsk/e2 is maintained with\r\n2. go - the go programming language, or golang, is the platform qmsk/e2 is written in\r\n3. bower - does all the web front end stuff\r\n4. npm - node package manager provides bower\r\n5. ssh - the secure shell provides remote access to configure your system from another device without having to attach a keyboard or mouse to your Pi\r\n6. PiBakery - A simple tool for creating customized boot disks for your raspberry pi.  At some point most of these instructions could be included in a 'recipe' for PiBakery\r\n\r\nBegin by downloading and installing PiBakery (or skip this step if you know what you're doing) from http://www.pibakery.org and create a boot image.  You will need about seven gigabytes of disk space.  Use PiBakery to enable ssh on boot, change the password or configure an IP address, although I wont describe that here.\r\n\r\nBoot your Pi and connect to it over the network.  There are a number of tools to discover the IP address of the new device if you did not use PiBakery to assign a static IP address.  I will not describe that here.  From the terminal of your laptop or desktop computer, connect to your Pi using ssh like this:\r\n\r\nssh pi@192.168.1.25\r\n\r\nThe first time you connect to the Pi you will be asked to add the ssh 'fingerprint' to a list kept on your computer.  \r\nType 'yes' and then enter the password you set with PiBakery or the default, which is 'raspberry'\r\n\r\nThe first step, which is not described in the qmsk/e2 readme file is to install go.  You can use any version greater than 1.3, which is unfortunately what is included with the stock Raspberry Pi system.  To install go (or golang, as it's referred to) visit https://golang.org/doc/install and read up.  The short story is to download the precomplied binary for the ARM architecture that the Pi uses and make some directories and save some setting to your .profile file.  This is the hardest part.  Currently, version 1.7 is the latest, so grab the file at https://storage.googleapis.com/golang/go1.7.1.linux-armv6l.tar.gz by typing the following into your command line after logging in to the Pi:\r\n\r\npi@raspberrypi:~ $ wget https://storage.googleapis.com/golang/go1.7.1.linux-armv6l.tar.gz\r\n\r\nwhich looks like this:\r\n\r\npi@raspberrypi:~ $ wget https://storage.googleapis.com/golang/go1.7.1.linux-armv6l.tar.gz\r\n--2016-09-12 15:28:44--  https://storage.googleapis.com/golang/go1.7.1.linux-armv6l.tar.gz\r\nResolving storage.googleapis.com (storage.googleapis.com)... 216.58.192.16, 2607:f8b0:4005:805::2010\r\nConnecting to storage.googleapis.com (storage.googleapis.com)|216.58.192.16|:443... connected.\r\nHTTP request sent, awaiting response... 200 OK\r\nLength: 69522921 (66M) [application/x-gzip]\r\nSaving to: ‘go1.7.1.linux-armv6l.tar.gz’\r\n\r\n.7.1.linux-armv6l.t  19%[===>                  ]  12.92M  2.47MB/s   eta 23s   \r\n\r\nWhen this is done you will have to install this file to a system directory with the following command:\r\n\r\npi@raspberrypi:~ $ sudo tar -C /usr/local -xzf go1.7.1.linux-armv6l.tar.gz\r\n\r\nWhich extracts the files to where they belong.  Now you have to tell the system that this stuff is there by editing some files.  From the golang installation instructions: \r\n\r\n(Typically these commands must be run as root or through sudo.)\r\n\r\nAdd /usr/local/go/bin to the PATH environment variable. You can do this by adding this line to your /etc/profile (for a system-wide installation) or $HOME/.profile:\r\n\r\nexport PATH=$PATH:/usr/local/go/bin\r\n\r\nYou will also need a local workspace to install the source files for qmsk/e2.  Add the line:\r\n\r\nexport GOPATH=$HOME/work\r\n\r\nThen save that file using your favorite text editor.  After you edit and save this file, force the system to read it again by using the source command, i.e.\r\n\r\npi@raspberrypi:~ $ source .profile\r\n\r\nJust type the part after the $ or whatever your shell's prompt is.\r\n\r\nBe sure to actually create this folder:\r\n\r\npi@raspberrypi:~ $ mkdir work\r\n\r\nI highly recommend following the golang tutorial and compiling the hello, world example before continuing.\r\n\r\nNow move into the work directory and create another folder, src, and move into it like this:\r\n\r\npi@raspberrypi:~ $ cd work\r\npi@raspberrypi:~/work $ mkdir src\r\npi@raspberrypi:~/work $ cd src\r\npi@raspberrypi:~/work/src $ \r\n\r\nNow we're back to the original readme file.  Install qmsk/e2 with:\r\n\r\ngit clone https://github.com/qmsk/e2.git\r\n\r\nand then cd into the e2 directory and run the go get command from the readme:\r\n\r\ngo get ./cmd/tally\r\ngo get ./cmd/server\r\n\r\nwhich looks like:\r\n\r\npi@raspberrypi:~/work/src $ git clone https://github.com/qmsk/e2.git\r\nCloning into 'e2'...\r\nremote: Counting objects: 2608, done.\r\nremote: Total 2608 (delta 0), reused 0 (delta 0), pack-reused 2608\r\nReceiving objects: 100% (2608/2608), 2.07 MiB | 657.00 KiB/s, done.\r\nResolving deltas: 100% (1527/1527), done.\r\nChecking connectivity... done.\r\npi@raspberrypi:~/work/src $ cd e2\r\npi@raspberrypi:~/work/src/e2 $ go get ./cmd/tally\r\npi@raspberrypi:~/work/src/e2 $ go get ./cmd/server\r\n\r\nNow lets install npm and then we'll install bower with npm.  This will take a minute.\r\n\r\nsudo apt-get install npm\r\n\r\nWhose output looks like this:\r\n\r\npi@raspberrypi:~/work/src/e2 $ sudo apt-get install npm\r\nReading package lists... Done\r\nBuilding dependency tree       \r\nReading state information... Done\r\nThe following extra packages will be installed:\r\n  gyp libc-ares-dev libjs-node-uuid libjs-underscore libssl-dev libssl-doc\r\n  libv8-3.14-dev node-abbrev node-ansi node-ansi-color-table node-archy\r\n  node-async node-block-stream node-combined-stream node-cookie-jar\r\n  node-delayed-stream node-forever-agent node-form-data node-fstream\r\n  node-fstream-ignore node-github-url-from-git node-glob node-graceful-fs\r\n  node-gyp node-inherits node-ini node-json-stringify-safe node-lockfile\r\n  node-lru-cache node-mime node-minimatch node-mkdirp node-mute-stream\r\n  node-node-uuid node-nopt node-normalize-package-data node-npmlog node-once\r\n  node-osenv node-qs node-read node-read-package-json node-request node-retry\r\n  node-rimraf node-semver node-sha node-sigmund node-slide node-tar\r\n  node-tunnel-agent node-underscore node-which nodejs-dev\r\nSuggested packages:\r\n  node-hawk node-aws-sign node-oauth-sign node-http-signature\r\nThe following NEW packages will be installed:\r\n  gyp libc-ares-dev libjs-node-uuid libjs-underscore libssl-dev libssl-doc\r\n  libv8-3.14-dev node-abbrev node-ansi node-ansi-color-table node-archy\r\n  node-async node-block-stream node-combined-stream node-cookie-jar\r\n  node-delayed-stream node-forever-agent node-form-data node-fstream\r\n  node-fstream-ignore node-github-url-from-git node-glob node-graceful-fs\r\n  node-gyp node-inherits node-ini node-json-stringify-safe node-lockfile\r\n  node-lru-cache node-mime node-minimatch node-mkdirp node-mute-stream\r\n  node-node-uuid node-nopt node-normalize-package-data node-npmlog node-once\r\n  node-osenv node-qs node-read node-read-package-json node-request node-retry\r\n  node-rimraf node-semver node-sha node-sigmund node-slide node-tar\r\n  node-tunnel-agent node-underscore node-which nodejs-dev npm\r\n0 upgraded, 55 newly installed, 0 to remove and 0 not upgraded.\r\nNeed to get 3,709 kB of archives.\r\nAfter this operation, 13.3 MB of additional disk space will be used.\r\nDo you want to continue? [Y/n] \r\n\r\n\r\nYou should probably update your available packages with\r\n\r\nsudo apt-get update\r\n\r\nbefore running the above command.\r\n\r\nAfter your coffee has cooled, install bower by typing\r\n\r\nsudo npm install -g bower\r\n\r\nwhich will look like:\r\n\r\npi@raspberrypi:~/work/src/e2 $ sudo npm install -g bower\r\n/usr/local/bin/bower -> /usr/local/lib/node_modules/bower/bin/bower\r\nbower@1.7.9 /usr/local/lib/node_modules/bower\r\npi@raspberrypi:~/work/src/e2 $ \r\n\r\nNow change directory into static and install bower there like this:\r\n\r\ncd static && bower install\r\n\r\nNow go back to the original readme and continue from there, knowing you have everything installed!"},"comment":{"url":"https://api.github.com/repos/qmsk/e2/issues/comments/246434080","html_url":"https://github.com/qmsk/e2/issues/5#issuecomment-246434080","issue_url":"https://api.github.com/repos/qmsk/e2/issues/5","id":246434080,"user":{"login":"dougthebug","id":7497785,"avatar_url":"https://avatars.githubusercontent.com/u/7497785?v=3","gravatar_id":"","url":"https://api.github.com/users/dougthebug","html_url":"https://github.com/dougthebug","followers_url":"https://api.github.com/users/dougthebug/followers","following_url":"https://api.github.com/users/dougthebug/following{/other_user}","gists_url":"https://api.github.com/users/dougthebug/gists{/gist_id}","starred_url":"https://api.github.com/users/dougthebug/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dougthebug/subscriptions","organizations_url":"https://api.github.com/users/dougthebug/orgs","repos_url":"https://api.github.com/users/dougthebug/repos","events_url":"https://api.github.com/users/dougthebug/events{/privacy}","received_events_url":"https://api.github.com/users/dougthebug/received_events","type":"User","site_admin":false},"created_at":"2016-09-12T17:56:36Z","updated_at":"2016-09-12T17:56:36Z","body":"Thank you!\n\nI wasn’t sure how exactly to do this.  At first I forked the project and made these notes in my own fork, but then realized that no one else would see them (i think).  Then I created this as an issue in the master, which looked to be the best choice.\n\nI’m still wrapping my head around github, and I’ll take a look at drone.\n\nI’m really excited to get this up and running.  The functionality you’ve implemented here is huge!\n\nAfter I posted this I realized I missed a step, and when I tried to run the command to install client I got:\n\npi@raspberrypi:~/work/src/e2 $ go get ./cmd/client\n# e2/cmd/client\ncmd/client/aux_list.go:15: options.ClientOptions.Client undefined (type client.Options has no field or method Client)\ncmd/client/list_destinations.go:15: options.ClientOptions.Client undefined (type client.Options has no field or method Client)\ncmd/client/preset_list.go:15: options.ClientOptions.Client undefined (type client.Options has no field or method Client)\ncmd/client/preset_show.go:17: options.ClientOptions.Client undefined (type client.Options has no field or method Client)\ncmd/client/screen_list.go:15: options.ClientOptions.Client undefined (type client.Options has no field or method Client)\ncmd/client/screen_show.go:17: options.ClientOptions.Client undefined (type client.Options has no field or method Client)\ncmd/client/source_list.go:15: options.ClientOptions.Client undefined (type client.Options has no field or method Client)\n\nI can post this as an issue if the answer isn’t totally obvious to you right away.\n\nThanks again, I look forward to contributing to this project and to getting back into programming.\n\n> On Sep 12, 2016, at 10:42 AM, Tero Marttila <notifications@github.com> wrote:\n> \n> Thank you for writing up these installation steps! I took the liberty to transcribe them into the wiki, with some additional formatting: https://github.com/qmsk/e2/wiki <https://github.com/qmsk/e2/wiki>\n> Feel free to further edit them there.\n> \n> And as per installation instructions in general, here's my thoughts:\n> \n> The README should cover any E2 specifics related to development and some basic usage. General bits like \"how to SSH to your PI\", \"how to build Go binaries\", \"how to install bower\" etc. are best covered elsewhere, and I suppose the github Wiki is as good a place as any for that.\n> \n> I updated the README with the Go 1.4 requirement.\n> \n> There should be versioned releases with automated builds of release binaries. Users shouldn't need to install development tools like Go or NPM/Bower.\n> \n> I have some manually built binaries at http://users.qmsk.net/~terom/qmsk-e2/dist/ <http://users.qmsk.net/%7Eterom/qmsk-e2/dist/> , but this is something that should be automated via some CI system like https://github.com/drone/drone <x-msg://12/drone>.\n> \n> —\n> You are receiving this because you authored the thread.\n> Reply to this email directly, view it on GitHub <https://github.com/qmsk/e2/issues/5#issuecomment-246429756>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AHJoOYoOqJULjazQg2S5ZIYu2w0ZIvmkks5qpY8ZgaJpZM4J60Su>.\n> \n\n"}}
{"actor":{"display_login":"dougthebug"}}