/srv/irclogs.ubuntu.com/2016/10/29/#snappy.txt

=== JanC_ is now known as JanC
bzoltanogra_:  silly questions :) 1) is there a way to create users on snapp device? 2) Can I run a single command (or /bin/bash) in classic just as in a chroot? Like ssh root@device_ip '/snap/bin/classic /bin/bash -c "foo"' ?07:07
Son_Gokuzyga: ping10:06
ogra_bzoltan, 1) adduser with the --extrausers option .. 2) indeed, but not as root@$ip .... you need sudo (passwordless by default though)10:25
bzoltanogra_: surprisingly the `ssh root@192.168.1.116 '/snap/bin/classic 'df -h''` works for me11:01
ogra_how could that be11:01
ogra_(on an unmodified image)11:01
qenghoThose ' quotes look funny too.11:02
ogra_bzoltan, by default the root account is locked and you cant set a password (readonly passwd file), so if you didnt hack up the imae to put a root ssh key in place or some such this should definitely not work11:03
ogra_(and would be a totally unsupported path too)11:03
bzoltanogra_: I have set up the ssh auth11:04
qenghoThis works for me: ssh Addr -l Me 'sudo /snap/bin/classic df'11:04
ogra_surely not via the config tools11:04
qenghoWithout 'sudo', complains.11:04
ogra_yep11:04
ogra_bzoltan, either use a system-user assertion, or run through the config UI, or use cloud-init, everything else is completely broken and will cause misbehaviour (all tools set up the user via snapd which does a bunch of more stuff than just adding a user to the passwd file)11:06
bzoltanogra_: I see11:07
ogra_just hacking up the image like that will not behave like any other snappy install11:07
bzoltanogra_:  make sense11:07
bzoltanogra_: I am just hacking around :) and collect thoughts.11:07
ogra_(sadly i dont know much about the system-user assertions, but thats likely your way to go ...)11:07
bzoltanogra_:  what is that config UI?11:07
ogra_well, console-conf ... the cli UI that starts on every tty on first boot of the image11:08
bzoltanogra_:  hmmm... I have no hdmi display, neither usb keyboard11:08
ogra_well, every tty includes serial ;)11:08
bzoltanogra_:  Have you seen the RPi osmc image installation?11:08
ogra_nope11:09
bzoltanogra_:  I love that ... it is a desktop tool. You select the sd card device, define what wlan you want to be default and it flashes the OS on teh sdk card with that... after that you have ssh11:10
ogra_ah, something like that is in the TODO list ... but further out11:10
bzoltanogra_:  with our stuff it is a bit too much hacking for a newcomer11:10
bzoltanogra_:  do you want my team to work on making the RPi/DB installation more convenient?11:11
ogra_well, you dd, boot the board, run through the config ... done11:11
bzoltanogra_:  It is kind of SDK stuff... making developer's life easy11:11
ogra_bzoltan, talk to sabdfl ;)11:11
ogra_there are frameworks (very roughly) defined already that were designed at the snappy sprints11:12
ogra_i.e. you would have a UI that actually creates the model assertion, the system-user assertion and calls ubuntu-image in the end to create a matchin img that you can provision with the created system-user assertion11:13
bzoltanogra_: how 'run thru the config' works without keyboard and and display?11:13
ogra_it doesnt11:13
ogra_you need access to a tty atm11:13
ogra_typically embedded/IoT people use serial consoles for that though11:14
ogra_(thats the current target audience)11:14
ogra_a commercial vendor would ship a USB key with system user assertion i guess ... that you can plug in on first boot to have the setup run automagically11:15
ogra_(or have an online assertion creation tool where you can put in your credentials to have the assertion created for a usb key)11:16
bzoltanogra_:  I assume that for tty I need a GPIO-USB cable ...11:16
ogra_something like https://www.amazon.de/gp/product/B00KVUSI3011:16
bzoltanogra_: yeps, I am familar with that.11:17
ogra_(thats the one i have)11:17
bzoltanogra_: I need to dig up my inventory for that :) or make one...11:19
* bzoltan is not in soldering mood11:19
ogra_heh11:19
ogra_you dont need to solder anything with the one above11:19
ogra_(there are little plugs at the ends of the cables, you just plug them onto the right pins)11:20
bzoltanogra_: not if you have one :)11:20
bzoltanogra_:  I know GPIO, I have all those cables and plugs for the headers. It is fairly easy to solder one...11:21
ogra_well, you need the FTDI electronics that are hidden in the USB plug11:21
ogra_its not a stragit usb cable11:22
ogra_*straight11:22
bzoltanogra_: True, it is easier to buy one11:22
mupBug #1637611 changed: snappy images should not ship /etc/profile.d/Z99-cloud-locale-test.sh <Snappy:Fix Released by ogra> <livecd-rootfs (Ubuntu):Fix Released by ogra> <https://launchpad.net/bugs/1637611>11:29
qenghoAre there any docs on how app authors should be using "snap set"?11:36
foxmasksomeone use snapcraft for a django project ? i'd like to see how snapcraft.yaml looks like12:06
qenghofoxmask: I haven't, but I can imagine it. Have you made anything with snapcraft yet?12:07
foxmaski try but I am not satisfied12:09
ogra_yay, my new kbd just got delivered12:12
* ogra_ dances12:12
qenghoClicky?12:12
ogra_super clicky, super small :)12:12
ogra_vortex pok3r12:12
qenghoogra_: Photo plz.12:12
ogra_https://mechanicalkeyboards.com/shop/images/products/large_1239_IMG_0984.jpg12:13
qenghofoxmask: Let's start with your yaml. Pastebin it?12:13
ogra_full metal body12:13
qenghoogra_: that's hot.12:14
qenghoogra_: I've been meaning to put braille caps on my keys so that I learn to read blind as I type.12:15
ogra_haha12:16
ogra_cool idea12:16
ogra_well, i'm still looking for a good set of SA or DSA caps for it now12:16
ogra_like https://pbs.twimg.com/media/CpyKqqEWYAUpvbY.jpg12:18
ogra_(probably less colorful)12:18
ogra_going back to commodore VIC20 typing ;)12:19
ogra_thats more like it https://imgur.com/S3N6i0L12:22
foxmaskqengho: https://gist.github.com/foxmask/4d6ab10571a4d500778d70b336877ed212:29
qenghofoxmask: Those look great!12:31
qenghofoxmask: For your command, you might find what you're looking for with...12:32
foxmaskqengho: if only :)12:32
foxmaski searched here https://github.com/search?o=desc&p=5&q=filename%3Asnapcraft.yaml+%22plugin%3A+python3%22+&s=indexed&type=Code&utf8=%E2%9C%9312:33
qengho$ find /snap/trigger-happy/current -type f -name python2 -o -name manage.py12:33
ogra_try dropping the python in fromt of the command, let it use the shebang12:33
ogra_*front12:33
qenghofoxmask: If it's python3, use that name to search, of course.12:34
ogra_and perhaps make it ./manage.py if the script isnt in PATH (i.e. $SNAP/bin )12:35
foxmaskqengho: there is no python* on manage.py script in that path12:35
foxmaskogra_: i also tried command: manage.py  but here too, the command is not found12:36
ogra_where in your snap does it end up ?12:36
qenghofoxmask: pastebin  $ find /snap/trigger-happy12:36
foxmaskqengho: return nothing :)12:37
foxmaskogra_: how can I check the content of the snap ?12:37
ogra_if it gets put into $SNAP/bin it will be in your path ... if not, you should add the path to the line relative to $SNAP12:37
qenghofoxmask: it returned something.12:37
ogra_build it, install it and look in /snap/$packagename/current/12:37
foxmaskqengho: ok12:37
foxmaskqengho: log exceeded the max size everywhere I paset :) I come back ; afk do 30m,12:44
foxmaskpaste*12:44
ogra_just use paste.ubuntu.com12:45
qenghoand we don't need everything. ...12:45
qenghofoxmask: pastebin  $ find /snap/trigger-happy -type f -executable12:45
clobranoHi there, I just observed that the ubuntu-core snap in my ubuntu 16.04 is "broken". What does it means specifically, and how can I fix it? Thanks13:27
foxmaskqengho: http://0bin.net/paste/C5xRZcgI3Fm6Otb2#l-0oY43Oxh8pds9dL1lijoTx5ioHwjUUGpl8WGmY/8B13:37
* foxmask bacj13:37
* foxmask back13:37
foxmaskqengho: forget all of that . that will wait :)14:08
foxmaskcu14:08
=== chihchun is now known as chihchun_afk
=== mup_ is now known as mup
linuxhikerIs there a way to pass shell variables in a snapcraft.yml? For example... CC="-static" ./configure21:28
linuxhikercurious why I am getting this: make: *** No rule to make target 'world'.  Stop.21:53
linuxhikerCommand '['/bin/sh', '/tmp/tmp6aq0q9nt', 'make', 'world', '-j1']' returned non-zero exit status 221:53
linuxhikerthis comes when I use snapcraft but the command itself: make world -j1 works from the command line21:53

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!