/srv/irclogs.ubuntu.com/2016/07/20/#snappy.txt

=== chihchun_afk is now known as chihchun
qenghoHow does my Qt snapped app know what theme it should use? Qt is Martian technology and I don't understand it.02:47
Croephaqengho: you can use env variables03:14
qenghoCroepha: that makes sense. I must not know what to use, because none I try changes it. I wish to use Humanity theme. What var and value?03:15
CroephaI dont have experience with QT styles, but for QT to work right, you need QT_PLUGIN_PATH to get to the platfrom plugins03:17
Croephahttps://wiki.archlinux.org/index.php/Uniform_look_for_Qt_and_GTK_applications says to use QT_STYLE_OVERRIDE03:17
Croephathere might also be a programatic way to do it03:18
Croephanot sure03:18
Croephayou might want to use strace to see if the app is actually trying to load anything03:18
qenghoI used strace. It's looking for hicolor only.03:19
Croephahave you tried QT_STYLE_OVERRIDE='gtk2'03:19
qenghoI thought so. I'm trying again.03:20
Croephayou might also want to try printing out the env from the app, to make sure that your env isn't getting dropped03:20
CroephaI have a bash script inside of my snap that sets the required vars03:21
Croephaprobably a better way would be to set the vars from inside the app03:21
qenghoI have a wrapper too.03:21
Croephaanyway, im not sure I can help, because I haven't messed with styles03:21
qenghoOkay then.03:22
RyanTGHow do I give the VLC snap package access to my DVD drive?04:31
RyanTGI already have snapd-2.0.10 which is supposed to make DVDs usable with VLC, so what am I missing?04:37
RyanTGfound it: snap remove vlc && apt-get install vlc04:38
liuxgif a snap needs a debian package, but it does not exist in the ubuntu archive, I can get the .deb file locally, how can I make use of the .deb file? thank04:39
=== chihchun is now known as chihchun_afk
qengholiuxg: There's no way to import a deb file, only a named APT package. You could make a plugin to unpack it and install it.05:13
liuxgqengho, I do not know how. This is a valid use case. For example, in China, there are some debian files which are not in the ubuntu archive (input method), there is no way to use stage-packages to do that. I think it would be good to support it in the snapcraft.05:16
qengholiuxg: I agree it would. Please file a bug report to explain what you want.  $ ubuntu-bug snapcraft   # maybe?05:17
liuxgqengho, sometimes, we need to add a specific ppa to get a software installed.05:17
liuxgqengho, sure, I will do that. thanks05:17
qengholiuxg: In the mean time, you can put a file at parts/plugins/x-deb-file.py , and extend  snapcraft.BasePlugin .  In your snapcraft, "plugin: deb-file" .05:19
liuxgqengho, is there any document for this? I want to have a better picture of this about how to do it. thanks.05:20
qengholiuxg: Yes. Google "write snapcraft plugins"05:21
liuxgqengho, OK. many thanks!05:23
qengho:)05:23
liuxgqengho, by the way, i have created a bug report at https://bugs.launchpad.net/snapcraft/+bug/160466905:24
mupBug #1604669: Support Installing a local deb package in the snapcraft <Snapcraft:New> <https://launchpad.net/bugs/1604669>05:24
qengholiuxg: defining an APT source is useful too05:26
liuxgqengho, how can I define an APT source for it? https://github.com/snapcore/snapcraft/blob/master/docs/snapcraft-syntax.md, at the link, I did not find anything about it.05:28
qengholiuxg: I'm suggeting anther bug report.05:28
qenghoanother05:28
liuxgqengho, yes, I think it is a good idea :)05:29
liuxgqengho, let me create one for it. thanks05:29
liuxgqengho, there is a bug https://bugs.launchpad.net/snapcraft/+bug/1583236, it seems that APT is already supported?05:31
mupBug #1583236: snapcraft APT sources checking too strict <Snapcraft:New> <https://launchpad.net/bugs/1583236>05:31
liuxgqengho, but I do not find it in any of the documents. it is weired.05:31
qenghoHah, I filed that one. it refers to the system sources.list05:32
liuxgqengho, so, it is not for the snapcraft?05:33
qengholiuxg: That means that when installing stage-packages: or build-packages:, warnings cause failure.05:33
qenghoIt has nothing to do with other sources from snapcraft configuratio.05:34
liuxgqengho, so the API support for the snapcraft  is that it can install debian pacakges from other sources, right? Is this not supported? I just want to clarify this.05:35
qengholiuxg: it is not supported to have your snapcraft refer to a package that is not in the distro or the local system's global source list.05:36
liuxgqengho, OK. thanks..05:36
liuxgqengho, I have filed a bug at  https://bugs.launchpad.net/snapcraft/+bug/1604671. would you please take a look at it? thanks05:40
mupBug #1604671: Adding APT source support in the snapcraft <Snapcraft:New> <https://launchpad.net/bugs/1604671>05:40
qenghoCool.05:40
qengholiuxg: Looks good to me.05:41
liuxgqengho, nice. thanks!05:41
qengholiuxg: Where are you physically?05:41
liuxgqengho, I am physically in Beijing, China. How about you?05:41
qenghoTaipei. Just noticing your name and wondering if you were near.05:42
liuxgqengho, good to know you. Are you from canonical?05:43
qenghoYes.05:44
qenghoThough snappy is not what I work on usually.05:44
liuxgqengho, oh, really? I am actually from phone team too :). by the way, I cannot find your irc nick name in our directory.05:45
qengholp:~cmiller05:46
liuxgqengho, oh, you are from US. nice to meet you :)05:47
qenghoLikewise.05:47
liuxgqengho, today, I tried to install the telegram app onto my desktop. I got the Chinese fonts in the snap. However, the input method does not work for me. I am wondering whether I need to install the input method into the snap.05:50
liuxgqengho, the problem is that I can only get the deb package for the input method.05:50
qenghoI see. Hmm. I would think you don't need the input method in the snap.05:51
liuxgqengho, I used to develop a Qt-based phone app and convert it to a snap. the characters are shown correctly unlike the telegram one.05:51
liuxgqengho, then,  the Chinese characters are all shown as rectangle blocks :(05:53
qengholiuxg: You *do* need fonts in the snap.05:53
liuxgqengho, yes, I have installed the fonts already.05:53
liuxgqengho, strange, right? http://paste.ubuntu.com/20145372/, this is the modified snapcraft.yaml05:54
liuxgqengho, the Chinese input method does not work at all. I cannot input Chinese characters.05:55
liuxgqengho, the original source code is at https://github.com/sergiusens/telegram-snap05:55
* qengho casts spell Summon Sergi.05:57
qengholiuxg: sorryy, I do'nt know.06:00
liuxgqengho, anyway, it is fine. it is just sth I experienced. internationalization is definitely one of the concerns. I think it would be easier to have the language support in the snapcraft as well.06:01
=== chihchun_afk is now known as chihchun
mupPR snapd#1573 opened: asserts/tool,cmd/snap: introduce hidden "snap sign" <Created by pedronis> <https://github.com/snapcore/snapd/pull/1573>06:41
mupPR snapcraft#672 closed: Capture the correct exception when not being able to decode json <Created by sergiusens> <Merged by sergiusens> <https://github.com/snapcore/snapcraft/pull/672>06:42
mupPR snapd#1568 closed: Enable SNAPPY_STORE_AUTH_DATA_FILENAME override for client auth data <Created by absoludity> <Merged by mvo5> <https://github.com/snapcore/snapd/pull/1568>06:45
=== chihchun is now known as chihchun_afk
mupPR snapd#1574 opened: tests: add network-control interface spread test <Created by fgimenez> <https://github.com/snapcore/snapd/pull/1574>06:57
=== chihchun_afk is now known as chihchun
dholbachhey hey07:00
mupPR snapcraft#674 opened: Add reference.md <Created by elopio> <https://github.com/snapcore/snapcraft/pull/674>07:33
liuxgdholbach, ping07:40
dholbachliuxg, pong07:41
liuxgdholbach, I just found that "snap run". but I do not how to use it. I tried it for the "hello-world" exmaple, it does not work. what should be the correct way to run it?07:41
liuxgdholbach, I have tried it like "snap run hello-world" or "snap run hello-world.env", both did not work.07:42
dholbachliuxg, you could ask all the others in the channel too - I'm not a snapd developer :-)07:46
dholbachI have never used "snap run" yet07:47
pmpliuxg: to run the hello-world-snap simply run hello-world07:47
pmpsnap is mainly for installing and managing snaps07:48
liuxgdholbach, yes, it is a little strange. I have seen its help by running "snap run -h", and it shows something like http://paste.ubuntu.com/20152247/07:48
pmpliuxg: hello-world.echo for example07:48
liuxgpmp,  yes, that is what I normally use. However, what is the "run" command for there?07:49
pmpliuxg: sorry, have never seen or used it myself07:49
liuxgpmp, yes, I understood that. But why there is a "run" command when I run "snap --help"07:49
liuxgpmp, it is a little confusing in that sense. if there is a command like "run", we can do sth like "snap run xxx".07:50
liuxgpmp, maybe it simply means that way you talked about. Then the help is a little bit confusing there.07:50
liuxgfrom the syntax there in the help, it is sth like "snap [OPTIONS] run [run-OPTIONS] <app name>". it is supposed to run a snap app.07:52
qenghoHow does my Qt snapped app know what theme it should use? Qt is Martian technology and I don't understand it.07:52
qenghoI have heard that one can set an environment variable of some kind, to affect it, but that seems to be lies lies lies.07:53
liuxgqengho, I think insider your Qt app, you can point what theme it should use.07:53
qengholiuxg: Inside how? I run a snapped app. I get broken thee.07:53
qenghotheme07:54
liuxgqengho, inside your MainView, there is a "theme" property.07:54
qenghoI am not going to edit the source.07:54
liuxgqengho, http://paste.ubuntu.com/20152716/, you can assign the theme you want to use07:56
liuxgqengho,   theme.name :"Ubuntu.Components.Themes.SuruDark"07:56
qengholiuxg: It seems to be set to Ambiance. strace doesn't try to access Ambiance files, though, only hicolor .08:01
* qengho afk, back later.08:01
liuxgqengho, I have a test project for ubuntu phone at https://github.com/liu-xiao-guo/theme. I think you probably need to package the theme stuff as well.08:02
=== chihchun is now known as chihchun_afk
=== chihchun_afk is now known as chihchun
mwhudsonzyga: are you going to release snap-confine again today? :)09:06
leousahey folks, is it possible to package a Mono based app that runs perfectly on the desktop as a snap?09:10
dholbachleousa, I wouldn't see why not, but haven't heard of somebody try it yet09:12
dholbachsomebody did a MonoGame apparently: http://askubuntu.com/questions/779315/how-do-i-create-a-snap-for-a-monogame-application09:13
dholbachleousa, what does the build use? is it autotools?09:14
leousayeah i tried that, but didnt work, although im by no means a snappy expert09:15
dholbachis the source for the app available?09:15
=== robert_ancell_ is now known as robert_ancell
leousai have only found the binaries unfortunately09:16
dholbachok09:16
dholbachin that case, just using the copy plugin should be a good start09:17
dholbachadd the relevant dependencies to your stage-packages: definition09:17
dholbachand define the binary to be run in the apps: section09:17
dholbachlet me see if there's a good example of something like that somewhere09:17
leousaok great, thanks I appreciate that dholbach09:18
dholbachno worries09:18
dholbachhttps://github.com/ubuntu/snappy-playpen/tree/master/gitter-im could be a good start, it uses a Makefile to handle the custom download of a .deb package somewhere09:19
dholbachbut you could easily replace that with    source: <url of tarball or zipfile>09:19
leousai tried ldd to find the package dependencies, there were quite a few, but had issues building the yaml file09:19
leousanice, ill have a look at it09:19
dholbachor https://github.com/ubuntu/snappy-playpen/tree/master/jtiledownloader09:20
dholbachleousa, which issues did you run into?09:20
dholbachcan you pastebine the snapcraft.yaml file?09:20
leousaok give me a min09:21
dholbachsure sure :)09:22
leousahttp://pastebin.com/9RUCJZnD09:25
dholbachcool, checking09:26
dholbachok, you could copy over the Forgotten\ Myths\ CCG.x86 file from wherever you get it from? Is it a tarball or something?09:27
dholbachand you could use the package names for the libraries you're listing and add them to stage-packages:09:27
dholbachlet me try it09:27
leousayou can get the files from this link09:29
leousahttps://drive.google.com/file/d/0B6jna1aYT5M1UHpPNHJ6dER5OXc/view09:29
leousait is a game that runs nice on the Ubuntu desktop, and wanted to package as a snap09:31
kalikianaSo... after rebooting all of my snaps do this:09:33
kalikianahtop09:33
kalikianafailed to create user data directory. errmsg: Permission denied09:33
kalikianaOn gitter it was suggested it could be related to my home being encrypted09:34
dholbachleousa, something like this? http://paste.ubuntu.com/20158963/09:34
dholbachkalikiana, does scanlog say anything when you start the app?09:34
kalikianawhat's scanlog?09:34
dholbachhttp://askubuntu.com/questions/783979/how-do-i-debug-snaps09:34
kalikianaReading09:34
kalikianadholbach: Well, how would I run that? :-D09:35
dholbach?09:35
kalikianaThat's a snap...09:35
dholbachRight, you install the snap, run the commands on that page, keep the terminal open...09:36
dholbachthen run your snap09:36
kalikianaNo, you don't get my problem: Any snap I run aborts.09:36
dholbachok, sorry, I missed that bit09:36
kalikianasnappy-debug.security scanlog09:36
kalikianafailed to create user data directory. errmsg: Permission denied09:36
dholbachdoes "snap changes" say anything?09:37
dholbachis snapd in a clean state?09:37
kalikianaYes, afair all is good, nothing "pending".09:38
kalikiana(That was why I rebooted, I couldn't resolve it otherwise)09:38
dholbachI guess you need to ping zyga, mvo, pedronis and Co09:39
dholbachI don't know09:39
kalikianals -lA ~/ | grep snap09:40
kalikianadrwxrwxr-x 15 cris cris 4,0K Jul 20 11:31 snap09:40
kalikianadrwx------  2 cris cris 4,0K Jun 19 00:33 .snap09:40
kalikianaThose are my snap folder permissions if that has any relevance09:40
leousaok some progress, but throws error: Error downloading stage packages for part 'fmyth': no such package 'libx11'09:41
dholbachsorry09:43
dholbachlibx11-609:44
leousabetter09:46
leousa[Errno 2] No such file or directory: '/home/leo/Applications/FM0_9545_linux/parts/fmyth/build/Forgotten\\ Myths\\ CCG.x86'09:46
leousafunny thing is that directory and file exist09:46
dholbachhohum09:50
dholbachDo you think you can send a mail with your snapcraft.yaml (or a link to it) to the mailing list?09:51
dholbachI don't quite know how to solve this one.09:51
leousasure thing i will send it09:52
dholbachfantastic09:52
leousaok mail sent, thx again dholbach09:59
kalikianaOkay, I found a way to run snappy-debug.security: SNAP=/snap/snappy-debug/22 /snap/snappy-debug/current/bin/snappy-security-scanlog | more10:14
mupBug #22: Legal Link <lp-foundations> <Launchpad itself:Fix Released> <https://launchpad.net/bugs/22>10:14
=== rcj` is now known as rcj
kalikianaog: apparmor="DENIED" operation="open" profile="/usr/bin/ubuntu-core-launcher10:15
kalikiana" name="/home/.ecryptfs/cris/.Private/" pid=26032 comm="ubuntu-core-lau" reque10:15
kalikianasted_mask="wr" denied_mask="wr" fsuid=1000 ouid=100010:15
kalikianaSo for some reason ubuntu-core-launcher is trying to read my encrypted folder10:16
mupPR snapd#1575 opened: osutil: check for nogrup instead of adm <Created by zyga> <https://github.com/snapcore/snapd/pull/1575>10:17
Croephaso, when snappy is doing a refresh/update, and you have custom kernels and custom os snap, does snapd know to just install newer versions of the same snaps?10:42
mupPR snapd#1575 closed: osutil: check for nogrup instead of adm <Created by zyga> <Merged by chipaca> <https://github.com/snapcore/snapd/pull/1575>11:36
thurstongood morning all...  any help on figuring out some bugs?12:08
=== hikiko is now known as hikiko|ln
lfaraoneIs there ethernet available anywhere at the hotel, by the by?12:18
thurstonwhen i run my application's binary it runs with no warnings,  however when i run the application's snap, i get warnings about being unable to load libXrandr.so12:20
=== hikiko|ln is now known as hikiko
CavanI just finished the tomcat-webapp snap and installed it, is there anyway for me to check if its working correctly?13:06
CavanI just finished the tomcat-webapp snap and installed it, is there anyway for me to check if its working correctly?13:14
CroephaCavan if its a daemon, you can check its logs via journalctl13:18
ogra_or just look at the processlist to see if it runs13:18
dholbachthurston, you're on amd64 I guess? it might be looking for 32bit libraries :-(13:19
dholbachthurston, it's something I just realised13:19
ogra_we ship libc for 32bit execution in the core snap13:19
ogra_but only that ...13:19
CavanCroepha, how do I know which logs are produced by tomcat?13:20
thurstonwhy would it work on my 64bit ubuntu laptop and not my 64bit ubuntu desktop?13:21
sborovkovHello. Any ideas what could be wrong here - running my snap on armhf classic image. Application crashes  KeyError: 'getpwuid(): uid not found: - look like it can not access /etc/passwd or something related to that. Any ideas what's the differnce with usual snappy image (everything works there)?13:21
CroephaCavan find service name via: systemctl list-unit-files '*snap*'  , then you can do journalctl -u "<service name>"13:22
Croephathurston: i dont really know about the 64bit angle, but have you tried copying the .so file into the snaps usr/lib ? that usually works for me, but i fear xrandr might end up wanting more and more things until you have all of xorg in your snap13:23
Croephathurston: thurston run ldd con your executable to see what its missing13:24
thurstonoh cool, thats a neat command!13:25
ogra_sborovkov, i think snapd on classic just binad mounts the hosts /etcc/passwd readonly on top of the one in the core snap and does not use /var/lib/extrausers at all13:26
CavanCroepha, the terminal output was 'UNIT FILE STATE  0 unit files listed.' is that normal or?13:26
ogra_i'm not sure if we want the extrausers stuff to actually be identical between native snappy and snappy on classic ... zyga would be the man to knw i guess13:27
ogra_*know13:27
CroephaCavan, no, thats not normal, you should have a list of services, even without any snaps loaded, it should atleast match the system snap related services13:27
CroephaCavan: What is your OS? and what is the command you used exactly?13:28
CavanUbuntu and ' systemctl list-unit-files 'tomcat-webapp-demo_1.0_amd64.snap''13:29
CavanCroepha13:29
thurstonshould i paste the list here?13:29
CroephaCavan: i meant literally '*snap*'13:30
ogra_on http://paste.ubuntu.com/13:30
sborovkovogra_: so snap does not see the usual /etc/passwd? I have this error both in python and glib which causes assertion that stops everything13:30
sborovkovzyga: Hello, any idea ^^13:30
ogra_sborovkov, why do you need the passwd file at all ?13:30
thurstonhttp://paste.ubuntu.com/20177325/13:30
CroephaCavan: the '*snap*' is kinda like | grep snap for systemctl13:30
CavanCroepha, ah thats brilliant thanks, it says the tomcat service is enabled.13:31
sborovkovogra_: I don't need it myself. Glib get some of that during initialization. No idea why. I get this warning and consequent assert at the end of the function https://github.com/GNOME/glib/blob/master/glib/gutils.c#L67113:31
CroephaCavan, ok, so the blahblah.service is the service name, so then you can do journalctl -u blahblah.service13:31
sborovkovogra_: and PythonQt gets that as well. Idk for what purpose honestly13:32
ogra_sborovkov, aha, it seems to try to look up *your* UID13:34
ogra_yeahm thats definietly a zyga thing and possible a jdstrand one ....13:34
thurstonthe list of plugs I include in the .yaml include [x11, opengl, unity7]   and the app works on my laptop,  but not my desktop,  which use different nvidia drivers13:35
ogra_snap-confine would have to somehow get that into into the core snap before executing the app13:35
ogra_thurston, there is an open bug with the proprietary nvidia drivers13:35
looldavmor2: hey13:36
looldavmor2: ups, EPING13:36
looldavidcalle: heya13:36
looldavidcalle: around?13:36
davmor2lool: D'oh13:37
thurstonand anyone else confirm for me that my snap won't run for them?13:38
sborovkovogra_: any ideas how I could workaround that for now? Or do I need to wait for a fix basically?13:44
ogra_sborovkov, not sure, you could try bind mounting /etc/passwd on top of the ubuntu-core /etc/passwd ...13:45
ogra_that is indeed a gross hack13:45
sborovkovogra_: eh, how would I do that?13:46
sborovkovI don't care if it's very big hack if I can application running for now :)13:46
ogra_mount|grep ubuntu-core ... to find the mountpoint for the highest version13:47
ogra_then mount --bind /etc/passwd /snap/mountpoint/etc/passwd13:47
ogra_you might need the same for shadow and group files too13:48
sborovkovunderstood, I will try that, thanks13:49
sborovkovogra_: Should I file a bug for this?13:56
jdstrandsborovkov: if you specify the 'network' plug you get /etc/passwd (because the network plug uses the 'nameservice' apparmor abstraction)13:59
sborovkovjdstrand: Hmm. I have it though. (running in devmode btw)13:59
sborovkovAs I mentioned above it's working in snappy image13:59
jdstrandI think you'll find that if we allowed /etc/passwd, then it would want /etc/group, then nsswitch.conf, then networking, etc13:59
sborovkovbut not in classic13:59
diddledan_does snappy confinement prevent forking or have I got a duff compile of hexchat (the program I'm trying to snapify)?14:00
jdstrandsborovkov: oh, then that isn't a security policy thing. what it sounds like is happening is that /etc/passwd from the core snap is being used14:01
diddledan_the child process forked by the main client for each server is dying into [defunct] aka zombie state14:01
jdstranddiddledan_: snappy allows fork() be default. try getting it to work when installing in --devmode14:01
thurstonwhats the best way to include library files manually?14:02
diddledan_ok, devmode works14:02
sborovkovjdstrand: I tried mounting /etc/passwd, /etc/group, etc/shadow to ubuntu-core as ogra suggested to get it working with a hack. No luck though, still failing with the same error14:02
=== dllewellyn is now known as diddletest
diddletestsee? :-p14:03
diddledan_ok, so why does it die when used without devmode I wonder14:03
jdstrandsborovkov: ogra_ suggested waiting for zyga. he knows the current state of bind mounts and I suggest waiting for him (since we ruled out the security policy)14:03
diddledan_and thanks for the pointer, jdstrand14:04
sborovkovjdstrand: Understood, thanks.14:04
jdstranddiddledan_: use 'sudo snap install snappy-debug' then do: sudo /snap/bin/snappy-debug.security scanlog14:04
jdstranddiddledan_: that should show you (non-dbus) sandbox denials with suggestions on what you need to do14:05
thurstonwhats the best way to include library files manually?14:06
diddledan_ok, it looks like it's trying to bind - so plug network-bind might fix it14:07
diddledan_awesome. I think that's got it going14:10
mupPR snapd#1576 opened: interfaces/builtin: allow getsockopt for connected x11 plugs <Created by zyga> <https://github.com/snapcore/snapd/pull/1576>14:10
jdstranddiddledan_: great! :)14:11
diddledan_right. now to publish it14:11
diddledan_oh, I need to add a menu/launcher entry14:13
loolj-b: can you open https://myapps.developer.ubuntu.com/dev/click-apps/5203/ ?14:16
j-blool: no.14:16
=== King_InuYasha is now known as Son_Goku
ogra_sborovkov, i'll poke zyga in real life once he comes out of the session (we are at a sprint currently)14:19
loolj-b: http https://search.apps.ubuntu.com/api/v1/search Accept:application/hal+json X-Ubuntu-Release:16 X-Ubuntu-Device-Channel:edge X-Ubuntu-Wire-Protocol:1 X-Ubuntu-Architecture:amd64 'q==vlc.caldav' fields==package_name,architecture,anon_download_url,confinement14:19
thurstonwhats the best way to include library files manually?14:24
sborovkovogra_: thanks :)14:25
loolj-b: https://myapps.developer.ubuntu.com/docs API docs14:29
kalikianajdstrand: Any suggestions on ucl chokin on ecryptfs? http://paste.ubuntu.com/20182986/14:32
loolj-b: http://195.154.102.74:8000/14:33
timothykalikiana: it should be fixed in snap-confine 1.0.3614:33
mupBug #1604848 opened: Create interface for unity8 scopes <Snappy:New> <https://launchpad.net/bugs/1604848>14:39
thurstonwhats the best way to include library files manually?14:40
zygasborovkov: you should see the real /etc/passwd except for an all-snap system14:46
zygasborovkov: http://pastebin.ubuntu.com/20184274/14:46
ogra_hmm, then it is weird that getpwuid_r() actually fails14:47
zygasborovkov: run it in strace14:48
zygasborovkov: or give me the apparmor / seccomp denial14:48
zygadidrocks: you can actually bind mount files14:48
zygadidrocks: so standalone .mo or anything is ok14:48
kalikianatimothy: How/when would I get that?14:50
kalikianaWhere do I see what version I have?14:51
thurston_X Error:  BadValue14:55
thurston_  Request Major code 154 (GLX)14:55
thurston_  Request Minor code 3 ()14:55
thurston_  Value 0x014:55
thurston_  Error Serial #2214:55
thurston_  Current Serial #2314:55
thurston_thats the error i get on my desktop14:55
j-blool: done.14:55
sborovkovzyga: hmm how do I run service with strace?14:57
sborovkovzyga: I don't have any apparmor denials, I am running in devmode. Just getpwuid fails14:58
sborovkovzyga: I do see real /etc/passwd in ubuntu-core indeed. May be something else is missing, idk14:59
CavanI'm trying to make a snp of Apache Calcite but I cant find a conf file to direct a Makefile, any tips?15:00
mupPR snapcraft#675 opened: Allow godeps to fetch Go dependencies <Created by stevenwilkin> <https://github.com/snapcore/snapcraft/pull/675>15:01
magicaltroutCavan: doesn't calcite use maven?15:02
Cavanmagicaltrout, I'm not too sure, if so would I just need to direct it to a git instead of a makefile?15:03
magicaltrouthttps://github.com/apache/calcite15:03
magicaltroutin which case15:04
magicaltroutyou could use the maven plugin I expect15:04
magicaltrouthttps://github.com/ubuntu/snappy-playpen/blob/cc1e13ca60280c249034bfaa3766072387d38a22/wallpaperdownloader/snapcraft.yaml#L1515:05
Cavanmagicaltrout, do I need 'calcite:         plugin: tar-content         source: http://www.apache.org/dyn/closer.lua?filename=calcite/apache-calcite-1.8.0/apache-calcite-1.8.0-src.tar.gz&action=download' or should I use the github you just sent? I'm really new to this sorry15:06
magicaltroutme too Cavan me too! ;)15:07
magicaltroutthat tar ball would still need compiling as its a src bundle15:07
Cavanmagicaltrout, thanks!15:08
magicaltroutany time chief15:09
Cavanmagicaltrout, I've staged and snapped Calcite, any idea how I would check if its working correctly?15:13
magicaltroutokay as a disclaimer I'm a developer who has worked with calcite a bit over the years.... my understanding of it in its current state it that a build of calcite would just give you a few libs to hook up to stuff.....15:14
magicaltroutso I guess my question is, why calcite? and what are you try to achieve?15:14
Cavanmagicaltrout, Calcite was picked at random to be honest, just seeing what I can do with Snapcraft really15:16
magicaltroutlol15:16
magicaltroutokay15:16
magicaltrouti'd pick something else15:16
Cavanmagicaltrout, any recomendations on what would be better?15:16
magicaltroutsure there's lots of apache projects that would suit15:17
magicaltroutlet me peruse the list and find some15:17
magicaltroutapache drill would be a good one Cavan if you're interested in data stuff15:18
magicaltroutits a nice wrapper around calcite in reality15:18
magicaltroutyou could snap the spark engine15:18
magicaltroutkaraf15:18
magicaltrouttomcat15:18
magicaltroutkafka15:19
Cavanmagicaltrout, I'll give them all a go aha! Thanks very much15:19
magicaltroutnifi15:19
magicaltrout:)15:19
magicaltroutpick a project thats not just a library basically :)15:19
jdstrandkalikiana: yes, that is fixed in later ucl that hasn't landed yet. add this to /etc/apparmor.d/usr.bin.ubuntu-core-launcher: http://paste.ubuntu.com/20187635/15:19
jdstrandkalikiana: then do: sudo apparmor_parser -r /etc/apparmor.d/usr.bin.ubuntu-core-launcher15:19
magicaltroutzeppelin would be a good one as well Cavan15:20
jdstrandzyga, sergiusens (cc ratliff): hey, fyi some of the chrome/firefox interface issues can only be resolved once snap-confine 1.0.36 is in xenial. can one of you talk to JamieBennett or mvo to prioritize that SRU?15:21
jdstrandI'd ask them myself, but they aren't here now. I will continue to follow up with them15:21
kalikianajdstrand: woot, everything works like a charm again.15:23
* kalikiana was feeling incomplete with no snaps all day15:24
kalikianathanks!15:24
jdstrandkalikiana: np. there are bugs for that. it is queued (and will be fixed in 1.0.36 which I just asked about)15:26
zygajdstrand: ack16:01
sborovkovzyga: so any ideas what could be going wrong that getpwuid is not working16:04
mupBug #1604880 opened: Missing inhibit interface <Snappy:New> <https://launchpad.net/bugs/1604880>16:12
Croephanot that I really care at this point, but ubuntu-core essentially has a built in key-logger... pretty much every console keystroke I make gets logged as a kernel debug message16:18
mupBug #1604885 opened: Access to mounted USB drives <Snappy:New> <https://launchpad.net/bugs/1604885>16:19
mupBug #1604887 opened: MPRIS interface does not work <Snappy:New> <https://launchpad.net/bugs/1604887>16:22
thurstoncan someone test my snap out on their machine?   sudo snap install rpgdiceroller16:26
Croephathurston: not a chance, sorry, what can we do that you cant do with virtualbox?16:28
thurstonmy desktop throws me an x-window error, and i can't figure out if its because i have multi monitors or what16:30
thurstonCondition ' x11_window==0 ' is true.16:32
kalikianathurston: I'll try but without sudo ;-)16:35
kalikianacould not load libXrandr.so, Error: libXrandr.so: cannot open shared object file: No such file or directory16:36
kalikianaOnly a single monitor connected right now16:36
thurstoni didn't realize you could use snap without sudo16:37
thurstondoes the app still come up for you kalikiana?16:38
kalikianathurston: I briefly see a window which closes before I can really see it16:41
kalikianasudo is only required if you're not logged in16:41
CavanJust finished snapping Apache Zeppelin, anyone know any commands to check if i've odne it correctly?16:44
thurstonkalikiana: thanks for doing that.   i'm trying to figure out how to include libxrandr.   I've got libxrandr2 included, but apparently it doesn't care16:45
kalikianathurston: Is it in a folder in LD_LIBRARY_PATH? You might have to copy or organize the file(s)16:49
Cavan(My internet died I dont know if I just sent this) Just finished snapping Apache Zeppelin, how would I check its working correctly, can I run it or?16:51
thurstonwell,  using the plug x11,  it automatically fetches libxrandr216:55
thurstonapart from that, i don't know really what you mean by LD_LIBRARY_PATH16:56
kalikianaI mean if the lib is in a known path16:57
kalikianaAs I was having the problem before where the libs would not end up somewhere they would be found16:58
thurstonthis is part of my problem,   i've been asking how exactly to include libraries manually?16:58
CavanHow do i run a snap after installation?17:02
mupPR snapcraft#676 opened: Special handling for pc files for conflicts <Created by sergiusens> <https://github.com/snapcore/snapcraft/pull/676>17:04
thurstonsooo,  any help on how to add libraries to a snap manually?17:08
kalikianathurston: Could it be that you need a symlink?17:08
kalikianals -R /snap/rpgdiceroller/current/ | grep libXrandr.so17:08
kalikianalibXrandr.so.217:08
=== chihchun is now known as chihchun_afk
CavanHow do I run a snap from consol?17:14
CavanAnyone have any idea?17:23
CroephaCavan: is it a daemon ?17:28
CavanCroepha, I'm not too sure. Its Apache Zeppelin, snapped. But also I think I messed up the wrapper and just fixed it so I'm snapping again and seeing17:29
Croephathis is your snap?17:29
CavanYeah17:29
Croephadoes it have deamon in the app section?17:30
CavanYes17:30
Croephado you know the service name?17:30
CavanNo idea, where would I find that?17:30
Croephait should be systemctl start <service name>17:31
Croephato list snap services: systemctl list-unit-files '*snap*'17:31
kalikianaYou may want to turn the daemon: line into a comment and run it manually to see if it starts up correctly17:49
ralsinaHi there snappers! I am having a weird problem. It seems snapcraft's python3 plugin can't install things that are only available as wheels (in my case, the entrypoints package). See http://pastebin.ubuntu.com/20204182/17:51
Croepharalsina , probably should file a bug17:59
ralsinaCroepha: ack17:59
Croephais there like a --no-wheel option you can pass to pip as a short term workaround?18:00
ralsinaCroepha: well, I *need* it to install a wheel18:01
ralsinaCroepha: and the whole pip invocation is done by the python3 plugin of snapcraft18:01
ralsinaReported, bug #160490918:01
mupBug #1604909: Python3 plugin fails to install requirements that are only available as wheels <Snapcraft:New> <https://launchpad.net/bugs/1604909>18:01
Croephawell, if the goal is just to get something working as a snap, then you can bypass the python3 plugin and use the bash plugin, or the copy plugin, assuming you have built outside18:03
thurstonwow,  how is it so difficult to package a single binary spit out from a game engine?   i can execute the binary on almost any linux system i throw it at,  but when i try to snap it? nope18:05
Croephathurston: yep, its difficult18:06
kalikianaCroepha: bash plugin? I don't see any such thing in list-plugins or search18:06
Croephakalikiana: snapcraft github18:08
Croephakalikiana: https://github.com/snapcore/snapcraft/pull/66418:08
mupPR snapcraft#664: New plugin: Bash <Created by monsterjamp> <https://github.com/snapcore/snapcraft/pull/664>18:08
Croephamiss pasted18:08
CavanWhen I try and start a service I get 'bash: syntax error near unexpected token `newline''18:13
ralsinaCroepha: this used to work until recently, the snap is Nikola, worked a few days ago. I suppose some dependency changed somewhere.18:14
CavanTrying to make a command to check if my snap works, i did 'apps:  zeppelin:    command: startzep    plugs: [network-bind]' Is this correct?18:57
CavanShould I remove the plug or should it work anyway?19:10
dak__hello, i have a question about snapcraft. i tried to package the angband.19:35
dak__i managed to build te snap, but it fail to load, because it looks for game files in /share/games/angband instead of $SNAP/share/games/angband19:36
dak__i thouth compiling it with --no-install might help, since the files are all in the same directory19:36
dak__but then i get "/snap/angband/100002/command-angband.wrapper: 5: exec: angband: Permission denied" :/19:37
dak__any ideas wy the permission is denied?19:43
jdstrandkyrofa: hey, re http://pastebin.ubuntu.com/19903287/ it looks like you are using a new snap-confine? I'm guessing /var/log isn't bind mounted so it can't find /var/log/syslog20:40
magicaltrout    ttps://docs.google.com/presentation/d/1UdKSsuXpYSy25V9HuxnqgzQRmlC1DEtLJUgEY-5PDoc/edit?pref=2&pli=1#slide=id.p20:40
magicaltroutif anyone is bored enough20:40
jdstrandkyrofa: how/where are you invoking it?20:40
magicaltrouttheres the slides from tonights presentation/roasting of mark shuttleworth20:41
* jdstrand notes it works fine here on xenial classic20:41
magicaltrout2https://github.com/buggtb/snappy-maven-plugin20:41
magicaltroutthere is a maven plugin to build  a snappy yaml file and build the pacage20:42
magicaltroutpackage20:42
jdstrandballoons: re snap.juju.juju unix denial> you either need to create a juju interface or to create a named unix socket that is in $SNAP_DATA20:52
balloonsjdstrand, hmm20:52
jdstrandballoons: is this socket just for internal communications?20:53
jdstrandballoons: or are other snaps supposed to be able to consume it?20:53
tsimonq2\o/ balloons20:53
balloonsjdstrand, ahh yes, internal20:53
balloonsjdstrand, I assume I'll find some more things like this, it would be lovely if I could get some understanding how to proceed with this one20:55
jdstrandballoons: looking at the policy, you could make a smaller code change and have the abstract socket path match snap.@{SNAP_NAME}.*20:56
jdstrandballoons: so instead of /var/lib/juju/mutex-/store-lock, use snap.juju.mutex/store-lock (or something similar)20:57
jdstrandballoons: we have this rule: actually///20:58
jdstrand...20:58
jdstrandballoons: actually, what we have should maybe work for you20:59
jdstrandballoons: can you paste /var/lib/snapd/apparmor/profiles/snap.juju.juju ?21:00
balloonsjdstrand, sure21:02
jdstrandballoons: actually, if what you pasted the other day was the full denial, I think we need one more rule. Can you file a bug and add the 'snapd-interface' tag? the interfaces team would need to discuss both default policy and/or possibly a new interface. I suspect that we can add a 'unix addr=@snap.${SNAP_NAME}.*,' with no problem. that would require you to make a small code change for the path to go from /var/lib/juju/mutex-/store-lock to snap.juju.21:05
jdstrandballoons: but then it would be in your control21:05
balloonsjdstrand, so I was initially looking at changing /var/lib/juju to somewhere else21:06
jdstrandballoons: that won't work atm. with what I am thinking, we can make that work21:06
balloonsjdstrand, so I can file a bug -- against snapd?21:07
jdstrandballoons: the snappy project21:07
balloonsand you would change the default policy to allow me to bind, but against what path?21:08
jdstrandballoons: https://bugs.launchpad.net/snappy/+filebug21:08
balloonsjdstrand, ohh on launchpad? not github?21:08
balloonsohh right.. snappy uses lp. I remember21:09
jdstrandballoons: that needs discussion, but I was thinking I'd give you two rules. 1) 'unix addr=@snap.${SNAP_NAME}.*,' and 2) 'unix addr=@/var/snap/@{SNAP_NAME}/**,'21:10
mupBug #1604967 opened: Apparmor denies bind to /var/lib/juju/mutex-/store-lock <snapd-interface> <Snappy:New> <https://launchpad.net/bugs/1604967>21:11
jdstrandballoons: these aren't real paths in the filesystem-- they are paths in the kernel. we have to namespace them accordingly as a result, but by giving both paths, it makes it so that people can do things in a natural way21:12
balloonsbah, my install of snappy is still borked. I don't get any binaries after installing my snap anymore (or any other snap from the store)21:13
wililupyI have an interresting snap installation error: http://pastebin.ubuntu.com/20229623/21:19
balloonsjdstrand, I'll work out my snappy install so I can get moving again, but do let me know if you need anything from me on this. As you might be able to tell, I'd like to try and get the juju client itself snappified. It would be nice to have for next week :-)21:20
jdstrandballoons: ok, I jotted down my ideas in a trello card and assigned the bug to me21:20
balloonsjdstrand, many thanks. I assume I may hit another one of these issues, so if there's a way for me to proceed or test changes before you implement, do let me know. I'm happy to delve in a little.21:21
jdstrandballoons: we won't have a snapd that will land in time for next week, but I can give you a rule to add to /var/lib/snapd/apparmor/profiles/snap.juju.juju as a workaround21:21
wililupyI'm using a custom kernel (3.18.25) and I installed apparmor patches for 3.12, but I'm still getting the above errors. Do you know if Canonical as a patched 3.18.25 kernel in the kernel.ubuntu.com git? I can't seem to find one.21:21
balloonsjdstrand, yep proof of concept is all I'm after21:21
jdstrandballoons: add this rule: 'unix addr="@/var/snap/@{SNAP_NAME}/**",' to that file21:21
jdstrandballoons: then do: sudo apparmor_parser -r /var/lib/snapd/apparmor/profiles/snap.juju.juju21:21
jdstrandballoons: then adjust your path internally to use /var/snap/juju/mutex-/store-lock21:22
balloonsjdstrand, ok, can do. Would /var/snap/juju be safe for other binds then? What about writes?21:23
jdstrandballoons: if you just want to test out the existing path, use this apparmor rule instead: unix addr="@/var/lib/juju/mutex-/store-lock",21:23
jdstrandballoons: /var/snap/juju would be safe for all the abstract unix sockets. binds, writes, everything is allowed with that rule21:24
jdstrandballoons: so you can have 15 different abstract sockets if you wanted, all under /var/snap/juju/...21:25
jdstrandor 3 or 37. you get the idea ;)21:25
balloonsjdstrand, awesome. That might just fix things21:25
jdstrandballoons: the final rules that get implemented may be slightly different after discussing the PR, but the concept should be acceptable with no problems21:26
jdstrandballoons: also sorry it took a while to respond. I was on holiday and just got back today21:33
balloonsjdstrand, no worries at all. I'm elated to see it might get solved so quickly :-)21:34
jdstrandballoons: it's actually something I've thought a lot about. I'm glad to have a good use case21:35
diddledan_o_O I can't figure-out what travis is complaining about in regards to my PR: https://github.com/ubuntu/snappy-playpen/pull/18721:35
mupPR ubuntu/snappy-playpen#187: Update hexchat snapcraft.yml <Created by diddledan> <https://github.com/ubuntu/snappy-playpen/pull/187>21:35
mupBug #1605003 opened: cannot communicate with server - openSUSE Tumbleweed <Snappy:New> <https://launchpad.net/bugs/1605003>22:36
diddledanok, I've hit a snag with hexchat - somewhere fchown syscall is being used but I can't figure-out where - is there any way of getting a backtrace leading to the point that seccomp kills an app?22:49
ali1234diddledan: i think you would run the program without seccomp and instead inside strace, which can print a backtrace when a specific system call is used rather than just killing it22:59
ali1234something like strace -e trace=fchown -k hexchat23:00
diddledanstrace is telling me -k isn't valid with that23:01
ali1234"This option is available only if strace is built with libunwind."23:02
ali1234seems like on ubuntu it is not because -k doesn't work at all for me23:03
ali1234do you know what file it is calling fchown on? if not, strace should be able to tell you that at least23:04
diddledanseems not - all I get is "fchown(16, 1000, 1000)                  = 0"23:05
ali123416 is the filedescriptor23:06
ali1234you can find out what file it is through proc23:06
* diddledan goes hunting :-)23:06
ali1234ls -l /proc/<hexchat pid>/fd/23:07
diddledanhmm, 16 isn't there, only 0, 1 and 223:07
diddledanso it's transient23:07
diddledan0, 1 and 2 are stdio?23:08
diddledanin, out and err23:08
ali1234yes23:08
ali1234you could try strace -e trace=open,fchown23:08
ali1234then you should see when it opens the fd23:08
diddledanroger that23:08
ali1234unless it doesn't open it of course, but does fdupe or something23:09
diddledanok, let me paste the two important lines23:09
diddledanhttp://pastebin.ubuntu.com/20241932/23:10
ali1234you might need to do -e file which will make a huge log of all file access, and then pick through it23:10
ali1234ah...23:10
ali1234so it is the scrollback cache/log23:10
diddledanyeah23:11
ali1234and it is setting it to be read only by you, nobody else on the system, which is totally reasonable23:11
diddledanI think it's using glib's IO functions for those23:11
diddledanso either glib or the C library is calling the fchown23:11
ali1234yes, but it will be initiated by hexchat23:12
diddledancould this be it? >>> ostream = G_OUTPUT_STREAM(g_file_append_to (sess->scrollfile, G_FILE_CREATE_PRIVATE, NULL, NULL));23:15
ali1234yes23:15
ali1234G_FILE_CREATE_PRIVATE23:15
ali1234and the filename on disk even contains goutputstream23:16
diddledanthat helped me narrow it down23:16
ali1234that's in common/text.c?23:16
diddledanyup23:16
ali1234i was just opening that file to have a look :)23:17
ali1234but you beat me to it23:17
ali1234there's actually two places where G_FILE_CREATE_PRIVATE is used int hat file23:17
diddledanthere's two uses of that constant23:17
diddledanyeah that ^^^23:17
ali1234no idea how you are supposed to fix this though23:18
diddledanme either23:18
diddledanI'm wondering if the isolation rules might need adjusting to allow fchown to the current userid23:19
diddledan(if that's even possible?)23:19
ali1234i probably know less about that than you at this point23:20
diddledanmight be worth my while emailing the snappy-dev list so there's a more permanent record that can be commented-on23:21
ali1234yeah23:21
ali1234or ask here in business hours :)23:22
diddledan:-)23:22
diddledanI don't "do" business hours :-p23:22

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