/srv/irclogs.ubuntu.com/2017/05/04/#snappy.txt

mupPR snapcraft#1276 closed: sources: validate unknown source-type in yaml <Created by EduardoVega> <Closed by EduardoVega> <https://github.com/snapcore/snapcraft/pull/1276>02:02
mupBug #1688103 opened: Classic confinement should allow preservation of $HOME <Snapcraft:New> <Snappy:New> <https://launchpad.net/bugs/1688103>02:55
mupPR snapcraft#1297 opened: sources: validate unknown source-type in yaml <Created by EduardoVega> <https://github.com/snapcore/snapcraft/pull/1297>03:26
mupPR snapcraft#1298 opened: Reroll of proposed JHBuild plugin <Created by diddledan> <https://github.com/snapcore/snapcraft/pull/1298>03:35
=== chihchun_afk is now known as chihchun
=== chihchun is now known as chihchun_afk
=== chihchun_afk is now known as chihchun
pstolowskimorning07:07
zygagood morning!07:33
* zyga will be back soon, just overslept;07:34
* Chipaca looks around for a zyga09:38
mupPR snapcraft#1299 opened: asset-tracking: save the dependencies of build packages <Created by elopio> <https://github.com/snapcore/snapcraft/pull/1299>09:59
Son_Gokuniemeyer: yo10:38
mupPR snapd#3266 closed: interfaces: allow plugging DBus clients to introspect the slot service  <Created by jdstrand> <Merged by zyga> <https://github.com/snapcore/snapd/pull/3266>10:46
Chipacazyga: un zyga!10:48
Chipacazyga: hello, you10:48
zygaChipaca: hey, I was sleeping :/10:48
Chipacazyga: excellent10:48
* zyga feels dizzy today, perhaps it is a sign to take a day off10:48
Chipacazyga: if you're not feeling well, get out of here10:49
Chipacazyga: don't want to get internet cooties10:49
zygaChipaca: I just flet sleepy10:50
zygaI'll file half a day off and take it slow10:50
Chipacazyga: how many hours did you sleep?10:50
zyganot sure, I just got back here10:51
Chipacazyga: (if you're late from sleeping too much because the other days you were working late instead of sleeping, i don't think you should file half a day)10:51
zygano, last night my daughter decided to stuff instead of behaving like a normal child, she was up way past 1AM10:51
Chipacadaughters gonna daught10:52
zygahaha10:53
zyganice :)10:53
Chipacazyga: i've addressed your concerns in etelpmoc i think10:55
Chipacazyga: fwiw ${!x} is variable indirection10:55
Chipacai.e. if $x is foo, ${!x} is $foo10:55
zygaindirection? so like ${${x}} ?10:55
zygaa10:55
zygaah10:55
zygawow10:55
zygaI didn't know that10:55
* zyga does that in make but not in bash10:55
* zyga hugs make10:55
Chipacazyga: i suspect https://travis-ci.org/snapcore/snapd/builds/228530132?utm_source=github_status&utm_medium=notification is the hook timeout thing11:01
zygaChipaca: looking11:01
zygaChipaca: though it should no longer time out AFAIK11:02
zygaha11:02
* zyga looks at details11:02
zygaah, yes11:02
zygaperhaps master is not merged into this yet?11:02
Chipacazyga: that's correct, this is merging release/2.25 back into master11:06
Chipacaall it is is the changelogs11:06
Chipacaas such, I'm merging them even though travis is grumpy11:07
Chipacazyga: ok?11:07
Chipacaagj! i can't11:07
Chipacawell... not on the website anyway11:07
Chipaca:-)11:07
zygaChipaca: I think we can merge master into that branch11:08
zygaChipaca: then it will merge11:08
zygaChipaca: it's silly but should work11:08
* zyga tries11:08
Chipacazyga: i can do this11:08
Chipacaalready have the branch11:08
zygaok11:08
zygaChipaca: question about the oldish PRs11:09
zygaChipaca: I feel we should fork and close the old PRs where we cannot push into them directly11:09
zygaChipaca: and take them over11:09
Chipacathere, merged master11:09
zygaChipaca: thanks!11:09
Chipacazyga: which ones can't we push into directly?11:09
Chipacazyga: (yes, fork and close those, but which?)11:10
zygaChipaca: those that do not belong to team members, e.g. https://github.com/snapcore/snapd/pull/286911:11
mupPR snapd#2869: interfaces/builtin: add online-accounts-service interface <Created by mardy> <https://github.com/snapcore/snapd/pull/2869>11:11
Chipacazyga: that one says i can push to it11:11
zygaChipaca: oh? maybe bad example11:12
* zyga looks11:12
zygayes11:12
Chipacathey would've had to manually untick the "let team members push" for it to be the case11:12
zygaah, that's good then11:13
zygamaybe it's a new thing; I didn't see this before on those branches11:13
zygaor maybe they ticked that back in between :)11:13
Chipacazyga: what do you want to do with snapd#3264?11:13
mupPR snapd#3264: tests: remove quoting from [[ ]] when globs <Created by zyga> <https://github.com/snapcore/snapd/pull/3264>11:13
zygaChipaca: yeah, I'll look11:14
zygaChipaca: I think you are right11:14
zygaChipaca: and it might explain why it worked before11:14
zygaChipaca: the test was buggy twice11:14
Chipacazyga: morphis replied there11:14
zygaChipaca: so it worked11:14
zygaChipaca: oh, looking11:14
Chipacahehe11:14
zygahaha11:15
zyganice11:15
zygamorphis: thanks; I'll correct that11:15
zygadone11:16
ChipacaI'm still disappointed [[ doesn't properly ligature into 〚11:16
zygaoh11:17
zygait does :)11:17
zygabtw, I have to show this to you11:17
zygaif you like things like that11:17
zygahttps://github.com/tonsky/FiraCode11:18
Chipacathere's a emacs mode that does that sort of thing when writing haskell11:18
zygaif you work in atom11:18
zygait works in any language11:18
zygaand I must say it does look very pretty and readable11:18
zygaI use it11:18
Chipacai tried atom, but no11:18
Chipacamuscle memory is a good thing to have, and it's wasted in atom11:18
zygayou can use any editor that can grok font features like that11:18
Chipaca(also, if i use emacs instead of atom, i can finally point at it and laugh about memory usage!)11:19
zygait's juts that only atom did (for the set that I tried)11:19
zygaterminal is too dumb11:19
zygaand I bet emacs (which I dind't try, or I'd be still trying to close it ;-) can too11:19
zygahahaha11:19
zygawell11:19
zygaI hate atom for constantly using 5-15% CPU11:19
zygafor whatever11:19
zygaand using 1.5GB of ram11:20
Chipacaclosing emacs is really hard: File -> Quit11:20
Chipaca:-P11:20
Chipaca(but, yeah, muscle memory)11:20
zygaoh, it seems to work in kde kosole11:20
zygaI know ^C^X11:20
zygaor something like that11:20
zyga^X^C11:21
Chipacahalf of the time if i have to think of it i don't get it11:21
Chipacalike, the combo for making a paragraph of text justified to a certain width11:21
zygaI ran vim to try11:21
zygavim prints :quit instructions if you do :)11:21
zygaI know how to use emacs but I just prefer vim11:22
Chipaca:-)11:22
zygayeah11:22
zygaI know how to do that in vim but I cannot remember, I have to just do it by trying11:22
Chipacayeap. And that's great :-)11:22
Chipacaso why waste it11:22
Chipacaanyway. lunch.11:23
zygaok, we have 30 branches11:23
zygaI'm taking oldest one11:23
zygaok, let's skip that one11:23
zygaI'll take 2nd oldest (mine)11:23
* didrocks is really happy about Visual Studio Code for any Go development. Doesn't use (from my testing) as much memory or CPU that atom, more feature, and font ligature with Fira Code as mentioned ;)11:24
Chipacadidrocks: when it's in a snap i'll try it :-)11:28
mupPR snapd#3270 opened: adjust Nice and oom_score levels for snapd <Created by ogra1> <https://github.com/snapcore/snapd/pull/3270>11:29
zygaChipaca: there's a snap11:33
zygaChipaca: sergio uses it11:33
zygadidrocks: I love visual studio code btw11:33
zygadidrocks: I really wish some of the new editors could be used on windows with ubuntu for windows11:33
zyga(but if you do your files are wasted, poor implementation from microsoft)11:33
didrockszyga: yeah, I don't personnally have that issues, but indeed, this is one I imagine11:36
zygadidrocks: well, on real ubuntu I just use vim :)11:38
* didrocks would miss sourcegraph on pure vim11:39
* ogra_ is always annoyed ending up with all the ":wq"'s in non vim edited files :P11:40
zygadidrocks: what is sourcegraph?11:41
zygahehe11:41
mupPR snapd#3271 opened: cmd/snap-confine: use /etc/ssl from the core snap <Created by morphis> <https://github.com/snapcore/snapd/pull/3271>11:42
morphiszyga: ^^11:42
zygamorphis: +111:44
zygamorphis: could we reuse the /etc/alternatives test11:44
zygamorphis: and use environment trick to multiply it?11:44
zygamorphis: I think it largely does this already11:44
morphiszyga: sure11:44
zygamorphis: can you please?11:44
zygamorphis: (feel free to rename it to something appropriate)11:44
zygamorphis: and this is very nice, it should fix docker on openssl!11:45
zygaer11:45
zygaopensuse :D11:45
zygaopenthis openthat11:45
morphisdocker and lxd :-)11:45
morphiszyga: there is something still wrong in the test, however enough for a first review :-)11:46
didrockszyga: https://sourcegraph.com/, you can look up for references, how certain APIs are used in the wild (on github in particular), have the documentation and referenced linked to any usage, even in a PR on GH11:51
didrocksdoesn't work in all languages, but quite awesome in Go :)11:51
zygadidrocks: interesting11:59
zygaChipaca: question, I need to teach interfaces about "snap try"12:02
zygaChipaca: we have snap.ConfinementType12:02
zygaChipaca: but that doesn't feel quite right12:03
Chipacazyga: tell me more -- why does snap try affect interfaces?12:03
zygaChipaca: because in try mode on encrypted $HOME we need special internal snippet12:04
zygaChipaca: I see that we also have interfaces.ConfinementOptions12:04
zygaChipaca: and that feels good, it's a struct with booleans12:04
Chipacatry is not a confinement type12:04
zygaChipaca: it's not a type12:05
Chipacaif you need it exposed, doing it via ConfinementOptions feels better, yes12:05
zygaChipaca: (not ConfinementType, ConfinementOptions)12:05
zygayeah12:05
Chipacazyga: yeah, was responding to your "we have snap.ConfinementType"12:05
zygaI'll do that12:05
zygaright12:05
zygaIRC :)12:05
zygathanks!12:05
zygaI didn't remember we have COptions12:05
zygacrypted home is funky12:30
zygaChipaca: it's funny that all the work that went into update-ns can be reused from snapd now12:31
zygaChipaca: (as in looking for mounted cyptfs in /home)12:31
Chipacazyga: hilarious12:31
zygaChipaca: well, unexpected benefit of writing it in go12:31
Chipaca:-)12:32
Chipacai think i need a nap12:32
* Chipaca grumpy12:32
zygaChipaca: do! I feel better after!12:33
zygaChipaca: siesta :)12:33
zygaChipaca: still here?12:41
* zyga traces the code from daemon to see what's happening12:42
Chipacazyga: yes12:46
zygaChipaca: I'm trying to grok if snap.Info is sufficient to know where snap try is coming from (where's the directory)12:48
* zyga would like to have a nice "snap list --internal" or something that showes all the data without any transformation but with mimimal pretty printing12:48
Chipacazyga: just hit the rest api :-)12:49
Chipacahttp snapd:///v2/snaps/thesnap12:49
zygaah12:49
* zyga tries12:49
zygahmm12:50
Chipacazyga: the "trymode" in the rest api is gotten from snapstate12:50
zygaseems not :/12:50
zygaI need the actual directory12:50
Chipacaah! you need the actual directory?12:50
zygayep12:51
zygaI might infer that from bind mount data12:51
zygabut scary12:51
* zyga looks at state12:52
niemeyerSon_Goku: Heya12:52
niemeyerHi all12:53
ogra_yo12:53
zygaChipaca: ah, we dont store that at all!12:53
zygaChipaca: it's thrown out after the change is done12:53
zygahey niemeyer12:53
Chipacazyga: it's SnapPath in the SnapSetup12:53
zygaChipaca: yes but that's in a change12:54
zygaChipaca: not in the state :/12:54
zygaChipaca: (snap state)12:54
Son_Gokuniemeyer: hey, so the snappy sprint date sounds good to me12:56
Son_Gokubut I need to first see if I can get the vacation block ;)12:56
niemeyerSon_Goku: Sounds good, fingers crossed12:56
Chipacazyga: sounds like maybe we should store it in there if it's needed13:00
morphiszyga: any idea why I get: [  306.778066] audit: type=1400 audit(1493902786.616:133): apparmor="DENIED" operation="mkdir" profile="/usr/lib/snapd/snap-confine" name="/run/snapd/lock/" pid=8144 comm="snap-confine" requested_mask="c" denied_mask="c" fsuid=0 ouid=013:00
morphiszyga: that is with my PR and latest snap-confine from master13:01
zygamorphis: can you join our standup maybe?13:03
morphiszyga: in another meeting right now13:03
mupPR snapd#3249 closed: releasing package snapd version 2.25 <Created by mvo5> <Merged by chipaca> <https://github.com/snapcore/snapd/pull/3249>13:03
morphiszyga: anything important or you just want to talk about the error above?13:04
zygamorphis: no, just wanted to have you in our standup13:04
morphiszyga: ah :-)13:04
morphiszyga: then feel free to put me on the attendees list13:04
morphisif we're over here soon I will join13:05
zygaok13:05
zygaI cannot do that thou13:05
ogra_morphis, i think zyga meant "join it on a regular base" ... is the meeting you have right noow reguar at this time ?13:11
morphisogra_: just every thursday, ever other day is fine13:12
ogra_ah, cool13:12
zygafgimenez: so the logs there have little information, perhaps the test needs to be tweaked to connect plugs/start docker some way?13:16
* zyga is unsure13:16
fgimenezzyga: not sure, running in qemu right now, will let you know how it goes13:16
fgimenezzyga: looks like a timing issue, from the debug console after the error "docker info" works just fine http://paste.ubuntu.com/24511102/13:19
zygayeah, it looks ok13:20
zygaI wonder if this is intentional: Debug Mode (server): true13:20
mpt<https://snapcraft.io/> is full of references to meta/snap.yaml. Is that (a) an old name for snapcraft.yaml, (b) a replacement for snapcraft.yaml, or (c) something else entirely?13:32
davidcallempt, c13:33
zygampt: c, it's a file read by snapd13:33
zygampt: it's a file that describes a built snap13:33
mptaha13:33
mptdavidcalle, zyga: Thanks. So does snapcraft (for example) produce the meta/snap.yaml as part of its output?13:34
pachulokyleN: are you around?13:34
pachulosorr, i meant kyrofa13:35
davidcallempt, it's part of the produced snap13:35
zygampt: yes13:35
zygampt: it should be in prime/13:35
=== chihchun is now known as chihchun_afk
=== jospoortvliet_ is now known as jospoortvliet
mptzyga, so meta/ is old-and-busted, and prime/ is new-hotness?13:41
zygampt: no13:41
zygampt: after you build something with snapcraft you should be able to see the unpacked snap in prime13:42
zygampt: including snap.yaml in prime/meta/snap.yaml13:42
zygampt: sorry, I didn't mean to imply that it is in a wrong place13:42
mptzyga, ok, so if snapcraft isn’t involved then there’s no prime/ directory?13:42
morphiszyga: I am struggeling a bit to work with a self-build snap-confine, what is the best way to test one? just running $ make hack?13:43
zygampt: yes13:44
zygampt: prime is just a way that snapcraft implements its internal things13:44
zygampt: snapd only looks at the build artefacts that are placed into the squashfs13:45
zygamorphis: yes13:45
zygamorphis: make hack works wonders :)13:45
* zyga uses it all the time13:45
zygamorphis: note that you need to bind mount it to core too13:45
zygamorphis: or use the version that ties this into the reexec flag13:45
zygamorphis: or snapd will still load snap-confine from core13:45
mptzyga, understood, thank you. (Asking these questions because I have the job of reviewing+tweaking the snapcraft.io front page.)13:45
zygampt: great, I'm glad to help13:47
zygajdstrand: hey, do you remember by any chance how 14.04 style encrypted home directory looked like13:47
zygajdstrand: what kind of filesystem was thta?13:47
* zyga looks for 14.04 iso13:47
morphiszyga: something like `SNAP_REEXEC=0 snap run --shell hello-world` shoudl work?13:51
zygamorphis: perhaps, just check if SNAP_REEXEC is the right variable13:51
zygamorphis: or just to be sure13:51
zygamorphis: bind mount snap-confine from distro over that in core13:52
zygamorphis: then it always works13:52
morphiszyga: if I add printf statements in snap-confine, should I see the output?13:52
mupPR snapd#3272 opened: add interfaces-shutdown-introspection spread test <Created by jdstrand> <https://github.com/snapcore/snapd/pull/3272>13:53
zygamorphis: yes13:53
zygabtw I was looking at systemd apis13:53
zygaI may start using them to log errors13:54
zygathey are really lovely!13:54
jdstrandzyga: like on all releases, it is a stacked filesystem13:54
zygajdstrand: right but I recall it was different in 14.0413:54
zygaI checked how it looks like in 16.0413:54
jdstrandzyga: you mean the apparmor paths?13:54
zygajdstrand: no, I mean how it is reapresented13:54
zygajdstrand: I want to look through the mount tables to check if there's an encrypted home in use13:55
jdstrandzyga: what you are describing I don't know what you are talking about. I know this:13:55
jdstrand  # encrypted ~/.Private and old-style encrypted $HOME13:55
jdstrand  owner @{HOME}/.Private/** mrixwlk,13:55
jdstrand  # new-style encrypted $HOME13:55
jdstrand  owner @{HOMEDIRS}/.ecryptfs/*/.Private/** mrixwlk,13:55
zygajdstrand: I know that too :)13:55
zygajdstrand: on 16.04 there's en "ecryptfs" mounted13:55
zygajdstrand: what is used on 14.04?13:55
* zyga checks anywy13:55
zygajdstrand: no worries, I'll find out soon enough :)13:56
jdstrandzyga: so if it is other than that, 'no, I don't remember' (I never knew ;)13:56
jdstrandzyga: you might ask Tyler (he is sprinting) if you can't get to the bottom of it13:56
zyganah I will know in 15 minutes13:56
zygajust installing 14.0413:57
zygaChipaca: question/suggestion, I think we ought to track "snap-try" origin in state13:57
zygaChipaca: now where is the question? in side-info? feels icky13:57
jdstrandmorphis: to answer your question, your denial for 'c' on '/run/snapd/lock/' is because in whatever mount namespace snap-confine is currently running in, that dir doesn't exist13:58
morphisjdstrand: hm13:59
zygamorphis: ah, you may need to do one more thing13:59
zygamorphis: you may need to bind mount the apparmor profile13:59
morphisjdstrand: I got that with a simple $ snap run --shell13:59
zygamorphis: from the distro onto the core snap13:59
morphiszyga: bind mount?13:59
zygamorphis: then restart snapd13:59
jdstrandmorphis: what distro?13:59
morphisjdstrand: Ubuntu 16.04 but with a self-build snap-confine13:59
* jdstrand wonders why people are bind mounting apparmor profiles...13:59
zygamorphis: mount --bind /etc/apparmor.d/usr.lib.snapd.snap-confine.real /snap/core/current/etc/apparmor.d/usr.lib.snapd.snap-confine.real14:00
jdstrandah14:00
zygajdstrand: deelopment14:00
zyga;)14:00
jdstrandyes14:00
zyga:D14:00
morphiszyga: why is that needed at all?14:00
Chipacazyga: (thinking)14:00
morphisif I set SNAP_REEXEC=014:00
zygamorphis: because snapd creates a new profile at runtime14:00
zygamorphis: any SNAP_REEXEC is probably not working :)14:00
zyga(just guessing)14:00
zygaI bet it's not working and then you get the wrong snap-confine and the wrong profle14:00
morphiszyga: when I call $ snap run --shell .. how is snapd then involved?14:00
zygaif it did work you would not need to bind mount anything14:00
zygamorphis: snapd compiles the apparmor profile of snap-confine from core on startup14:01
zygamorphis: maaaagic ;)14:01
zygamorphis: look at /etc/apparmor.d14:01
morphiszyga: hm, I have snapd already running, calling `make hack` and then immediately `snap run --shell` afterwards14:01
zygamorphis: do the bind mount14:02
zygamorphis: reload snapd14:02
zygamorphis: it'll work14:02
zygaor check what really controls reexec14:02
jdstrandmorphis: to be more clear. if there is a bug in reexec, then snapd is loading the profile from /snap/core/current/etc/apparmor.d/... and not one that you may have loaded14:02
zygamorphis: AFAIR there's a patch that fixes some of that (maybe reexec is unconditional)14:02
jdstrandmorphis: so if you bind mount over the one in /snap/core, you trick snapd to load your profile14:02
morphisjdstrand, zyga: I still don't get how snapd is involved when I run $ snap run --shell14:03
zygamorphis: it isnt14:03
zygamorphis: but ... if snap run doesn't grok reexec feature14:03
zygamorphis: and for whatever reason goes to "reexec" (not really) by running snap-confine from the core snap14:03
morphisfrom what I read in the code it shouldn't with SNAP_REEXEC=014:03
zygamorphis: then the apparmor profile for snap-confine in the core snap applies14:03
zygamorphis: well, debug away :)14:04
zygamorphis: note: snap also reexecs14:04
zygamorphis: so your snap reexes into core "snap" then runs snap-confine from either core or distro14:04
jdstrandmorphis: like zyga says, it doesn't. but, if you restart snapd for some reason and this reexec logic isn't right, then the profile in /snap/core gets loading into the kernel14:04
morphisok, I see14:04
zygamorphis: and to finish that sentence, snapd on startup generates and loads the apparmor profile for snap-confine based on what is stored in the core snap14:04
zygamorphis: (for the snap-confine from /snap/core/123/usr/lib/snaps/snap-confine)14:05
jdstrandmorphis: you should be able to apparmor_parser -r /path/to/the/profile/you/want/loaded and *not* restart snapd and have it work too14:05
zygamorphis: each copy of snap-confine has a distinct profile14:05
* jdstrand is assuming there is a bug in reexec, as zyga guessed14:05
morphiszyga, jdstrand: ok leaving the profile beside, I've added a few printf statements to my self-build snap-confine binary and then don't show up when I run snap run, bind mounts in place etc.14:08
zygamorphis: does it show when you run it manually?14:09
zygamorphis: did you forget to make hack again?14:09
zygamorphis: note that after you bind mount I think make hack does weired stuff14:09
zygamorphis: not sure14:09
zygaweird*14:10
zygamorphis: also journal has useful hints on reexec14:10
morphiszyga: no I didn't, also verified with strace, however let me play a bit more14:13
pcercueihi14:13
pcercueiI'm trying to package an app that requires a specific udev rule14:13
pcercueiis there support for that?14:13
zygapcercuei: can you tell me more about the rule14:19
zygapcercuei: it is possible but it requires an interface14:19
zygapcercuei: that is merged in upstream snapd14:19
pcercueiSUBSYSTEM=="usb", PROGRAM=="/bin/sh -c '/usr/bin/iio_info -s | grep %s{idVendor}:%s{idProduct}'", RESULT!="", TAG+="uaccess"14:22
pcercueithat's my rule right now. "iio_info -s" scans the compatible USB devices, the udev rule gives users access to those14:23
pcercueithe 'iio_info' tool would be inside my snap14:23
zygapcercuei: hmm, that would not work then14:23
zyga(we don't have support for running helper progams from snaps)14:23
pcercueiI can change the rule for a standard idVendor/idProduct check without calling an external program14:23
zygabut we may have something else...14:24
zygapcercuei: so14:24
zygapcercuei: do you have your own gadget snap?14:24
zygapcercuei: we have the iio interface14:24
zygapcercuei: your gadget can describe such devices14:24
zygapcercuei: and then your app can have a plug to consume it14:25
pcercueiit's a bit more complicated than that14:25
zygapcercuei: note that I have no idea what iio is in practice, I read the kernel docs about that a while ago but I never tried using anything like that14:25
pcercueiIIO is a kernel framework, so I assume the 'iio' interface of snaps grant access to /dev/iio:deviceX and /sys/bus/iio/*14:26
pcercueihowever here, I'm doing IIO over USB14:26
pcercueiwith a server that uses FunctionFS on the USB device, and acts as a RPC more or less14:27
pcercueithe client is libiio, which uses libusb to communicate with the server14:27
pcercueiSo the 'raw-usb' plug works fine in my snap, as long as the udev rule is installed14:28
zygait adds access to /sys/bus/iio/devices/$specific_device/14:28
zygapcercuei: the problem is that we don't have any hotplug capability in snapd yet14:29
zygapcercuei: and thus any such iio slot must be declared statically by the gadget snap14:29
zygapcercuei: the rest should work OK14:29
morphiszyga, jdstrand: ok got it working now, not sure what my problem was before14:30
morphiszyga, jdstrand: thanks anyway!14:30
pcercueiI don't really care about hotplug - but when my snap starts, it should be able to see an already-plugged compatible device14:30
pcercueiotherwise that means I have to ask my users to install a .deb so that the udev rule is installed, which defeats the purpose of having a one-file package14:32
zygapcercuei: not that your app, to get that permission needs an interface connection14:32
zygapcercuei: something on the system must show that there's a "iio" slot available14:33
zygapcercuei: and your app (and the snap containing it) must declare an "iio" plug14:33
zygapcercuei: and something must make the connection between the two14:33
zygapcercuei: only then can your app actually use that device14:33
zygapcercuei: and note that this only works in a core system with just snaps (no debs) so that you can use a gadget snap14:33
zygapcercuei: does that make sense to you?14:34
=== fede2_ is now known as fede2
pcercueinot really14:35
zygapcercuei: ok, let's start from one basic thing14:35
pcercueiwhat on the system would say that there's a 'iio-usb' slot available?14:35
zygapcercuei: snaps get permissions only when an interface is connected14:35
zygapcercuei: (we'll get to that)14:35
zygapcercuei: a connection is made between a plug (consumer) and a slot (provider) that are compatible14:36
zygapcercuei: any snap can declare a iio plug14:36
zygapcercuei: but iio slots can only come from gadget or core snaps14:36
pcercueiYes; in my case, I plug to the 'usb-raw' slot14:36
zygapcercuei: becase there is no hot-plug detection the core snap does not declare any iio slots14:36
zygapcercuei: that leaves us with the gadget snap14:36
zygapcercuei: I'm unsure I understand how usb-raw and iio interplay here14:37
pcercueiforget about IIO14:37
pcercueiI'm just trying to communicate with a USB device; the data I transfer is related to IIO, but that's not relevant here14:38
zygapcercuei: so when you use usb-raw what denials are you getting?14:39
pcercueiThe problem I have, is that while I plug to 'usb-raw', I still can't communicate with the USB device, because it belongs to the 'root' user and isn't accessible by other users of the system, unless a udev rule is here to say so14:40
zygaaha14:40
pcercueiif I run my snap app with sudo, the USB device is properly detected14:40
zygaso the app itself runs as an ordidinary user?14:40
zygaok14:40
zygaI get it now14:40
zygathis is a different issue, sorry for the confusin14:40
zygaconfusion*, one sec14:40
pcercueino problem :)14:40
Chipacazyga: wrt trymode, i think it's right that it goes in SnapState's Sequence14:40
Chipacazyga: what's more, i think trymode as a flag on SnapState itself is wrong14:41
zygaChipaca: yep, I agree14:41
Chipacazyga: (it's wrong, and results in buggy output in "snap list --all" when you have a snap installed and then do 'snap try' of the same snap14:41
Chipaca)14:41
zygapcercuei: https://forum.snapcraft.io/t/snappy-and-users-and-groups/33114:42
zygapcercuei: have a look at this thread please14:42
zygapcercuei: it describes where we are with that14:42
pcercueithanks14:43
* zyga is starving but will be back soon14:43
zygapcercuei: 2. supporting device access via ACLs for granting access of devices to (non-root) users. https://launchpad.net/bugs/164614414:43
mupBug #1646144: ACLs to devices need to be supported in core  <Canonical System Image:Confirmed for pat-mcgowan> <Snappy:Fix Committed by ogra> <ubuntu-core-meta (Ubuntu):Fix Committed by ogra> <https://launchpad.net/bugs/1646144>14:43
ogra_thats fixed in edge14:43
zygaogra_: that's just a sliver of the problem14:43
zygaogra_: the whole thing is not implemented14:43
ogra_yeah14:45
pcercueiah, that's unfortunate14:45
ogra_well, using a gadget and adding the rule there would work though ...14:45
ogra_as well as adding the rule manually to an image14:45
ogra_(its just linux after all ... )14:46
kuhlmantI have submitted for a name in the Ubuntu Store, 'mojo' to be used for a snap. This was a couple of days ago and I'm wondering what the process is and the expected processing time?14:51
zygaogra_: not sure, can a gadget add arbitrary udev rules?14:52
zygaogra_: the problem is that the user running this isn't root14:52
ogra_well, the rule is run by udev14:53
zygaogra_: which rule? can a gadget add arbitrary unconfined rules?14:53
ogra_and i think you are able to ship anything in system-data/etc/14:53
ogra_iirc ubuntu-image has code to copy all such stuff14:54
morphiszyga: updated https://github.com/snapcore/snapd/pull/3271 and combined both test cases14:55
mupPR snapd#3271: cmd/snap-confine: use /etc/ssl from the core snap <Created by morphis> <https://github.com/snapcore/snapd/pull/3271>14:55
Chipacakuhlmant: i think you need to start a forum thread about it14:56
pcercueiogra_: gadget snaps look like something to generate OS images14:59
kuhlmantChipaca: I guess I can do that, I didn't think there as much to discuss so haven't. If starting a forum thread is the standard process though I will. What is next typically?14:59
pcercueiogra_: my snap would run on Ubuntu, Debian, Fedora etc.14:59
ogra_pcercuei, yes, indeed they are ... zyga mentioning the gadget above made me think you were on UbuntuCore, sorry15:00
pcercueiok15:00
ogra_(i could have asked :P )15:00
ogra_though i couldnt imagine an UbuntuCore multi-user system ... that could have told me what you want :)15:01
morphiszyga: you remember when you looked into https://bugs.launchpad.net/snappy/+bug/1644573 which parts of the go std library were trying to use IPv6?15:02
mupBug #1644573: snapctl causes hooks to attempt to open ip/ipv6 tcp connection <Snappy:Triaged by zyga> <https://launchpad.net/bugs/1644573>15:02
stationcan ubuntu core be instaled as an Gateway/Router/Server or is it a bad idea, is there a tut15:23
station+firewall15:23
mupPR snapd#3273 opened: tests: wait for the docker socket to be listening <Created by fgimenez> <https://github.com/snapcore/snapd/pull/3273>15:27
Chipacastation: yes it can (dell is shipping such a thing for example)15:27
stationwell I cnow but is there a DIY Tut?15:28
stationif I set to grab a firewal Docker Image and sow on, would't that either take for ages or function like crap at the moment15:30
stationor can I plunge myself into the unknown and be a happy Firewall/ Gateway /Router/Server user in like 5h15:32
Chipacastation: I don't think there's a tutorial aimed at that specifically15:45
Chipacastation: but if what you're looking for is to create a one-off thing, as opposed to a product, it's merely a question of installing the right snaps15:46
ogra_there should be a ufw snap15:54
ogra_and there is a wifi-ap snap15:54
ogra_so a firewall and an AP are definitely possible15:55
* ogra_ wouldnt put docker in the loop ... thats just useless overhead15:55
kyrofaHey pachulo, did you need me?15:58
mupBug #1688103 changed: Classic confinement should allow preservation of $HOME <Snapcraft:Invalid> <Snappy:Invalid> <https://launchpad.net/bugs/1688103>16:03
mupPR snapd#3264 closed: tests: remove quoting from [[ ]] when globs <Created by zyga> <Merged by chipaca> <https://github.com/snapcore/snapd/pull/3264>16:10
mupPR snapd#3267 closed: cmd: make rst2man optional <Created by morphis> <Merged by chipaca> <https://github.com/snapcore/snapd/pull/3267>16:10
mupPR snapd#3254 closed: tests: re-enable and moderninze /media sharing test <Created by zyga> <Merged by chipaca> <https://github.com/snapcore/snapd/pull/3254>16:11
Chipacazyga: super easy review: snapd#327016:13
mupPR snapd#3270: adjust Nice and oom_score levels for snapd <Created by ogra1> <https://github.com/snapcore/snapd/pull/3270>16:13
Chipacapstolowski: zyga: and please finish your reviews of my completion branches...16:17
pstolowskiChipaca, will do tomorrow first thing in the morning, sorry about that16:18
Chipacamorphis: thanks!16:22
mupPR snapd#3270 closed: adjust Nice and oom_score levels for snapd <Created by ogra1> <Merged by chipaca> <https://github.com/snapcore/snapd/pull/3270>16:22
morphisChipaca: np16:23
mupPR snapd#3240 closed: snap: add `snap refresh --time` option <Created by mvo5> <Merged by chipaca> <https://github.com/snapcore/snapd/pull/3240>16:24
* ogra_ hugs Chipaca 16:26
diddledanwhat should I put in the CLA form for "Canonical Project Manager or contact" so that my snapcraft submission can be accepted?16:28
* zyga will soon return to code reviews16:32
Chipacadiddledan: what options are there?16:34
diddledanit's a blank text field16:34
diddledanbut it won't accept a blank entry16:34
Chipacadiddledan: ah. Jamie Bennet16:35
diddledanok I took that. agreement now signed \o/16:35
diddledans/I/it/16:35
Chipaca:-)16:36
=== daniel1 is now known as Odd_Bloke
jdstrandzyga: hew, fyi, be87d017 broke 'make check' on (at least) xenial and earlier because it doesn't support -x17:05
jdstrandzyga: 'make check' for snap-confine when shellcheck is installed that is17:06
jdstrandhey*17:06
jdstrandzyga: and uninstalling shellcheck makes 'make check' fail17:08
jdstrandzyga: ugh, all the annotations need a newer shellcheck17:11
jdstrandwell, maybe not all, but a bunch17:11
jdstrandworkaround seems to be to install shellcheck from zesty17:13
jdstrandzyga: does this ^ mean 'make check' isn't run during the LP builds? that would be unfortunate17:14
jdstrandzyga: it seems the fix would be to check if '-x' is supported and if not, skip the syntax check17:15
jdstrandzyga: or checking 'shellcheck --version'17:16
jdstrandzyga: or shipping shellcheck in the sources so it is always the same17:16
jdstrandanyway, I'm not blocked17:17
zygare17:31
zygajdstrand: ay, I know about shellckeck, unfortunate :/17:31
zygajdstrand: you can make it pass by re-running autogen.sh17:32
zygajdstrand: shellcheck is written in haskell so insane to ship17:32
zygajdstrand: I thought about it and my secret desire is to have a shellcheck backport as everything else is hard (including shellcheck as a snap)17:32
zygajdstrand: or alternatively do a non-backport update of shellcheck17:34
zygajdstrand: but that's something foundations would have to comment on17:34
zygaslangasek: hey17:34
jdstrandinteresting17:34
zygaslangasek: quick question; what is easier, backport newer shellcheck to xenial or use shellcheck as a snap while building snapd?17:34
zygaslangasek: interestingly we could move the package from xenial to, say, zesty, and then do xenial backports17:35
jdstrandafaik the former since the latter isn't supported (declaring Build-Deps on snaps)17:35
zygaslangasek: then zesty shellcheck is good17:35
jdstrandyou also can't do LP builds for the archive against -backports17:36
zygajdstrand: aww :/17:36
jdstrandarchive builds*17:36
zygajdstrand: right17:36
zygajdstrand: well17:36
zygajdstrand: I think it's semi-ok17:36
zygajdstrand: what need to change17:36
zygajdstrand: is that >16.04 builds should pull in shellcheck17:36
jdstrandsru 0.4.4 to xenial would be fine17:36
zygajdstrand: then we'll know during daily CI via adt17:36
zygajdstrand: yeah? I'll check if it builds quickly17:37
jdstrandbut, really, as you say, just skipping the shellcheck where the version is known not to work is fine17:37
jdstrandit is just we don't want to disable all of 'make check' to avoid the shellcheck issue17:37
* zyga has a love hate relationship with shellcheck, it's amazing and haskel is interesting but man, haskel toolchain stuff is terribly annoying to work with17:37
zygajdstrand: oh, I think it's not that, we just skip shellcheck17:37
zygajdstrand: we still run other checks17:37
zygajdstrand: (for sure)17:37
zygaone thing we should do soon is to enable hard error checking on valgrind17:38
jdstrandimho, it is fine to not run check-syntax-sh on 16, since we are getting all the benefits from the versions of Ubuntu with the used shellcheck17:38
zygabut some of that is hard as there's plenty of false positives because we fork/exec and use glib for testing17:38
zygayes, I agree17:38
jdstrandit's kind of funny to implement a tool in a rather niche language to syntax check a ubiquitous language17:40
* jdstrand didn't realize it was haskell17:40
zygajdstrand: yeah, I read the implementation, it is really beautiful17:42
zygajdstrand: hey18:19
zygajdstrand: can you have a look at https://github.com/snapcore/snapd/pull/2837/files18:20
mupPR snapd#2837: interfaces/apparmor: allow reading from ecryptfs <Created by zyga> <https://github.com/snapcore/snapd/pull/2837>18:20
zygajdstrand: not a detailed review18:20
zygajdstrand: I'm still working on extra tests18:20
zygajdstrand: just tell me if that fits your idea18:20
jdstrandzyga: there was another conversation on that somewhere...18:23
jdstrandzyga: I'm not imagining that am I?18:23
jdstrandzyga: oh, heh, nm18:24
mupPR snapd#3273 closed: tests: wait for the docker socket to be listening <Created by fgimenez> <Merged by mvo5> <https://github.com/snapcore/snapd/pull/3273>18:24
jdstrandthe conversation was in that PR-- I was thinking this was a brand new PR :)18:24
zygajdstrand: :D18:29
zygajdstrand: it's my oldest PR ever18:29
zygajdstrand: there's one obvious nastiness there18:29
zygajdstrand: _any_ ecryptfs gives _any_ try mode snaps the extra snippet18:29
zygajdstrand: but we can remove that nastiness soon, chipaca said we should rework the state a little to store trymode flag in a per-revision thing18:30
zygajdstrand: and then we can also store the path18:30
zygajdstrand: (currently snapd just doesn't know)18:30
jdstrandI'm actually already commenting on that18:32
zygathank you!18:32
zygajdstrand: thanks!18:48
jdstrandnp18:49
=== JanC is now known as Guest75375
=== JanC_ is now known as JanC
slangasekzyga: you can't build-depend on snaps at all currently19:34
Chipacaogra_: you around?22:04
mupPR snapd#3268 closed: interfaces/browser-support: deny read on squashfs backing files and LVM vg names <Created by jdstrand> <Merged by jdstrand> <https://github.com/snapcore/snapd/pull/3268>22:11
Son_Gokuniemeyer: so I've made the vacation request22:50
Son_Gokufingers crossed!22:50

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