Re: Snap packages as build dependencies of other snaps

2017-04-08 Thread XiaoGuo Liu
can you do it by remote parts? you can find more info by:

$ snapcraft update
$ snapcraft search

There are a number of existing parts there already. You can publish your
own.

Best regards,
XiaoGuo


On Sun, Apr 9, 2017 at 12:51 AM, Joseph Rushton Wakeling <
joseph.wakel...@webdrake.net> wrote:

> Hello folks,
>
> Is it possible to specify an existing snap package (by track and release
> channel) as a build dependency of a part of another snap package?
>
> I'm interested specifically in the case of using an existing snap package
> to provide a compiler used to build another snap.  From what I understand
> from discussion around the go snapcraft plugin, there is some intention to
> allow this, but is it just for plugins?
>
> Thanks & best wishes,
>
> -- Joe
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
> an/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Issues creating webapps snaps with stric confinement

2017-04-04 Thread XiaoGuo Liu
Hi Winael,

Have you seen the tutorial at
https://tutorials.ubuntu.com/tutorial/snap-a-website#0?

Best regards,
XiaoGuo

On Fri, Mar 31, 2017 at 9:28 PM, Vincent JOBARD 
wrote:

> Hi Everyone
>
> I just try to follow the tutorial to learn how to create webapps snaps
> using snapcraft. (
> https://developer.ubuntu.com/en/phone/web/ubuntu-webapps-guide/, very nice
> tutorial by the way)
>
> Unfortunately, when I try to create my snap with strict confinement, I have
> a network Error page, but all works fine in devmode.
>
> I'm at work behind a proxy with cntlm authentification. could it be related
> ?
>
> Thx for your answers guys
>
> Cheers
> Winael
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: content interface, DENIED mounting $SNAP/mydir

2017-03-02 Thread XiaoGuo Liu
Can we use the configure hook to create the directory at installation?

On Fri, Mar 3, 2017 at 3:06 PM, Simon Fels  wrote:

> On 03.03.2017 01:06, Michi Henning wrote:
> >
> >> On 3 Mar 2017, at 4:33 , knitzsche  >> <mailto:kyle.nitzs...@canonical.com>> wrote:
> >>
> >> Hi,
> >>
> >> I am trying to use the wifi-ap content sharing interface.
> >>
> >> It is DENIED (see below) when I try to use a $SNAP directory.
> >>
> >> It works when I instead use $SNAP_DATA directory for the content
> >> sharing. But, I have to create that directory at run time: I can't
> >> figure out so far how to create (from snapcraft.yaml) an empty dir in
> >> $SNAP_COMMON or $SNAP_DATA at install time. (Knowing this would solve
> >> my problem.)
> >
> >
> > We do this to create a directory:
> >
> > install: |
> >   # Make sure we have a mount point for ubuntu-app-platform
> >   mkdir -p $SNAPCRAFT_PART_INSTALL/ubuntu-app-platform
>
> That doesn't help much here as we're bind-mounting read/write data and
> that seems to be not possible to go into somewhere below $SNAP.
>
> I fear the only answer to this problem are interface hooks which would
> allow us to create the relevant directory before the bind-mount happens
> inside $SNAP_DATA.
>
> regards,
> Simon
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Is there any way to choose the arch to build on build.snapcraft.io?

2017-03-02 Thread XiaoGuo Liu
Hi,

I just tried to use build.snapcraft.io to build my application. The build
was successful. However, the app was meant for amd64. After I chose my
repos, it built for armhf and amd64 at the same time. The both versions
were published. How can I choose the arch to publish?

Thanks & best regards,
XiaoGuo

-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: snapcraft 2.27 has been released

2017-02-28 Thread XiaoGuo Liu
Hi Roberto,

In that case, you can just run your own script in the command in stead of
directly launching your app. In your script, just do whatever thing there.

Best regards,
XiaoGuo

On Tue, Feb 28, 2017 at 9:51 PM, Roberto Mier Escandón  <
roberto.escan...@canonical.com> wrote:

> Hey guys,
>
> Couldn't we have environment property pointing also to a file script as
> in the case of scriptlets. In the case of needing to set a bunch of
> things before launching app I'd prefer having it in that way.
>
> Cheers.
>
> On 24/02/17 20:05, Kyle Fazzari wrote:
> >
> >
> > On 02/24/2017 10:49 AM, Claudio André wrote:
> >>
> >> 2017-02-17 10:49 GMT-02:00 Sergio Schvezov
> >> mailto:sergio.schve...@canonical.com>>:
> >>
> >> Hello snapcrafters!
> >>
> >> ## Setting up environment
> >>
> >> No more wrapper scripts just to setup on environment entry, this is
> >> now tied into an app entry in `apps`. Here's a quick example:
> >>
> >> ```yaml
> >> apps:
> >> vim:
> >> command: bin/vim
> >> environment:
> >> VIMRUNTIME: $SNAP/share/vim/vim80
> >> ```
> >>
> >>
> >> Hi, I tried to append to path (see below). It is not supported.
> >>
> >> ```yaml
> >> environment:
> >>   PATH: "$SNAP/usr/lib/jvm/default-java/bin:$PATH"
> >> ```
> >>
> >> I'm ok with it. But, in case this is not by design, I'm mailing you
> guys.
> >
> > I can verify this. To clarify, this builds and runs fine, but actually
> > results in the PATH including the string `$PATH` instead of expanding it.
> >
> > Can a snapd dev comment on this? Is that intended?
> >
> >
> >
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: HowTo: How to make a snap package for lolcat with snapcraft on Ubuntu

2017-02-26 Thread XiaoGuo Liu
Hi Simos,

Thanks! Nice work!

Thanks & best regards,
XiaoGuo

On Mon, Feb 27, 2017 at 3:14 PM, Simos Xenitellis <
simos.li...@googlemail.com> wrote:

> Hi All,
>
> I wrote a tutorial on how to make a snap for a CLI utility called "lolcat",
> https://blog.simos.info/how-to-make-a-snap-package-for-
> lolcat-with-snapcraft-on-ubuntu/
>
> I am trying a different style and I aim to show how to create a snap
> for four different implementations of lolcat (in Python, Go, Rust, and
> C).
> The tutorial aims to gently introduce a few more concepts and
> reinforce at the same time the basics of snap creation.
>
> I am looking for feedback and especially if there are any concepts
> that I should tackle in a better way.
>
> Cheers,
> Simos
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: snap connect myapp:camera out-of-the-box

2017-02-22 Thread XiaoGuo Liu
I have updated the bug report. Please check my answers.

Best regards,
XiaoGuo

On Tue, Feb 21, 2017 at 11:44 PM, Dev Dev  wrote:

> Hi,
>
> Anyone can give me more information (ETA, how it will works) about the
> connection to camera. Right now, I need to ask my users who installed
> myapp via the Software Center to open a terminal and run:
> sudo snap connect myapp:camera
>
> It needs to be automagically connected.
>
> I reported this issue here:
> https://bugs.launchpad.net/snapcraft/+bug/1609577
>
> Thanks
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Experimental Python interpreter snap

2017-02-19 Thread XiaoGuo Liu
Hi James,

Nice. This is a nice example showing how to reduce a python snap package.
A few days ago, I also made a small example to make use of the python3
coming with the core at:

https://github.com/liu-xiao-guo/httpstat

In the above example, I in fact do not package the python. It works.

Thanks & best regards,
XiaoGuo

On Mon, Feb 20, 2017 at 10:16 AM, James Henstridge <
james.henstri...@canonical.com> wrote:

> To learn a bit more about I put together a snap for Python 3.6.0,
> which can be installed with:
>
> snap install --edge python36-jamesh
>
> You can then run "python36-jamesh.python3", which will give you the a
> Python shell running with strict confinement, with the full standard
> library available.
>
> Now I know Snapcraft already has support for packaging Python
> applications, so what benefits does this package add?  There were a
> few extra points in how I built the package:
>
> 1. the interpreter binary and extension modules all have appropriate
> $ORIGIN relative rpath set.
>
> 2. a sitecustomize.py is provided that will add
> $SNAP/lib/python3.6/site-packages to sys.path. (more on why this is
> useful later)
>
> This makes the interpreter fully relocatable in the file system while
> still being able to find the bundled libraries.  In turn, this means
> the interpreter is functional when exported to another snap via the
> content interface.
>
> To demonstrate this, I put together a trivial "hello world" snapcraft
> project here:
>
> https://github.com/jhenstridge/python-snap-pkg/tree/master/examples/hello-
> world
>
> After building this package, it can be run after installing and
> connecting the interface:
>
> $ snap install --dangerous hello-world_0.1_amd64.snap
> hello-world 0.1 installed
> $ snap connect hello-world:python3 python36-jamesh:python3
> $ hello-world
> Hello world!
>
> Since the hello-world snap doesn't actually include Python, it is
> quite light weight (4 kB, which I think is as small as a squashfs
> gets).  The space savings may not be that great with a single snap
> (the interpreter snap is almost 20MB), but the space savings increase
> as you install more snaps using the interface.  It also means that we
> could upgrade to Python 3.6.1 (when it comes out) without rebuilding
> this snap.
>
> And since the interpreter is being run under the hello-world snap's
> confinement policy, it can do potentially do things the main
> "python36-jamesh.python3" binary can't.  For example, if you add the
> "network" plug, you'll be able to access the network.
>
> And the sitecustomize script will also mean the interpreter can locate
> packages shipped in the plug snap.
>
> I'd be interested in any suggestions or feedback about the snap.
>
> Thanks,
>
> James.
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: New stable "core" and "ubuntu-core" snaps released

2017-02-16 Thread XiaoGuo Liu
Thanks. May I know what is the "reload-command" for in the snap.yaml? How
to make use of it in the snapcraft.yaml?

Best regards,
XiaoGuo

On Thu, Feb 16, 2017 at 10:55 PM, Michael Vogt 
wrote:

> Hello,
>
> The Snappy team is happy to announce the promotion of snapd 2.22.2
> from the candidate channel to stable in both the "core" and
> "ubuntu-core" snaps. It will also be available via the regular apt
> update mechanism in Ubuntu 14.04, 16.04 and 16.10. Other distributions
> will follow on their own schedule.
>
> As a reminder 2.22.2 brings with it:
>
> - automatically transition ubuntu-core snaps to core
> - support for X-Ayatana-Desktop-Shortcuts in desktop files
> - improve retry handling on network errors further
> - support for disabling sshd from the core config
> - support new "reload-command" in snap.yaml
> - fix snap try with classic confinement
> - many more bugfixes
> - interface improvements:
>   - opengl, default, network-control, network-manager
>   - new interfaces:
> - unity8-download-manager, evolution, account-control,
>   core-support
>
> Due to the power of Ubuntu Core, your device will update and reboot
> automatically so there is nothing for you to do :)
>
> Please let us know if you notice any issues and enjoy the new release!
>
> Cheers,
>  Michael (on behalf of the snappy team)
>
>
> --
> Devices mailing list
> devi...@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.snapcraft.io/
> mailman/listinfo/devices
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Issue with ubuntu OS snap first time boot.

2017-02-15 Thread XiaoGuo Liu
It seems not the problem. My problem is that it cannot finish the last step
of console-conf after I type the email address. It awaits from the Ubuntu
Store, but finally, I received a timeout message.

On Wed, Feb 15, 2017 at 11:14 PM, knitzsche 
wrote:

> probably this bug: https://bugs.launchpad.net/ubu
> ntu/+source/linux-raspi2/+bug/1652270
>
>
> On 02/13/2017 11:04 PM, XiaoGuo Liu wrote:
>
>> Today, I had the same problem. I downloaded the Raspberry Pi3 image at:
>>
>> http://cdimage.ubuntu.com/ubuntu-core/16/stable/
>>
>> The date is: ubuntu-core-16-pi3.img.xz
>> <http://cdimage.ubuntu.com/ubuntu-core/16/stable/current/ubu
>> ntu-core-16-pi3.img.xz>2017-01-26
>> 20:29316M
>> 
>>
>> After I flashed it, I had the same issue as described in the above
>> email. Attached please find the captured picture.
>>
>> The old image in the Ubuntu Core could not boot, and it stopped at
>> "booting kernel". I thought it was an old image flashed long time ago. I
>> decided to take the new one.
>>
>> Thanks & best regards,
>> XiaoGuo
>>
>>
>>
>> On Tue, Jan 10, 2017 at 9:35 PM, Ajay Pandey > <mailto:ajay.pan...@einfochips.com>> wrote:
>>
>> Hi All,
>>
>> __ __
>>
>> We are facing issue with the Ubuntu OS snap first time boot
>> console-conf.
>>
>> __ __
>>
>> We have generated the id_rsa.pub key and put it in the launchpad.net
>> <http://launchpad.net> as well as the login.ubuntu.com
>> <http://login.ubuntu.com> profiles.
>>
>> __ __
>>
>> Please find below the error that we are getting:
>>
>> __ __
>>
>> /Profile setup
>>
>> Enter an email address from your account in the store.
>>
>>  Email address:   *x...@gmail.com
>> <mailto:x...@gmail.com>(example)*
>>
>> If you do not have an account, visit https://login.ubuntu.com
>> to create one.
>>
>>   Creating user
>> failed:
>> *error: while creating user: cannot communicate with server:
>> Post
>>   http://localhost/v2/create-user
>> <http://localhost/v2/create-user>: EOF*
>>
>>
>>Contacting
>> store...
>>
>>[ Done   ]
>>[ Cancel ]
>>
>>
>>
>>   40 %/
>>
>> 
>> 
>> *
>> eInfochips Business Disclaimer: This e-mail message and all
>> attachments transmitted with it are intended solely for the use of
>> the addressee and may contain legally privileged and confidential
>> information. If the reader of this message is not the intended
>> recipient, or an employee or agent responsible for delivering this
>> message to the intended recipient, you are hereby notified that any
>> dissemination, distribution, copying, or other use of this message
>> or its attachments is strictly prohibited. If you have received this
>> message in error, please notify the sender immediately by replying
>> to this message and please delete it from your computer. Any views
>> expressed in this message are those of the individual sender unless
>> otherwise stated. Company has taken enough precautions to prevent
>> the spread of viruses. However the company accepts no liability for
>> any damage caused by any virus transmitted by this email.
>> ************
>> 
>> *
>>
>>
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io <mailto:Snapcraft@lists.snapcraft.io>
>> Modify settings or unsubscribe at:
>> https://lists.ubuntu.com/mailman/listinfo/snapcraft
>> <https://lists.ubuntu.com/mailman/listinfo/snapcraft>
>>
>>
>>
>>
>> --
>> XiaoGuo, Liu
>>
>>
>>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
> an/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Currernt config hook implementation scales very badly

2017-02-14 Thread XiaoGuo Liu
Hi Ciao,

Thanks! I just upgraded it to edge channel, and now it works as expected.

liu-xiao-guo@localhost:~$ snap set core service.ssh.disable=true
liu-xiao-guo@localhost:~$  sudo snap set core service.ssh.disable=true
liu-xiao-guo@localhost:~$  snap set core service.ssh.disable=true
liu-xiao-guo@localhost:~$ snap set core service.ssh.disable=false
liu-xiao-guo@localhost:~$ snap interfaces |grep core
:core-support core

I think the problem could be that the stable channel does not support it.

Best regards,
XiaoGuo

On Tue, Feb 14, 2017 at 5:45 PM, Oliver Grawert  wrote:

> hi,
> Am Dienstag, den 14.02.2017, 10:53 +0800 schrieb XiaoGuo Liu:
> > Hi,
> >
> > Today, I just followed the instructions at:
> >
> > https://github.com/CanonicalLtd/ubuntu-core-docs/blob/master/en/refer
> > ence/core-configuration.md
> >
> > to disable ssh. However, I got the error like:
> >
> > liu-xiao-guo@localhost:~$ sudo snap set core service.ssh.disable=true
> > error: cannot perform the following tasks:
> > - Run configure hook of "core" snap
> > (/snap/core/1177/meta/hooks/configure: 62:
> > /snap/core/1177/meta/hooks/configure: systemctl: Permission denied)
> >
> > Is this a bug? It was tested on Raspberry Pi2 device, and my core
> > system info is like:
>
> hmm, works fine on my pi2 install ...
>
> ogra@localhost:~$ snap set core service.ssh.disable=true
> ogra@localhost:~$ snap set core service.ssh.disable=false
> ogra@localhost:~$
>
> line 62 calls: "systemctl disable ssh.service"
> do you get the same error if you call the above (with sudo) manually ?
>
> could your SD card be full or have errors (and thus be mounted
> readonly) ?
>
> also check if the core-support interface is properly connected (it
> should auto-connect, this would definitely be a bug):
>
> ogra@localhost:~$ snap interfaces |grep core
> :core-support core
> ogra@localhost:~$
>
> ciao
> oli
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Currernt config hook implementation scales very badly

2017-02-13 Thread XiaoGuo Liu
Hi,

Today, I just followed the instructions at:

https://github.com/CanonicalLtd/ubuntu-core-docs/blob/master/en/reference/core-configuration.md

to disable ssh. However, I got the error like:

liu-xiao-guo@localhost:~$ sudo snap set core service.ssh.disable=true
error: cannot perform the following tasks:
- Run configure hook of "core" snap (/snap/core/1177/meta/hooks/configure:
62: /snap/core/1177/meta/hooks/configure: systemctl: Permission denied)

Is this a bug? It was tested on Raspberry Pi2 device, and my core system
info is like:

liu-xiao-guo@localhost:~$ snap version
snap2.23~201702101018.git.979009c~ubuntu16.04.1
snapd   2.23~201702101018.git.979009c~ubuntu16.04.1
series  16

liu-xiao-guo@localhost:~$ snap info core
name:  core
summary:   "snapd runtime environment"
publisher: canonical
description: |
  The core runtime environment for snapd
type:core
tracking:edge
installed:   16.04.1 (1177) 68MB -
refreshed:   2017-02-13 04:42:55 + UTC
channels:
  stable:16.04.1 (893)  67MB -
  candidate: 16.04.1 (1083) 68MB -
  beta:  16.04.1 (1083) 68MB -
  edge:  16.04.1 (1177) 68MB -

Thanks & best regards,
xiaoguo

On Wed, Feb 1, 2017 at 6:31 PM, Oliver Grawert  wrote:

> hi,
>
> after we recently added a config hook [1] to the core snap it is now
> possible to disable ssh if you require [2] ...
>
> there is a long standing request to do the same for syslog for systems
> running from SD card, which is why i looked into trying to extend the
> existing configure script for this, which made me notice some issue...
>
> when you call "snap set core foo=bar", there is no indication at all
> for the script which variable changes a value, neither in the shell
> environment nor in the argument list.
>
> the only way to get your value is to call snapctl for every existing
> variable [3]. since you dont know what specific variable was requested
> to change the only way to reliably write it is to write *all* existing
> variables ...
>
> now, if you package something with a more complex config that you want
> completely handled via snap config this gets ugly very fast... imagine
> something like postfix with can potentially have 100s of config
> options. instead of atomically changing a single option you will
> regenerate the full config from scratch. this takes a lot longer,
> bringing the risk of a completely broken config in case of a power
> loss, beyond resulting an an awful config hook script with a large
> block of "snapctl get" calls at the top.
>
> can we extend the config hook implementation minimally so a "snap set
> core foo=bar" would at least have something like "SNAP_OPTION=foo" in
> the environment that the generating script or binary could read to
> avoid the unnecessary processing or would that break some design
> concept ?
>
> ciao
> oli
>
> [1] http://bazaar.launchpad.net/~snappy-dev/core-snap/trunk/view/head:/
> hooks/configure
> [2] https://github.com/CanonicalLtd/ubuntu-core-docs/blob/master/en/ref
> erence/core-configuration.md
> [3] https://github.com/snapcore/snapd/wiki/hooks
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Package too old for cleanbuild

2017-02-12 Thread XiaoGuo Liu
Will the new release address the issue at
https://bugs.launchpad.net/snapcraft/+bug/1662464? Currently, I am using
ogra's packageproxy, and it works perfectly.  I created a blog at
http://blog.csdn.net/ubuntutouch/article/details/54405477

However, nodejs is not a debian package. Instead, it downloads every time
after the project is cleaned and rebuilt. This is a really a bad developer
experience. Last time, when I had a hackathon event, it was almost
impossible for a developer to develop a nodejs at the site since the
download took years to get it finished due to the network limitation or
other reasons. Even now at home, sometimes it takes quite a while to
download the nodejs package. I need to try different combination of VPN. It
is really troublesome for me.

Best regards,
XiaoGuo

On Mon, Feb 13, 2017 at 10:44 AM, Michi Henning  wrote:

> >
> > While I don't disagree with the suggestions here, if I may suggest a
> > workaround:
> >
> > If you find yourself using cleanbuild a lot (it makes a new ephemeral
> > container, builds, then destroys the container), you might find some
> > workflow improvements by simply developing the snap in a container. You
> > can even bind-mount the source from the host, if you want. This is the
> > workflow I use personally. It allows for one to fully customize the apt
> > sources while also utilizing Snapcraft's built-in stage package cache*,
> > and it doesn't clutter the development environment on the host.
>
> Thanks Kyle!
>
> While this works, I don’t think it meets the pragmatic needs of the
> developer. It’s already complex enough to learn a new tool chain and figure
> out an effective edit/debug/test cycle. If I have to set up my own
> container for this, I end up adding yet more variables and possible sources
> of errors.
>
> We really need the tool to take care of this, otherwise everyone goes
> through the same pain (and mistakes) over and over. The big bottleneck here
> is the endless re-downloading of all the packages. If snapcraft could take
> care of this transparently and use a cache, things would proceed at a
> tolerable pace, without everyone having to re-invent their own wheel.
>
> Cheers,
>
> Michi.
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: start engine before client

2017-02-12 Thread XiaoGuo Liu
I think you can just make a script. Inside the script, launch the engine
first, then start the player client. You just need one app which launches
your created script.

Best regards,
xiaoguo

On Fri, Feb 10, 2017 at 9:08 PM, Vasilisc  wrote:

> The program "app1" is not mine. It consists of two parts.
>
> I create snapcraft.yaml
> 
> apps:
>  engine:
>   command: $SNAP/opt/app1/engine --start
>   plugs: [home, unity7, x11, pulseaudio, network, network-bind]
>
>  player:
>   command: $SNAP/opt/app1/player "$@"
>   plugs: [home, unity7, x11, pulseaudio, network, network-bind]
> 
>
> If to launch an engine (app1.engine) and then the client (app1.player),
> then everything works perfectly. How to make that start of the client
> automatically launched an engine?
>
> Sorry for my english.
> --
> Best regards,
> vasilisc
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
> an/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: 'organize' affects 'stage-packages'

2017-02-09 Thread XiaoGuo Liu
I think you may point a folder name there in the organize something like:

 organize:
  'usr/share/ubuntu-html5-ui-toolkit/': www/ubuntu-html5-ui-toolkit

Basically, the folder "usr/share/ubuntu-html5-ui-toolkit" will be moved to
directory "www/ubuntu-html5-ui-toolkit" in the snap.

Best regards,
xiaoguo

On Fri, Feb 10, 2017 at 12:47 PM, Ruddick Lawrence 
wrote:

> I just discovered that a part with:
>
> organize:
>   '*': opt/
> stage-packages:
> - some-great-package
>
> moves the contents of the stage-packages into opt in addition to the
> output of the plugin. Is this the intended behavior, and if so, is there a
> way to move only the plugin output into a subfolder?
>
> Thanks,
> Ruddick
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: snapd available in Trusty Tahr

2017-02-09 Thread XiaoGuo Liu
Hi Thomas,

Thanks. I have reported a bug at
https://bugs.launchpad.net/snapd/+bug/1663174

Best regards,
XiaoGuo

On Thu, Feb 9, 2017 at 5:11 PM, Thomas Voß 
wrote:

>
>
> On Thu, Feb 9, 2017 at 10:09 AM, XiaoGuo Liu 
> wrote:
>
>> Hi Jamie,
>>
>> For my case, right now, after I log out and login again (in fact, I
>> rebooted my machine). the /snap/bin path is still not added. Everything is
>> still the same. I cannot execute the "hello-word" snap app. I do not know
>> where I did wrongly.
>>
>>
> ​In this case, please file a bug against launchpad.net/snapd, and tag it
> with trusty. /snap/bin should be in your PATH after a reboot.
>
> Thanks,
>
>   Thomas​
>
>
>
>> Thanks & bestt regards,
>> XiaoGuo
>>
>> On Thu, Feb 9, 2017 at 5:05 PM, Jamie Bennett <
>> jamie.benn...@canonical.com> wrote:
>>
>>> The simplest way is to log out and back in again. We are looking at
>>> other options on how to make this easier.
>>>
>>> Regards,
>>> Jamie.
>>>
>>> On 9 Feb 2017, at 09:02, XiaoGuo Liu  wrote:
>>>
>>> Hi Thomas,
>>>
>>> So, an end user needs to manually add the path, right? It is not a
>>> little bit straightforward though. I think it would be good to come with
>>> detailed instructions.
>>>
>>> Thanks & best regards,
>>> XiaoGuo
>>>
>>>
>>> On Thu, Feb 9, 2017 at 4:39 PM, Thomas Voß 
>>> wrote:
>>>
>>>>
>>>>
>>>> On Thu, Feb 9, 2017 at 5:02 AM, XiaoGuo Liu 
>>>> wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> I just tried to install the snapd and installed a hello-world snap app
>>>>> on 14.04 desktop. However, I found a problem. When I un the hello-world, 
>>>>> it
>>>>> shows:
>>>>>
>>>>> liuxg@liuxg:/snap/bin$ hello-world
>>>>> hello-world: command not found
>>>>>
>>>>>
>>>> This is expected behavior right now. PATH is adjusted in
>>>> /etc/profile.d/apps-bin-path.sh (comes with the snapd package).
>>>> /etc/profile and the entries in /etc/profile.d/* are only considered for
>>>> login shells. With that, a reboot, logout/login, or sourcing /etc/profile
>>>> in your current shell will give you the correct PATH setup.
>>>>
>>>> We are looking into letting the user know when installing the debian
>>>> package (as opposed to the situation where snapd is already part of the
>>>> image). See https://github.com/snapcore/snapd/pull/2819 for reference.
>>>>
>>>> Thanks for testing,
>>>>
>>>>   Thomas
>>>>
>>>>
>>>>
>>>>> Which means that /snap/bin path is not added to the path after
>>>>> installing the core. Also, when I run it under the /snap/bin, it shows:
>>>>>
>>>>> liuxg@liuxg:/snap/bin$ ./hello-world
>>>>> ERROR: ld.so: object '/lib/$LIB/liblsp.so' from /etc/ld.so.preload
>>>>> cannot be preloaded (cannot open shared object file): ignored.
>>>>> ERROR: ld.so: object '/lib/$LIB/liblsp.so' from /etc/ld.so.preload
>>>>> cannot be preloaded (cannot open shared object file): ignored.
>>>>> Hello World!
>>>>>
>>>>> My desktop info is:
>>>>>
>>>>> liuxg@liuxg:~$ lsb_release -a
>>>>> No LSB modules are available.
>>>>> Distributor ID: Ubuntu
>>>>> Description: Ubuntu 14.04.5 LTS
>>>>> Release: 14.04
>>>>> Codename: trusty
>>>>>
>>>>> liuxg@liuxg:~$ snap list
>>>>> Name Version  Rev  Developer  Notes
>>>>> core 16.04.1  888  canonical  -
>>>>> hello-world  6.3  27   canonical  -
>>>>>
>>>>> Thanks & best regards,
>>>>> XiaoGuo
>>>>>
>>>>>
>>>>> On Wed, Feb 8, 2017 at 5:35 AM, Andrew Mason <
>>>>> and...@miniatureworldmaker.com.au> wrote:
>>>>>
>>>>>> Awesome, i am going to give this a try!
>>>>>>
>>>>>> On 8 February 2017 8:01:30 am ACDT, Manik Taneja 
>>>>>> wrote:
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Tue, Feb 7, 2017 a

Re: snapd available in Trusty Tahr

2017-02-09 Thread XiaoGuo Liu
Hi Jamie,

For my case, right now, after I log out and login again (in fact, I
rebooted my machine). the /snap/bin path is still not added. Everything is
still the same. I cannot execute the "hello-word" snap app. I do not know
where I did wrongly.

Thanks & bestt regards,
XiaoGuo

On Thu, Feb 9, 2017 at 5:05 PM, Jamie Bennett 
wrote:

> The simplest way is to log out and back in again. We are looking at other
> options on how to make this easier.
>
> Regards,
> Jamie.
>
> On 9 Feb 2017, at 09:02, XiaoGuo Liu  wrote:
>
> Hi Thomas,
>
> So, an end user needs to manually add the path, right? It is not a little
> bit straightforward though. I think it would be good to come with detailed
> instructions.
>
> Thanks & best regards,
> XiaoGuo
>
>
> On Thu, Feb 9, 2017 at 4:39 PM, Thomas Voß 
> wrote:
>
>>
>>
>> On Thu, Feb 9, 2017 at 5:02 AM, XiaoGuo Liu 
>> wrote:
>>
>>> Hi,
>>>
>>> I just tried to install the snapd and installed a hello-world snap app
>>> on 14.04 desktop. However, I found a problem. When I un the hello-world, it
>>> shows:
>>>
>>> liuxg@liuxg:/snap/bin$ hello-world
>>> hello-world: command not found
>>>
>>>
>> This is expected behavior right now. PATH is adjusted in
>> /etc/profile.d/apps-bin-path.sh (comes with the snapd package).
>> /etc/profile and the entries in /etc/profile.d/* are only considered for
>> login shells. With that, a reboot, logout/login, or sourcing /etc/profile
>> in your current shell will give you the correct PATH setup.
>>
>> We are looking into letting the user know when installing the debian
>> package (as opposed to the situation where snapd is already part of the
>> image). See https://github.com/snapcore/snapd/pull/2819 for reference.
>>
>> Thanks for testing,
>>
>>   Thomas
>>
>>
>>
>>> Which means that /snap/bin path is not added to the path after
>>> installing the core. Also, when I run it under the /snap/bin, it shows:
>>>
>>> liuxg@liuxg:/snap/bin$ ./hello-world
>>> ERROR: ld.so: object '/lib/$LIB/liblsp.so' from /etc/ld.so.preload
>>> cannot be preloaded (cannot open shared object file): ignored.
>>> ERROR: ld.so: object '/lib/$LIB/liblsp.so' from /etc/ld.so.preload
>>> cannot be preloaded (cannot open shared object file): ignored.
>>> Hello World!
>>>
>>> My desktop info is:
>>>
>>> liuxg@liuxg:~$ lsb_release -a
>>> No LSB modules are available.
>>> Distributor ID: Ubuntu
>>> Description: Ubuntu 14.04.5 LTS
>>> Release: 14.04
>>> Codename: trusty
>>>
>>> liuxg@liuxg:~$ snap list
>>> Name Version  Rev  Developer  Notes
>>> core 16.04.1  888  canonical  -
>>> hello-world  6.3  27   canonical  -
>>>
>>> Thanks & best regards,
>>> XiaoGuo
>>>
>>>
>>> On Wed, Feb 8, 2017 at 5:35 AM, Andrew Mason <
>>> and...@miniatureworldmaker.com.au> wrote:
>>>
>>>> Awesome, i am going to give this a try!
>>>>
>>>> On 8 February 2017 8:01:30 am ACDT, Manik Taneja 
>>>> wrote:
>>>>>
>>>>>
>>>>>
>>>>> On Tue, Feb 7, 2017 at 12:36 PM, Mark Shuttleworth 
>>>>> wrote:
>>>>>
>>>>>> On 07/02/17 20:17, Thomas Voß wrote:
>>>>>> > https://bugs.launchpad.net/ubuntu/+source/xorg-server-lts-xe
>>>>>> nial/+bug/1655724
>>>>>> > was released to the updates pocket today.
>>>>>>
>>>>>> Congrats! Quick feedback from folks with Trusty (14.04 LTS) systems,
>>>>>> cloud or desktop, would be welcome. Pick a favorite snap and take it
>>>>>> for
>>>>>> a spin.
>>>>>>
>>>>> The experience is very clean now. I just tried on AWS and have
>>>>> RocketChat up and
>>>>> running-
>>>>>
>>>>> [image: Inline image 1]
>>>>> Kudos to everyone involved in delivering this!
>>>>>
>>>>> Cheers,
>>>>> Manik
>>>>>
>>>>
>>>> --
>>>> Sent from my mobile device.
>>>>
>>>> --
>>>> Snapcraft mailing list
>>>> Snapcraft@lists.snapcraft.io
>>>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>>>> an/listinfo/snapcraft
>>>>
>>>>
>>>
>>>
>>> --
>>> XiaoGuo, Liu
>>>
>>> --
>>> Snapcraft mailing list
>>> Snapcraft@lists.snapcraft.io
>>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>>> an/listinfo/snapcraft
>>>
>>>
>>
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>> an/listinfo/snapcraft
>>
>>
>
>
> --
> XiaoGuo, Liu
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: snapd available in Trusty Tahr

2017-02-09 Thread XiaoGuo Liu
Hi Thomas,

So, an end user needs to manually add the path, right? It is not a little
bit straightforward though. I think it would be good to come with detailed
instructions.

Thanks & best regards,
XiaoGuo


On Thu, Feb 9, 2017 at 4:39 PM, Thomas Voß 
wrote:

>
>
> On Thu, Feb 9, 2017 at 5:02 AM, XiaoGuo Liu 
> wrote:
>
>> Hi,
>>
>> I just tried to install the snapd and installed a hello-world snap app on
>> 14.04 desktop. However, I found a problem. When I un the hello-world, it
>> shows:
>>
>> liuxg@liuxg:/snap/bin$ hello-world
>> hello-world: command not found
>>
>>
> This is expected behavior right now. PATH is adjusted in
> /etc/profile.d/apps-bin-path.sh (comes with the snapd package).
> /etc/profile and the entries in /etc/profile.d/* are only considered for
> login shells. With that, a reboot, logout/login, or sourcing /etc/profile
> in your current shell will give you the correct PATH setup.
>
> We are looking into letting the user know when installing the debian
> package (as opposed to the situation where snapd is already part of the
> image). See https://github.com/snapcore/snapd/pull/2819 for reference.
>
> Thanks for testing,
>
>   Thomas
>
>
>
>> Which means that /snap/bin path is not added to the path after installing
>> the core. Also, when I run it under the /snap/bin, it shows:
>>
>> liuxg@liuxg:/snap/bin$ ./hello-world
>> ERROR: ld.so: object '/lib/$LIB/liblsp.so' from /etc/ld.so.preload cannot
>> be preloaded (cannot open shared object file): ignored.
>> ERROR: ld.so: object '/lib/$LIB/liblsp.so' from /etc/ld.so.preload cannot
>> be preloaded (cannot open shared object file): ignored.
>> Hello World!
>>
>> My desktop info is:
>>
>> liuxg@liuxg:~$ lsb_release -a
>> No LSB modules are available.
>> Distributor ID: Ubuntu
>> Description: Ubuntu 14.04.5 LTS
>> Release: 14.04
>> Codename: trusty
>>
>> liuxg@liuxg:~$ snap list
>> Name Version  Rev  Developer  Notes
>> core 16.04.1  888  canonical  -
>> hello-world  6.3  27   canonical  -
>>
>> Thanks & best regards,
>> XiaoGuo
>>
>>
>> On Wed, Feb 8, 2017 at 5:35 AM, Andrew Mason <
>> and...@miniatureworldmaker.com.au> wrote:
>>
>>> Awesome, i am going to give this a try!
>>>
>>> On 8 February 2017 8:01:30 am ACDT, Manik Taneja 
>>> wrote:
>>>>
>>>>
>>>>
>>>> On Tue, Feb 7, 2017 at 12:36 PM, Mark Shuttleworth 
>>>> wrote:
>>>>
>>>>> On 07/02/17 20:17, Thomas Voß wrote:
>>>>> > https://bugs.launchpad.net/ubuntu/+source/xorg-server-lts-xe
>>>>> nial/+bug/1655724
>>>>> > was released to the updates pocket today.
>>>>>
>>>>> Congrats! Quick feedback from folks with Trusty (14.04 LTS) systems,
>>>>> cloud or desktop, would be welcome. Pick a favorite snap and take it
>>>>> for
>>>>> a spin.
>>>>>
>>>> The experience is very clean now. I just tried on AWS and have
>>>> RocketChat up and
>>>> running-
>>>>
>>>> [image: Inline image 1]
>>>> Kudos to everyone involved in delivering this!
>>>>
>>>> Cheers,
>>>> Manik
>>>>
>>>
>>> --
>>> Sent from my mobile device.
>>>
>>> --
>>> Snapcraft mailing list
>>> Snapcraft@lists.snapcraft.io
>>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>>> an/listinfo/snapcraft
>>>
>>>
>>
>>
>> --
>> XiaoGuo, Liu
>>
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>> an/listinfo/snapcraft
>>
>>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: ubuntu-app-platform updated to Qt 5.6.2

2017-02-08 Thread XiaoGuo Liu
Hi James,

Thanks for your help. Yes, you are right! Now I do a new version of it, and
I used a wrapper to launch it. This time, the app can be launched
successfully, but still there is an error like:

** (process:29208): WARNING **: Unable to register app:
GDBus.Error:org.freedesktop.DBus.Error.AccessDenied: An AppArmor policy
prevents this sender from sending this message to this recipient;
type="method_call", sender=":1.467" (uid=1000 pid=29208
comm="webapp-container www/index.html ") interface="com.canonical.hud"
member="RegisterApplication" error name="(unset)" requested_reply="0"
destination=":1.36" (uid=1000 pid=2741
comm="/usr/lib/x86_64-linux-gnu/hud/hud-service ")
XmbTextListToTextProperty result code -2
XmbTextListToTextProperty result code -2
qml: [JS] (file:///snap/wuziqi/x1/www/js/app.js:1) Uncaught ReferenceError:
UbuntuUI is not defined

My code is at https://github.com/liu-xiao-guo/wuziqi1

I think it is another error.

Thanks & best regards,
XiaoGuo


On Thu, Feb 9, 2017 at 2:26 PM, James Henstridge <
james.henstri...@canonical.com> wrote:

> On 9 February 2017 at 12:12, XiaoGuo Liu 
> wrote:
> > Hi James,
> >
> > Thanks for your reply. Yeah, it could be reason for it. I used to have a
> Qt
> > project, and the app was launched by desktop-launch:
> >
> > https://github.com/liu-xiao-guo/rssreader_platform
> >
> > For my case, it is a html5 app. I do not know what is the correct way to
> > launch the app. Do you know what should be set up correctly? I may have
> my
> > own script to set them up.
>
> The webapp-helper part you're using looks like it provides a
> bin/webapp-launcher helper script that would do what you want.  It
> looks like it might be what you're after.
>
> James.
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: ubuntu-app-platform updated to Qt 5.6.2

2017-02-08 Thread XiaoGuo Liu
Hi James,

Thanks for your reply. Yeah, it could be reason for it. I used to have a Qt
project, and the app was launched by desktop-launch:

https://github.com/liu-xiao-guo/rssreader_platform

For my case, it is a html5 app. I do not know what is the correct way to
launch the app. Do you know what should be set up correctly? I may have my
own script to set them up.

Thanks & best regards,
XiaoGuo

On Thu, Feb 9, 2017 at 12:02 PM, James Henstridge <
james.henstri...@canonical.com> wrote:

> On 9 February 2017 at 10:43, XiaoGuo Liu 
> wrote:
> > I am now trying to snap a html5 webapp. My source code is here at:
> >
> > https://github.com/liu-xiao-guo/wuziqi
>
> Looking at the snapcraft.yaml file, you don't seem to be using the
> launcher shell script provided by the part.  Without that,
> LD_LIBRARY_PATH and other environment variables won't be set up
> correctly to use libraries provided by ubuntu-app-platform.
>
> James.
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: snapd available in Trusty Tahr

2017-02-08 Thread XiaoGuo Liu
Hi,

I just tried to install the snapd and installed a hello-world snap app on
14.04 desktop. However, I found a problem. When I un the hello-world, it
shows:

liuxg@liuxg:/snap/bin$ hello-world
hello-world: command not found

Which means that /snap/bin path is not added to the path after installing
the core. Also, when I run it under the /snap/bin, it shows:

liuxg@liuxg:/snap/bin$ ./hello-world
ERROR: ld.so: object '/lib/$LIB/liblsp.so' from /etc/ld.so.preload cannot
be preloaded (cannot open shared object file): ignored.
ERROR: ld.so: object '/lib/$LIB/liblsp.so' from /etc/ld.so.preload cannot
be preloaded (cannot open shared object file): ignored.
Hello World!

My desktop info is:

liuxg@liuxg:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 14.04.5 LTS
Release: 14.04
Codename: trusty

liuxg@liuxg:~$ snap list
Name Version  Rev  Developer  Notes
core 16.04.1  888  canonical  -
hello-world  6.3  27   canonical  -

Thanks & best regards,
XiaoGuo


On Wed, Feb 8, 2017 at 5:35 AM, Andrew Mason <
and...@miniatureworldmaker.com.au> wrote:

> Awesome, i am going to give this a try!
>
> On 8 February 2017 8:01:30 am ACDT, Manik Taneja 
> wrote:
>>
>>
>>
>> On Tue, Feb 7, 2017 at 12:36 PM, Mark Shuttleworth 
>> wrote:
>>
>>> On 07/02/17 20:17, Thomas Voß wrote:
>>> > https://bugs.launchpad.net/ubuntu/+source/xorg-server-lts-
>>> xenial/+bug/1655724
>>> > was released to the updates pocket today.
>>>
>>> Congrats! Quick feedback from folks with Trusty (14.04 LTS) systems,
>>> cloud or desktop, would be welcome. Pick a favorite snap and take it for
>>> a spin.
>>>
>> The experience is very clean now. I just tried on AWS and have RocketChat
>> up and
>> running-
>>
>> [image: Inline image 1]
>> Kudos to everyone involved in delivering this!
>>
>> Cheers,
>> Manik
>>
>
> --
> Sent from my mobile device.
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: ubuntu-app-platform updated to Qt 5.6.2

2017-02-08 Thread XiaoGuo Liu
I am now trying to snap a html5 webapp. My source code is here at:

https://github.com/liu-xiao-guo/wuziqi

Currently, my Qt version on my desktop is Qt 5.6.2:

QMake version 3.0
Using Qt version 5.6.2 in /usr/lib/x86_64-linux-gnu


I installed ubuntu-app-platform from the edge channel.

$ snap info ubuntu-app-platform
name:  ubuntu-app-platform
summary:   "Ubuntu app platform for running apps on a shared platform of
libraries"
publisher: canonical
description: |
  Ubuntu app platform is an optional package your app can use to minimize
the
  disk space the app takes. The platform offers you shared content which
  includes Qt 5.6.2 with Ubuntu's backported fixes, Ubuntu UI Toolkit, PIM
  libraries and Oxide web browser engine among else.

  It is recommended to use the associated cloud part
desktop-ubuntu-app-platform
  to make the usage easy. Note that for developing a package targeting to
use
  ubuntu-app-platform, you will need to use Ubuntu 16.04 LTS added with the
  "stable-phone-overlay" PPA which includes the newer Qt and other packages!
tracking:edge
installed:   1 (34) 216MB -
refreshed:   2017-02-08 21:34:47 +0800 CST
channels:
  stable:1 (22) 154MB -
  candidate: 1 (34) 216MB -
  beta:  1 (34) 216MB -
  edge:  1 (34) 216MB -

When running my app, it comes the error like:

===
$ wuziqi
This application failed to start because it could not find or load the Qt
platform plugin "xcb"
in "".

Reinstalling the application may fix this problem.
Aborted (core dumped)


What could be the reason for it?

Thanks & best regards,
XiaoGuo


On Thu, Feb 9, 2017 at 10:28 AM, XiaoGuo Liu 
wrote:

> These days, I tried to make use of ubuntu-app-platform. I have upgraded
> the snap to the latest version 34 from the edge channel. Still I get an
> error like:
>
> This application failed to start because it could not find or load the Qt
> platform plugin "xcb"
> in "".
>
> Reinstalling the application may fix this problem.
> Aborted (core dumped)
>
> What could be the problem for it?
>
> Thanks & best regards,
> XiaoGuo
>
> On Wed, Feb 8, 2017 at 11:54 PM, Florian Boucault <
> florian.bouca...@canonical.com> wrote:
>
>> Indeed, sorry about that. The latest version with no Qt bundled is
>> released now.
>>
>> Florian
>>
>> Le mer. 8 févr. 2017 à 14:20, Timo Jyrinki  a
>> écrit :
>>
>>> 2017-02-07 17:00 GMT+02:00 Florian Boucault <
>>> florian.bouca...@canonical.com>:
>>> > I thought I fixed the terminal last week. At least the terminal
>>> available on
>>> > the edge channel now is working for me. Does it work for you?
>>> > I made sure that the stage-packages only contain packages that are not
>>> in
>>> > ubuntu-app-platform and also used  build-attributes:
>>> [no-system-libraries]
>>>
>>> It does not work if I upgrade to the edge version of
>>> ubuntu-app-platform (and uninstall and reinstall ubuntu-terminal-app).
>>>
>>> So yes you fixed it, and I tested the fix but the fixed version needs
>>> to be uploaded to the store by someone with rights. Maybe Bill?
>>>
>>> The current 33 version in the store still has the bundled Qt libraries
>>> - see $ ls /snap/ubuntu-terminal-app/33/usr/lib/x86_64-linux-gnu/
>>>
>>> -Timo
>>>
>>> --
>>> Snapcraft mailing list
>>> Snapcraft@lists.snapcraft.io
>>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>>> an/listinfo/snapcraft
>>>
>>
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>> an/listinfo/snapcraft
>>
>>
>
>
> --
> XiaoGuo, Liu
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: ubuntu-app-platform updated to Qt 5.6.2

2017-02-08 Thread XiaoGuo Liu
These days, I tried to make use of ubuntu-app-platform. I have upgraded the
snap to the latest version 34 from the edge channel. Still I get an error
like:

This application failed to start because it could not find or load the Qt
platform plugin "xcb"
in "".

Reinstalling the application may fix this problem.
Aborted (core dumped)

What could be the problem for it?

Thanks & best regards,
XiaoGuo

On Wed, Feb 8, 2017 at 11:54 PM, Florian Boucault <
florian.bouca...@canonical.com> wrote:

> Indeed, sorry about that. The latest version with no Qt bundled is
> released now.
>
> Florian
>
> Le mer. 8 févr. 2017 à 14:20, Timo Jyrinki  a
> écrit :
>
>> 2017-02-07 17:00 GMT+02:00 Florian Boucault > com>:
>> > I thought I fixed the terminal last week. At least the terminal
>> available on
>> > the edge channel now is working for me. Does it work for you?
>> > I made sure that the stage-packages only contain packages that are not
>> in
>> > ubuntu-app-platform and also used  build-attributes:
>> [no-system-libraries]
>>
>> It does not work if I upgrade to the edge version of
>> ubuntu-app-platform (and uninstall and reinstall ubuntu-terminal-app).
>>
>> So yes you fixed it, and I tested the fix but the fixed version needs
>> to be uploaded to the store by someone with rights. Maybe Bill?
>>
>> The current 33 version in the store still has the bundled Qt libraries
>> - see $ ls /snap/ubuntu-terminal-app/33/usr/lib/x86_64-linux-gnu/
>>
>> -Timo
>>
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.ubuntu.com/
>> mailman/listinfo/snapcraft
>>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Is there any way to list all of the configure options for a snap application?

2017-02-07 Thread XiaoGuo Liu
Yeah, I think this is much needed. For example, I really want to know what
are the configuration options for the core snap. One use case could be that
I want to stop the autopilot upgrade feature..

Thanks & best regards,
XiaoGuo

On Wed, Feb 8, 2017 at 2:20 PM, Manik Taneja 
wrote:

>
>
> On Feb 7, 2017, at 10:14 PM, XiaoGuo Liu 
> wrote:
>
> Hi,
>
> According to the article at https://github.com/snapcore/snapd/blob/master/
> tests/lib/snaps/snapctl-hooks/meta/hooks/configure, we can configure a
> snap using "snap  get/set" command. Is there any way to list all of the
> configuration options for a snap app so that an end user can fine-tune the
> app.
>
> No, this is in the roadmap but not implemented yet!
>
>
> Thanks & best regards,
> XiaoGuo
>
> --
> XiaoGuo, Liu
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Is there any way to list all of the configure options for a snap application?

2017-02-07 Thread XiaoGuo Liu
Hi,

According to the article at
https://github.com/snapcore/snapd/blob/master/tests/lib/snaps/snapctl-hooks/meta/hooks/configure,
we can configure a snap using "snap  get/set" command. Is there any way to
list all of the configuration options for a snap app so that an end user
can fine-tune the app.

Thanks & best regards,
XiaoGuo

-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Where to save stuff (in snap-agnostic way)

2017-02-07 Thread XiaoGuo Liu
Hi Jamie,

Thanks for your explanation. You are right. The directory name takes the
very first execution of the command. After that, when accessing the /tmp
directory, it uses the directory created earlier if it is running from
another command.

I have updated my example code at
https://github.com/liu-xiao-guo/helloworld-fifo

When I firstly run "hello.fifo", the directory name takes something
"like snap.1000_snap.hello.fifo_5BpMiB". When trying to write to it using
"hello.fifo1", the same directory is used.

When I firstly run "hello.fifo1", the directory name takes something
"snap.1000_snap.hello.fifo1_6MJX5m". When trying to write to it using
"hello.fifo", the same directory is used.

Thanks & best regards,
XiaoGuo


On Wed, Feb 8, 2017 at 12:21 AM, Jamie Strandboge 
wrote:

> On Tue, 2017-02-07 at 12:04 +0800, XiaoGuo Liu wrote:
> > Hi Jamie,
> >
> > For my sample app at https://github.com/liu-xiao-guo/helloworld-fifo, I
> > tried to use the /tmp file to create a file, and  finally I get a file on
> > my Desktop like:
> >
> > root@liuxg:/tmp/snap.1000_snap.hello.fifo_TovLTW/tmp# ls
> > anothefile
> >
> > It seems to me that the path is still related to the command name "fifo".
> > Does this conflict with your saying?
>
> It does not. That directory is what is bind mounted into mount namespace
> and
> that is remembered for subsequent invocations of that command or other
> commands
> from the same snap. Try it: create a snap with two commands, have one
> create a
> file in /tmp and another to read the same file in /tmp-- it will work and
> the
> temporary directory in the system's /tmp will be
> /tmp/snap.0_snap.$SNAP_NAME._... will have the
> file you
> created in it.
>
> --
> Jamie Strandboge     | http://www.canonical.com
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Where to save stuff (in snap-agnostic way)

2017-02-06 Thread XiaoGuo Liu
Hi Jamie,

For my sample app at https://github.com/liu-xiao-guo/helloworld-fifo, I
tried to use the /tmp file to create a file, and  finally I get a file on
my Desktop like:

root@liuxg:/tmp/snap.1000_snap.hello.fifo_TovLTW/tmp# ls
anothefile

It seems to me that the path is still related to the command name "fifo".
Does this conflict with your saying?

Currently, my snapd version on 16.04 desktop is:

liuxg@liuxg:~$ snap version
snap2.22.1
snapd   2.22.1
series  16
ubuntu  16.04

Thanks & best regards,
XiaoGuo



On Tue, Feb 7, 2017 at 1:21 AM, Jamie Strandboge 
wrote:

> On Sun, 2017-02-05 at 08:04 +0800, XiaoGuo Liu wrote:
> > Hi Oli,
> >
> > Does it mean all of the snaps have the same /tmp or each snap has its own
> > /tmp? I am a little bit confused about this.
> >
>
> You might be confused because the behavior changed. For a long time, each
> snap
> *command* had its own /tmp directory. That was changed late last year so
> that
> all commands with the same snap share the same /tmp directory such that
> each
> snap has its own /tmp directory.
>
> --
> Jamie Strandboge | http://www.canonical.com
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: HowTo: How to create a snap for a Python app with networking using snapcraft in Ubuntu 16.04

2017-02-06 Thread XiaoGuo Liu
Hi Simos,

Thanks! It is really nice to see the tutorial, and it is very detailed.

Best regards,
XiaoGuo

On Mon, Feb 6, 2017 at 5:56 PM, Simos Xenitellis  wrote:

> Hi All,
>
> I wrote an article about creating a snap for an existing Python
> program using the new snapcraft 2.26. Then, I uploaded to the Ubuntu
> Store.
>
> I am looking forward to receiving feedback :-)
>
> Link: https://blog.simos.info/how-to-create-a-snap-for-a-python-
> app-with-networking-using-snapcraft-in-ubuntu-16-04/
>
> Link to HN submission: https://news.ycombinator.com/item?id=13578034
>
> Simos
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Snap icon in the Ubuntu Store

2017-02-06 Thread XiaoGuo Liu
Hi Kyle,

Thanks for your reply. I cannot remember it exactly whether I set an icon
for it or not. But this is definitely a confusing part.

I think snapweb may have a bug for it since I change another picture in my
package, but it is not reflected at all after the new installation.

Best regards,
XiaoGuo

On Mon, Feb 6, 2017 at 1:42 PM, Kyle Fazzari 
wrote:

> Any chance the snap in question has an icon set store side? I believe the
> one in the store takes precedence over the one in the snap itself.
>
> Kyle
>
> On Feb 5, 2017 4:47 PM, "XiaoGuo Liu"  wrote:
>
>> I just found another problem with snapweb. If I change the icon to
>> another picture in the snapcraft.yaml file, after new installation, the
>> package icon in the snapweb is not updated, and the old one is still used.
>> Is this a bug?
>>
>> Thanks & best regards,
>> XiaoGuo
>>
>> On Mon, Feb 6, 2017 at 8:15 AM, XiaoGuo Liu 
>> wrote:
>>
>>> Hi,
>>>
>>> I am a little confused about the snap icon in the store. According to
>>> the document at:
>>>
>>> https://snapcraft.io/docs/build-snaps/metadata
>>>
>>> A package icon is defined by the "icon" field in the snapcraft.yaml.
>>> However, my own project at:
>>>
>>> https://github.com/liu-xiao-guo/ss-qt
>>>
>>> does not have the "icon" field, and it can be found at:
>>>
>>> https://uappexplorer.com/app/ss-qt.xiaoguo
>>>
>>> However, after installation on my desktop, in the snapweb, it does show
>>> an snap icon for it. Why is it like this? For some of the apps, if I do not
>>> have the icon field defined, it does not show the snap icon in the snapweb
>>> at all.
>>>
>>> Attached please find the picture for it.
>>>
>>> Thanks & best regards,
>>> XiaoGuo
>>>
>>>
>>> --
>>> XiaoGuo, Liu
>>>
>>
>>
>>
>> --
>> XiaoGuo, Liu
>>
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>> an/listinfo/snapcraft
>>
>>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Snap icon in the Ubuntu Store

2017-02-05 Thread XiaoGuo Liu
I just found another problem with snapweb. If I change the icon to another
picture in the snapcraft.yaml file, after new installation, the package
icon in the snapweb is not updated, and the old one is still used. Is this
a bug?

Thanks & best regards,
XiaoGuo

On Mon, Feb 6, 2017 at 8:15 AM, XiaoGuo Liu 
wrote:

> Hi,
>
> I am a little confused about the snap icon in the store. According to the
> document at:
>
> https://snapcraft.io/docs/build-snaps/metadata
>
> A package icon is defined by the "icon" field in the snapcraft.yaml.
> However, my own project at:
>
> https://github.com/liu-xiao-guo/ss-qt
>
> does not have the "icon" field, and it can be found at:
>
> https://uappexplorer.com/app/ss-qt.xiaoguo
>
> However, after installation on my desktop, in the snapweb, it does show an
> snap icon for it. Why is it like this? For some of the apps, if I do not
> have the icon field defined, it does not show the snap icon in the snapweb
> at all.
>
> Attached please find the picture for it.
>
> Thanks & best regards,
> XiaoGuo
>
>
> --
> XiaoGuo, Liu
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Where to save stuff (in snap-agnostic way)

2017-02-04 Thread XiaoGuo Liu
Sorry,

I just found that each snap has its own "tmp" directory created in the /tmp
directory of the system. I just created a file, and it looks like:

root@liuxg:/tmp/snap.1000_snap.hello.fifo_TovLTW/tmp# ls
anothefile

Thanks & best regards,
XiaoGuo

On Sun, Feb 5, 2017 at 8:04 AM, XiaoGuo Liu 
wrote:

> Hi Oli,
>
> Does it mean all of the snaps have the same /tmp or each snap has its own
> /tmp? I am a little bit confused about this.
>
> Thanks & best regards,
> XiaoGuo
>
>
>
> On Sat, Feb 4, 2017 at 6:43 PM, Oliver Grawert  wrote:
>
>> hi,
>> Am Freitag, den 03.02.2017, 21:04 +0100 schrieb Luca Dionisi:
>> > What is the best place to write (and read) a temporary FIFO file from
>> > a confined snap application?
>> > This is for simple IPC between 2 processes of the same snap.
>> > Before attempting to snap the application I was using a fixed
>> > filename
>> > in /tmp. Admittedly poor solution.
>> > The solution should be usable also with another packaging system.
>> >
>> well ... in case of snaps /tmp is a private directory that only your
>> snap can access so it is actually a good place for such stuff ...
>>
>> ... that said ... if you want to use it in other packaging systems
>> where this is not the case it might indeed not be the best choice and
>> using XDG_RUNTIME_DIR might be the better way, as others pointed out.
>>
>> ciao
>>         oli
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>> an/listinfo/snapcraft
>>
>>
>
>
> --
> XiaoGuo, Liu
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Where to save stuff (in snap-agnostic way)

2017-02-04 Thread XiaoGuo Liu
Hi Oli,

Does it mean all of the snaps have the same /tmp or each snap has its own
/tmp? I am a little bit confused about this.

Thanks & best regards,
XiaoGuo



On Sat, Feb 4, 2017 at 6:43 PM, Oliver Grawert  wrote:

> hi,
> Am Freitag, den 03.02.2017, 21:04 +0100 schrieb Luca Dionisi:
> > What is the best place to write (and read) a temporary FIFO file from
> > a confined snap application?
> > This is for simple IPC between 2 processes of the same snap.
> > Before attempting to snap the application I was using a fixed
> > filename
> > in /tmp. Admittedly poor solution.
> > The solution should be usable also with another packaging system.
> >
> well ... in case of snaps /tmp is a private directory that only your
> snap can access so it is actually a good place for such stuff ...
>
> ... that said ... if you want to use it in other packaging systems
> where this is not the case it might indeed not be the best choice and
> using XDG_RUNTIME_DIR might be the better way, as others pointed out.
>
> ciao
> oli
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Where to save stuff (in snap-agnostic way)

2017-02-03 Thread XiaoGuo Liu
Hi Seth,

Thanks. You are right. I just created a new dir under the root, and I tried
to access it, and it was successful this time.

liuxg@liuxg:~/snappy/desktop$ sudo snap run --shell hello.env
[sudo] password for liuxg:
root@liuxg:/home/liuxg/snappy/desktop# cd /run/user/0/snap.hello
root@liuxg:/run/user/0/snap.hello# ls

Many thanks
Best regards,
XiaoGuo

On Sat, Feb 4, 2017 at 10:40 AM, Seth Arnold 
wrote:

> On Sat, Feb 04, 2017 at 10:33:20AM +0800, XiaoGuo Liu wrote:
> > liuxg@liuxg:~/snappy/desktop/ss$ hello.env | grep XDG_RUNTIME
> > XDG_RUNTIME_DIR=/run/user/1000/snap.hello
> > $ sudo snap run --shell hello.env
> > # env | grep XDG_RUNTIME_DIR
> > XDG_RUNTIME_DIR=/run/user/0/snap.hello
>
> Your first command was run as a standard user, probably the first user
> installed on the system, since it is user 1000.
>
> Your second command was run as root via the sudo tool, thus you get a
> different directory. Every user's data should be stored in a place where
> it won't collide with other users, and root is no different in this case.
>
> Thanks
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Where to save stuff (in snap-agnostic way)

2017-02-03 Thread XiaoGuo Liu
Hi,

I just tried it with my helloworld snap example. It shows:

liuxg@liuxg:~/snappy/desktop/ss$ hello.env | grep XDG_RUNTIME
XDG_RUNTIME_DIR=/run/user/1000/snap.hello

When I tried to run it with:

$ sudo snap run --shell hello.env

Inside the shell, I find different variable for XDG_RUNTIME_DIR:

# env | grep XDG_RUNTIME_DIR
XDG_RUNTIME_DIR=/run/user/0/snap.hello

I tried to create the above named dir /run/user/1000/snap.hello, but it is
not accessible in the  shell

Thanks.



On Sat, Feb 4, 2017 at 5:41 AM, Michael Hall  wrote:

> Be sure to use XDG_RUNTIME_DIR and not '/var/run' specifically, as
> XDG_RUNTIME_DIR is /run/user//snap./ in a snap's
> runtime. You may also need to create that directory before using it.
>
> Michael Hall
> mhall...@ubuntu.com
>
> On 02/03/2017 04:19 PM, Christian Dywan wrote:
> > Hey Luca,
> >
> > I'll suggest XDG_RUNTIME_DIR i.e. /var/run
> >
> > Regards,
> > Cris
> >
> > Am 3. Februar 2017 21:04:19 MEZ schrieb Luca Dionisi
> > :
> >
> > What is the best place to write (and read) a temporary FIFO file from
> > a confined snap application?
> > This is for simple IPC between 2 processes of the same snap.
> > Before attempting to snap the application I was using a fixed
> filename
> > in /tmp. Admittedly poor solution.
> > The solution should be usable also with another packaging system.
> >
> > --Luca
> >
> > P.S. the problem with Vala library has been solved and I was able to
> > make the snap work in devmode. Now I am trying to move from devmode
> to
> > strict.
> >
> >
> > --
> > Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9 Mail
> > gesendet.
> >
> >
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
> an/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Snapcraft 2.25 has been released.

2017-01-23 Thread XiaoGuo Liu
Hi Olivier,

Sorry, I do not understand what exactly you mean "no app in the snap is
named like
the snap itself". Could you please elaborate it more?

Thanks & best regards,
XiaoGuo

On Mon, Jan 23, 2017 at 9:50 PM, Olivier Tilloy <
olivier.til...@canonical.com> wrote:

> Hi XiaoGuo,
>
> Your example happens to work because no app in the snap is named like
> the snap itself. For such snaps, using the new desktop feature should
> be safe.
>
> Cheers,
>
>  Olivier
>
>
> On Mon, Jan 23, 2017 at 3:48 AM, XiaoGuo Liu 
> wrote:
> > Hi Olivier,
> >
> > Based on the snapcraft release 2.25, I have made an example at:
> >
> > https://github.com/liu-xiao-guo/helloworld-desktop
> >
> > So, far, I do not have any problems with it. Is there anything I am doing
> > wrongly? I can see the launchers in the Ubuntu dash without any problems
> and
> > the apps are launched well.
> >
> > By the way, I have created a blog for it at
> > http://blog.csdn.net/ubuntutouch/article/details/54691673. It has the
> > captured pictures.
> >
> > Thanks & best regards,
> > XiaoGuo
> >
> > On Sat, Jan 21, 2017 at 12:09 AM, Olivier Tilloy
> >  wrote:
> >>
> >> On Thu, Jan 19, 2017 at 3:47 AM, Sergio Schvezov 
> >> wrote:
> >> > Hello snapcrafters!
> >> >
> >> > We are pleased to announce the release of version `2.25` of snapcraft
> >> > has been released:
> >> > https://launchpad.net/snapcraft/+milestone/2.25
> >> >
> >> > This release is now available on xenial-updates, yakkety-updates and
> >> > zesty.
> >> > What follows are the full release notes (the prettier version can be
> >> > read at https://github.com/snapcore/snapcraft/releases/tag/2.25)
> >> >
> >> > # New in this release
> >> >
> >> > ## Support for hooks
> >> > Hooks support has arrived. There are currently two ways to use them,
> >> > either with a by-convention path or by using a `part` and installing
> into an
> >> > expected path in the part's install directory.
> >> >
> >> > Find out more about this feature at
> >> > https://github.com/snapcore/snapcraft/blob/master/docs/hooks.md
> >> >
> >> > ## Desktop file support
> >> > Aside from the by-convention functionality already in place, you can
> now
> >> > declare a desktop file from your app within an `apps` entry using a
> path
> >> > relative to the `prime` directory pointing to a desktop file,
> snapcraft will
> >> > take care of the rest.
> >>
> >> I would not recommend starting to use that new feature because of
> >> https://launchpad.net/bugs/1658123. This will hopefully be usable in
> >> time for 2.26.
> >>
> >>
> >> > So if your project already has a desktop file, say in
> >> > `./prime/usr/share/applications/my-app.desktop` all you need to do is
> >> > something like this:
> >> >
> >> > ```yaml
> >> > apps:
> >> > my-app:
> >> > command: my-app
> >> > desktop: usr/share/applications/my-app.desktop
> >> > ```
> >> >
> >> > That said, it is worth mentioning that the by-convention mechanism is
> >> > still supported.
> >> >
> >> > ## rust plugin
> >> > The `rust` plugin has seen an improvement and a couple of bug fixes.
> >> >
> >> > The added feature allow for one to set `rust-features` which is a list
> >> > of strings used to build optional dependencies (run `snapcraft help
> rust`
> >> > for a bit more details).
> >> >
> >> > The bug fixes relate to:
> >> >
> >> > - Allowing to build with `Cargo.toml` not in the base source
> directory.
> >> > - Repecting the other `rust` plugin properties: `rust-channel` and
> >> > `rust-revision`.
> >> >
> >> > ## nodejs plugin
> >> > The plugin now correctly downloads dependencies in `package.json` to
> the
> >> > correct location.
> >> >
> >> > ## godeps plugin
> >> > This plugin is now no longer affected by `GOBIN` being set in the
> >> > environment.
> >> >
> >> > ## deb sources
> >> > `deb` sources are now being handled with `python-debian` which does
> >> > incorrecly handle symlinks.
> >> >
> >>

Re: Snapcraft 2.25 has been released.

2017-01-22 Thread XiaoGuo Liu
 a team
> thank you for:
> >
> > - Chris Holcombe
> > - Jonathon Love
> > - Kit Randel
> > - Marco Trevisan
> > - Matthew Aguirre
> > - Olivier Tilloy
> >
> > # Final Notes
> > To get the source for this release check it out at
> > https://github.com/snapcore/snapcraft/releases/tag/2.25
> >
> > A great place to collaborate and discuss features, bugs and ideas on
> > snapcraft is snapcraft@lists.snapcraft.io mailing list or on the
> snapcraft
> > channel on Rocket Chat https://rocket.ubuntu.com/channel/snapcraft
> >
> > To file bugs, please go to https://bugs.launchpad.net/snapcraft/+filebug
> .
> >
> > Happy snapcrafting!
> > -- Sergio and the team
> >
> > --
> > Sent using Dekko from my Ubuntu device
> >
> > --
> > Snapcraft mailing list
> > Snapcraft@lists.snapcraft.io
> > Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Snapcraft 2.25 has been released.

2017-01-19 Thread XiaoGuo Liu
Hi,

For the desktop, can each of the app have its own icon? If yes, how can we
define the icons for each of them?

Thanks & best regards,
XiaoGuo

On Thu, Jan 19, 2017 at 10:47 AM, Sergio Schvezov 
wrote:

> Hello snapcrafters!
>
> We are pleased to announce the release of version `2.25` of snapcraft has
> been released:
> https://launchpad.net/snapcraft/+milestone/2.25
>
> This release is now available on xenial-updates, yakkety-updates and zesty.
> What follows are the full release notes (the prettier version can be read
> at https://github.com/snapcore/snapcraft/releases/tag/2.25)
>
> # New in this release
>
> ## Support for hooks
> Hooks support has arrived. There are currently two ways to use them,
> either with a by-convention path or by using a `part` and installing into
> an expected path in the part's install directory.
>
> Find out more about this feature at https://github.com/snapcore/
> snapcraft/blob/master/docs/hooks.md
>
> ## Desktop file support
> Aside from the by-convention functionality already in place, you can now
> declare a desktop file from your app within an `apps` entry using a path
> relative to the `prime` directory pointing to a desktop file, snapcraft
> will take care of the rest. So if your project already has a desktop file,
> say in `./prime/usr/share/applications/my-app.desktop` all you need to do
> is something like this:
>
> ```yaml
> apps:
> my-app:
> command: my-app
> desktop: usr/share/applications/my-app.desktop
> ```
>
> That said, it is worth mentioning that the by-convention mechanism is
> still supported.
>
> ## rust plugin
> The `rust` plugin has seen an improvement and a couple of bug fixes.
>
> The added feature allow for one to set `rust-features` which is a list of
> strings used to build optional dependencies (run `snapcraft help rust` for
> a bit more details).
>
> The bug fixes relate to:
>
> - Allowing to build with `Cargo.toml` not in the base source directory.
> - Repecting the other `rust` plugin properties: `rust-channel` and
> `rust-revision`.
>
> ## nodejs plugin
> The plugin now correctly downloads dependencies in `package.json` to the
> correct location.
>
> ## godeps plugin
> This plugin is now no longer affected by `GOBIN` being set in the
> environment.
>
> ## deb sources
> `deb` sources are now being handled with `python-debian` which does
> incorrecly handle symlinks.
>
> ## More modes for daemon's in apps
> You can now set the `daemon` property in an `apps` entry to `notify` (and
> it will follow systemd's expected behavior for this service type).
>
> ## Deprecations
> Some new deprecations have been introduced, for `parts` the `prime`
> keyword is now favored over the `snap` one. When using the `snap` keyword a
> link to http://snapcraft.io/docs/deprecation-notices/dn1 will be
> presented with more information and the migration path.
>
> Plugins that are part of snapcraft that were displaying `DEPRECATED`
> notices have all been updated to use the newer plugin API.
>
> ## Classic confinement
> Some improvements were made to classic confinement with a more
> comprehensive error when the prerequisites to build a classic confined snap
> are not met.
>
> ## parts
> Improvements were made to the core parts management of snapcraft:
>
> - `stage` entries now don't need to be replicated in `prime`.
> - cleaning all parts works correctly even if `snapcraft.yaml` is broken.
>
> ## Others
> For the full list of things available on 2.25 feel free to check
> https://launchpad.net/snapcraft/+milestone/2.25
>
> # Contributions
> This release has seen some contributions from outside of the snapcraft
> core team, so we want to give a shout out to these folks, here's a team
> thank you for:
>
> - Chris Holcombe
> - Jonathon Love
> - Kit Randel
> - Marco Trevisan
> - Matthew Aguirre
> - Olivier Tilloy
>
> # Final Notes
> To get the source for this release check it out at
> https://github.com/snapcore/snapcraft/releases/tag/2.25
>
> A great place to collaborate and discuss features, bugs and ideas on
> snapcraft is snapcraft@lists.snapcraft.io mailing list or on the snapcraft
> channel on Rocket Chat https://rocket.ubuntu.com/channel/snapcraft
>
> To file bugs, please go to https://bugs.launchpad.net/snapcraft/+filebug.
>
> Happy snapcrafting!
> -- Sergio and the team
>
> --
> Sent using Dekko from my Ubuntu device
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Which snap interface allows accessing /dev/rfkill?

2017-01-19 Thread XiaoGuo Liu
I think it would be good to let "snappy-debug" snap output what are the
needed plugs. Sometimes, the utility does  not give us hints. Is there any
way to improve the app? It is even easier than looking for some info on the
website.

https://github.com/snapcore/snapd/wiki/Security

Thanks &  best regards,
xiaoguo

On Fri, Jan 20, 2017 at 5:48 AM, Oliver Ries 
wrote:

> On Thu, Jan 19, 2017 at 8:54 AM, Sergio Schvezov <
> sergio.schve...@canonical.com> wrote:
>
>> On Thu, 19 Jan 2017 07:58:53 -0700, Oliver Ries wrote:
>> > On Thu, Jan 19, 2017 at 2:49 AM, Jamie Bennett <
>> jamie.benn...@canonical.com>
>> > wrote:
>> >
>> >> Hi Tonny,
>> >>
>> >> A quick grep of the snapd source code shows that /dev/rfkill is part of
>> >> the network-control and network-manager interfaces.
>> >>
>> >
>> > this method (grep the code) has been a repeated answer in the last few
>> > days, do we have any way of publishing this as part of our
>> documentation?
>>
>> It was one of the feedback items from James last week:
>>
>> - all interfaces described.
>> - extended information on what the interface provides (apparmor rules and
>> seccomp) for easier debugging or figuring out what you need. These don't
>> need to be in your face
>
>
> what does this mean specifically?
> Olli
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Snap portability between different boards?

2017-01-05 Thread XiaoGuo Liu
I think it should as long as they both have the same architecture (32bit or
64bit). If the app use any specific hardware, we need to make sure it
exists on both platform, for example camera.

On Fri, Jan 6, 2017 at 2:39 AM, Dan Kegel  wrote:

> Hi all,
> can snaps built on the pi run on the artik, and vice versa?
> A compatibility matrix might be handy.
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Issues generating snap

2017-01-04 Thread XiaoGuo Liu
Hi Gareth,

I would recommend looking at the example project at
https://github.com/snapcore/snapcraft/tree/master/demos/py3-project. It is
a working example for your reference.

Best regards,
XiaoGuo

On Wed, Jan 4, 2017 at 9:57 PM,  wrote:

>
> You're welcome, it takes a big community to make Ubuntu happen. I hope
>> that you find snaps have just as big an impact :) It would be wonderful
>> if we can really improve the flow of bits from upstreams to users, or
>> even just make it easier for people to manage private apps that they are
>> pushing around on their networks.
>>
>> Mark
>>
>
> Actually I developed a niche application for use on desktop, a product
> only really available on Windows. I packaged it over and over for deb but
> it seems impossible to do. I then paid for someone to package it and a year
> on I'm still waiting for the approval process in the developer portal to
> finish, but there doesn't seem to be anyone to approach about this.
>
> So I have been trying to package in deb format for at least 2 years. I
> built a snap in a night. Ok it didn't work but you have now told me why. I
> get the feeling I'm going to get along with your vision just fine. Expect
> to see a desktop remote control for roku and now TV boxes and PAT testing
> software appearing in the software store soon.
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
> an/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Issues generating snap

2017-01-04 Thread XiaoGuo Liu
Hi Gareth,

Please see my comments below. I am sorry that some places might not be so
clear to you. You can use google-translate to translate it.

Best regards,
XiaoGuo

On Wed, Jan 4, 2017 at 1:33 PM, Gareth France  wrote:

>
>
> On 04/01/17 04:13, XiaoGuo Liu wrote:
>
> Hi Gareth,
>
> Based on sergio's scripts at http://paste.ubuntu.com/23733207/ , I have
> created a tutorial for it. Hopefully, it is useful to you. You may find it
> at:
>
> http://blog.csdn.net/ubuntutouch/article/details/54017425
>
> Best regards,
> XiaoGuo
>
>
> That is wonderful, thank you. However I have encountered several issues.
> First your tutorial is in Chinese, second it is not clear how you are
> naming your container (the command to create it simply refers to it as
> yakkety but the responses to that command state creating and starting
> flying-snake).
>

The name "flying-snake" is automatically chosen during the process. For
your case, it could be a different name. You have to replace it with your
own container name.


>
> When adding a user mine simply returns to the command prompt it does not
> add user,
>

You probably need to use your own container name instead of the one
"flying-snake" in my blog. You may try it again.


> group, home directory, request a password etc. Adding admin privilages
> same issue. Then you tell me to add something at the end of 'the file' but
> you have not said which file or how I should be accessing it.
>

$ lxc exec flying-snake -- visudo  -- it will invoke an editor for editing
some stuff there.

>
>

> I decided to stop here as I doubt very much this is working at my end.
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Issues generating snap

2017-01-03 Thread XiaoGuo Liu
Hi Gareth,

Based on sergio's scripts at http://paste.ubuntu.com/23733207/ , I have
created a tutorial for it. Hopefully, it is useful to you. You may find it
at:

http://blog.csdn.net/ubuntutouch/article/details/54017425

Best regards,
XiaoGuo

On Wed, Jan 4, 2017 at 4:49 AM, Gareth France  wrote:

>
>
> On 03/01/17 20:33, Sergio Schvezov wrote:
>
>> Can you install lxd and create a yakkety container as I did in the paste
>> and try from there?
>>
>
> Installed, but sorry, how do I do that?
>
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
> an/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Package naming clashes

2017-01-03 Thread XiaoGuo Liu
Hi Luther,

Some of the package names are reserved like "google". For normal snaps, you
need to use:
$ snapcraft register snap-name

to make sure your name is successfully registered.

For more info, please refer to:
https://github.com/snapcore/snapcraft/blob/master/docs/upload-your-snap.md

Best regards,
XiaoGuo

On Tue, Jan 3, 2017 at 5:42 PM, Luther Goh Lu Feng  wrote:

> I am sure that there is precedence and guidelines in place, but I couldn't
> to find the search result.
>
> Say someone in the community builds a snap for nginx, and later doesnt
> keep the snap up to date. Then another person builds a more updated nginx
> snap. How are the package names chosen so that there would be collisions,
> and people know that they are installing the latest working version?
>
> Is there some sort of handing and taking over for the package name from
> maintainer to maintainer? How is it done with Ubuntu deb packages at the
> moment? Thanks
>
>
> -- Luther
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Tutorial: how to give apps alias name?

2016-12-22 Thread XiaoGuo Liu
Hi,

I just created a blog on how to give apps alias name in snap packages. You
need to have snap 2.20 and snapcraft 2.24 to support it. The tutorial can
be found at:

http://blog.csdn.net/ubuntutouch/article/details/53839566

Thanks & best regards,
XiaoGuo

-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: content sharing from $SNAP_COMMON

2016-12-21 Thread XiaoGuo Liu
Hi,

Based on the solution, I have created two examples for it:

Share a read-only bianary:
   https://github.com/liu-xiao-guo/content-bin

Share a SNAP_COMMON directory:
   https://github.com/liu-xiao-guo/content-data

I have created a blog at
http://blog.csdn.net/ubuntutouch/article/details/53811829. Hopefully, it is
useful to the rest of the developers.

Best regards,
xiaoguo

On Thu, Dec 22, 2016 at 2:25 AM, Jacek Nykis 
wrote:

> On 21/12/16 17:43, Jacek Nykis wrote:
> > On 21/12/16 17:22, Pat McGowan wrote:
> >> The documentation on sharing writable data was updated last week,
> notably
> >> saying this works in version 2.19.1 and later. There is also a
> >> recommendation to not use subfolders. 2.20.1 is available from xenial
> >> proposed.
> >>
> >> https://github.com/snapcore/snapd/wiki/Content-Interface
> >>
> >> Hope it helps
> >> Pat
> >
> > Thanks for suggestion Pat.
> >
> > I saw that page but I am trying to share read only data. It does not
> > work in 2.17, I also tried with 2.20.1 without luck.
> >
> > I am trying to share single directory containing one file.
> >
> > Regards,
> > Jacek
>
> Thank you everybody for help, especially zyga on rocketchat!
>
> He was able to clarify things for me and provider workaround. I added
> info to the bug in case others hit this problem:
> https://bugs.launchpad.net/snappy/+bug/1650671/comments/2
>
> Regards,
> Jacek
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: content sharing from $SNAP_COMMON

2016-12-21 Thread XiaoGuo Liu
Hi,

If I want to define "executables" and "writable-data" for the same snap
application, what should be the correct way of writing the snapcraft yaml?

Currently, according to the document at
https://github.com/snapcore/snapd/wiki/Content-Interface

slots:
  content:
content: writable-data
write:
  - $SNAP_DATA

There are two "content" there, and it confuses the developers. Which one is
customizable?

Thanks & best regards,
XiaoGuo

On Thu, Dec 22, 2016 at 2:25 AM, Jacek Nykis 
wrote:

> On 21/12/16 17:43, Jacek Nykis wrote:
> > On 21/12/16 17:22, Pat McGowan wrote:
> >> The documentation on sharing writable data was updated last week,
> notably
> >> saying this works in version 2.19.1 and later. There is also a
> >> recommendation to not use subfolders. 2.20.1 is available from xenial
> >> proposed.
> >>
> >> https://github.com/snapcore/snapd/wiki/Content-Interface
> >>
> >> Hope it helps
> >> Pat
> >
> > Thanks for suggestion Pat.
> >
> > I saw that page but I am trying to share read only data. It does not
> > work in 2.17, I also tried with 2.20.1 without luck.
> >
> > I am trying to share single directory containing one file.
> >
> > Regards,
> > Jacek
>
> Thank you everybody for help, especially zyga on rocketchat!
>
> He was able to clarify things for me and provider workaround. I added
> info to the bug in case others hit this problem:
> https://bugs.launchpad.net/snappy/+bug/1650671/comments/2
>
> Regards,
> Jacek
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Source of ssh key for first login

2016-12-21 Thread XiaoGuo Liu
To my best understanding, you must have network to have the console-conf
for the first time setup.

On Wed, Dec 21, 2016 at 5:51 PM, Luther Goh Lu Feng 
wrote:

> During setup, console-conf will download the SSH key registered with your
> Store account, The ssh key is used for first login.
>
> Is there a way to configure Ubuntu Core such that the source of the ssh
> key can be from elsewhere? eg for cases whereby the device cant go online
> and can only access a private network. Thanks
>
>
> -- Luther
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Dashboard service to view deployed snaps/versions on fleet of devices running Ubuntu Core

2016-12-21 Thread XiaoGuo Liu
You may find more reading in my blog at
http://blog.csdn.net/ubuntutouch/article/details/52980068

On Wed, Dec 21, 2016 at 5:48 PM, XiaoGuo Liu 
wrote:

> Firstly, you log into your ubuntu core device, and use the following
> command to install snapweb:
>
> $ sudo snap install snapweb
>
> Then on your desktop browser, just open the address like:
> ubuntu-core-device-ip:4200. On the browser, you will see the installed apps
> and also you can install some new apps there.
>
> Best regards,
> XiaoGuo
>
> On Wed, Dec 21, 2016 at 5:38 PM, Luther Goh Lu Feng 
> wrote:
>
>> I am interested to know if there are any online management dashboards for
>> Ubuntu Core device management. Thanks.
>>
>> -- Luther
>>
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>> an/listinfo/snapcraft
>>
>
>
>
> --
> XiaoGuo, Liu
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Dashboard service to view deployed snaps/versions on fleet of devices running Ubuntu Core

2016-12-21 Thread XiaoGuo Liu
Firstly, you log into your ubuntu core device, and use the following
command to install snapweb:

$ sudo snap install snapweb

Then on your desktop browser, just open the address like:
ubuntu-core-device-ip:4200. On the browser, you will see the installed apps
and also you can install some new apps there.

Best regards,
XiaoGuo

On Wed, Dec 21, 2016 at 5:38 PM, Luther Goh Lu Feng 
wrote:

> I am interested to know if there are any online management dashboards for
> Ubuntu Core device management. Thanks.
>
> -- Luther
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Published snap on candidate channel not found

2016-12-19 Thread XiaoGuo Liu
Hi Peng,

I think the reason is that we might want to show only apps with quality.
We do not want to mess up everything there by using "snap finding".

I can find all of my published apps at https://myapps.developer.ubuntu.com/.
If it does not work for you, you probably need to file a bug against the
store.

Best regards,
XiaoGuo


On Tue, Dec 20, 2016 at 2:47 PM, Peng Liu  wrote:

> Hi XiaoGuo,
>
> What could be the reason that I can not either find or install the snap I
> published to the 16.04 store through web page?
> https://myapps.developer.ubuntu.com/
>
> Thanks.
>
> Peng
>
> On Mon, Dec 19, 2016 at 11:58 PM, XiaoGuo Liu 
> wrote:
>
>> Hi Luther,
>>
>> Currently, "snap find" only can find the snaps published on the "stable"
>> channel. I cannot be use to search for the apps published on other channels.
>>
>> From snap version 2.18 on wards, "snap find" with no  parameters will
>> return the featured snaps:
>>
>> liu-xiao-guo@localhost:~$ snap find
>> Name   Version   Developer   Notes  Summary
>> docker 1.11.2-9  canonical   -  The docker app deployment
>> mechanism
>> lxd2.6.2 canonical   -  LXD - the container
>> lighervisor
>> rocketchat-server  0.39.0rocketchat  -  Group chat server for
>> 100s,  installed in seconds.
>> liu-xiao-guo@localhost:~$ snap version
>> snap2.20
>> snapd   2.20
>> series  16
>>
>> Hope this answers your question!
>>
>> Best regards,
>> XiaoGuo
>>
>> On Tue, Dec 20, 2016 at 12:25 PM, Luther Goh Lu Feng 
>> wrote:
>>
>>> I published a snap after going through the codelabs tutorial,
>>> hello-luther, in the candidate channel. However I am unable to find the
>>> snap when I perform a search
>>>
>>> $ snap find hello-luther |grep luther
>>>
>>> But I did manage to install the snap:
>>>
>>> sudo snap install hello-luther --channel=candidate
>>>
>>>
>>> Question: is the failure to return the search result expected? Thanks.
>>>
>>>
>>> -- Luther
>>> --
>>> Snapcraft mailing list
>>> Snapcraft@lists.snapcraft.io
>>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>>> an/listinfo/snapcraft
>>>
>>>
>>
>>
>> --
>> XiaoGuo, Liu
>>
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>> an/listinfo/snapcraft
>>
>>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Published snap on candidate channel not found

2016-12-19 Thread XiaoGuo Liu
Hi Luther,

Currently, "snap find" only can find the snaps published on the "stable"
channel. I cannot be use to search for the apps published on other channels.

>From snap version 2.18 on wards, "snap find" with no  parameters will
return the featured snaps:

liu-xiao-guo@localhost:~$ snap find
Name   Version   Developer   Notes  Summary
docker 1.11.2-9  canonical   -  The docker app deployment
mechanism
lxd2.6.2 canonical   -  LXD - the container
lighervisor
rocketchat-server  0.39.0rocketchat  -  Group chat server for 100s,
 installed in seconds.
liu-xiao-guo@localhost:~$ snap version
snap2.20
snapd   2.20
series  16

Hope this answers your question!

Best regards,
XiaoGuo

On Tue, Dec 20, 2016 at 12:25 PM, Luther Goh Lu Feng 
wrote:

> I published a snap after going through the codelabs tutorial,
> hello-luther, in the candidate channel. However I am unable to find the
> snap when I perform a search
>
> $ snap find hello-luther |grep luther
>
> But I did manage to install the snap:
>
> sudo snap install hello-luther --channel=candidate
>
>
> Question: is the failure to return the search result expected? Thanks.
>
>
> -- Luther
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: mysqltuner on a snap install

2016-12-15 Thread XiaoGuo Liu
Hi,

Some time ago, I created a tomcat/mysql/jsp web application. The sample
snap app can be found at:

https://github.com/liu-xiao-guo/tomcat-maven-webapp

I created a blog for at
http://blog.csdn.net/ubuntutouch/article/details/52217173

Hopefully, the example code is useful to you!

Best regards,
XiaoGuo

On Thu, Dec 15, 2016 at 7:40 PM, Tiago Carrondo 
wrote:

> Hi, all
>
> I have a question/problem:
>
> I have installed the nexcloud snap and I want to use de mysqltuner to
> fine tune his mysql server but if I "apt install" mysqltuner is going to
> run on the global mysq server of the  machine but not on the server
> inside the snap.
>
> How can I solve this?
>
> Thanks in advance
>
> --
> Melhores cumprimentos/Regards
>
> Tiago Carrondo
> consultor | formador | sysadmin
> https://carrondo.net
> https://launchpad.net/~tcarrondo
> https://wiki.ubuntu.com/tcarrondo
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Snapcraft's state tracking improvements

2016-12-13 Thread XiaoGuo Liu
Thanks kyle, this is really important! In a hackathon event, when the
network was bad and shared by many people, keeping cleaning the project and
rebuilding the project took a lot of time to build the whole project.
Sometime, it took a few tens minutes to get it done!

Best regards,
XiaoGuo

On Wed, Dec 14, 2016 at 5:57 AM, Kyle Fazzari 
wrote:

> Hey everyone.
>
> I feel it coming on... this is going to be a tome. tl;dr... snapcraft
> could be smarter than it is. But would that lead to its doing more for
> you than you want? We'd like to find out.
>
> I've spoken to a few of you individually about this, and I want to open
> this topic up for wider conversation. We have a number of bugs logged
> against snapcraft for its state tracking shortcomings. For example, a
> few of you may have run into these issues:
>
> - You add a stage package to a part in an already-built snap, and run
> `snapcraft` again. It happily says all the steps have already run, and
> generates a snap that doesn't contain your stage package.
>
> - You add (or modify) a file in the local source for a part of an
> already-built snap, and run `snapcraft` again`. It again reports that
> everything has already run, and generates a snap that doesn't contain
> your modifications.
>
> We used to have even more of these issues, but snapcraft has slowly been
> getting smarter about things like this. You may have noticed that v2.23
> fixed that first problem, for example. Well, sort of. Let me explain.
>
> Snapcraft's state tracking allows us to do some handy things. For
> example, as you probably know, when you run the `stage` or `prime`
> steps, you're combining files from multiple parts into a single
> directory. Thanks to state tracking, snapcraft is able to disentangle
> which files came from which part, and allow you to remove a single
> part's files using per-step cleaning.
>
> However, this is complicated by the ability to have inter-part
> dependencies (using the `after` keyword). If part A depends on part B
> and part B is being cleaned, then snapcraft knows part A needs to be
> cleaned as well. But should it go ahead and clean it for you? What if
> you were offline and part A required the internet to build? Or
> re-building part A took forever and you didn't want to just wipe it? We
> weren't sure when we implemented this ability, so we decided to be safe
> and force you to say exactly what you wanted. For example, if you simply
> said `snapcraft clean part B` we error out, saying something like "Hey
> you're trying to clean part B, but part A depends on it. If you intend
> for both to be cleaned, please say so."
>
> This same mindset can be found elsewhere:
>
> - If you change something in the YAML that makes a part out of date
> (e.g. stage packages) it tells you it's out of date and why, but doesn't
> clean/rebuild it for you.
>
> - Trying to build part A which depends on part B before B itself has
> been staged leads to "Hey, part A has unsatisfied dependencies." If you
> run `snapcraft stage A B` it'll do the right thing.
>
> - Not-yet-released features will know when local sources for a part have
> changed, and build the updates, but what should it do if that part has
> another depending upon it?
>
> The point is: snapcraft is/will be smart enough to help a lot more than
> it currently does in these types of situations. The question I'm posing
> to you all is: how much do you want its help?
>
> I see four options for how to handle such situations:
>
>
> *Option 1*: Error out and make you be specific. This is the current
> behavior.
>
> *Option 2*: Automatically take care of everything. If you modify a part
> with dependencies, snapcraft will rebuild those dependencies as it sees
> fit without your needing to say so. Similarly, if you clean a part with
> dependencies, snapcraft will clean those dependencies as it sees fit
> without your needing to say so.
>
> *Option 3*: Prompt. "You've modified part A, but part B depends upon it.
> Would you like to rebuild it as well? (Y/n)" and the like.
>
> *Option 4*: Add the ability to configure this behavior between options
> 1-3. Perhaps the sensible default would be option 3.
>
>
> Our goal here is to do the least surprising thing, which is why we're
> asking for input from our users. Please let your voice be heard!
>
> --
> Kyle Fazzari (kyrofa)
> Software Engineer
> Canonical Ltd.
> k...@canonical.com
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Cannot install snap apps from store

2016-12-10 Thread XiaoGuo Liu
Hi Madper,

Thanks for your reply. Yeah, it has been confirmed in the bug report at
https://bugs.launchpad.net/snappy/+bug/1639981. It happens in other regions
as well.

Best regards,
XiaoGuo

On Fri, Dec 9, 2016 at 8:29 PM, Madper Xie  wrote:

> Hi Xiaoguo,
>
> I do believe that you have a good proxy. So just try to use your proxy
> when you reproduce the timeout issue again. So that we can know if Mainland
> China is the only affected area.
>
>
>- sudo systemctl edit snapd; #adding following configure:
>
> [Service]
> Environment=http_proxy=http://host:port
>
>- sudo systemctl restart snapd
>- If you do only have a socks proxy you can use polipoc as a bridge.
>Which will accept http input and redirect it to a socks interface.
>- Put following configuration into /etc/polipo/config
>
> `
>
> logSyslog = true
> logFile = /var/log/polipo/polipo.log
> proxyAddress = "0.0.0.0"
> proxyPort = 8118
> socksParentProxy = "127.0.0.1:1080" # please modify this line as
> needed.
> socksProxyType = socks5
> ```
>
> On Fri, Dec 9, 2016 at 7:46 PM, Shuduo Sang 
> wrote:
>
>> Not sure if there are CDN deployed in China to accelerate Ubuntu Core
>> store. If there are, the issue need be resolved by CDN vendor. If there are
>> not, please help to deploy some. Network issue really make Chinese
>> developer and Ubuntu Core taster frustrated.
>>
>> On Fri, Dec 9, 2016 at 3:54 PM, XiaoGuo Liu 
>> wrote:
>>
>>> Yes, at one time, it was consistent that it did not work at all no
>>> matter how many times I tried, and it was quite embarrassing during a
>>> training session. I thought it was network problem. After some time, it
>>> became OK.
>>>
>>> On Fri, Dec 9, 2016 at 3:46 PM, Manik Taneja >> > wrote:
>>>
>>>>
>>>>
>>>> On Dec 8, 2016, at 11:13 PM, Michael Nelson <
>>>> michael.nel...@canonical.com> wrote:
>>>>
>>>> On Fri, Dec 9, 2016 at 5:39 PM Manik Taneja 
>>>> wrote:
>>>>
>>>>> On Dec 8, 2016, at 8:21 PM, Oliver Ries 
>>>>> wrote:
>>>>>
>>>>> Hi
>>>>>
>>>>> On Thu, Dec 8, 2016 at 6:31 PM, XiaoGuo Liu >>>> > wrote:
>>>>>
>>>>> Hi,
>>>>>
>>>>> I do not know how many of you have met the issue. When I try to
>>>>> install an app from the store, it comes me an error like:
>>>>>
>>>>> liuxg@ubuntu:~$ sudo snap install tensorflow-demo --devmode --beta
>>>>> error: cannot install "tensorflow-demo": Get
>>>>> https://search.apps.ubuntu.com/api/v1/snaps/details/tensorfl
>>>>> ow-demo?channel=beta: net/http: request canceled while waiting for
>>>>> connection (Client.Timeout exceeded while awaiting headers)
>>>>> liuxg@ubuntu:~$ sudo snap install tensorflow-demo --devmode --beta
>>>>> error: cannot install "tensorflow-demo": Get
>>>>> https://search.apps.ubuntu.com/api/v1/snaps/details/tensorfl
>>>>> ow-demo?channel=beta: net/http: request canceled while waiting for
>>>>> connection (Client.Timeout exceeded while awaiting headers)
>>>>>
>>>>> This has been usually because of CDN issues afaik. The store team
>>>>> should able to confirm shortly.
>>>>>
>>>>
>>>> In this case, it's an issue just with the initial connection from the
>>>> client to search.apps.ubuntu.com, before following any CDN url to
>>>> download the snap. I also tried to reproduce around 40mins after XiaoGuo
>>>> and couldn't.
>>>>
>>>> After trying to reproduce, I checked the apache logs for
>>>> search.apps.ubuntu.com and saw that during that time it only ever saw
>>>> requests which resulted in 200 replies:
>>>>
>>>> http://paste.ubuntu.com/23602216/
>>>>
>>>> There were no relevant errors in the error log that I could see, nor
>>>> does our monitoring show any high load at the time, so unless apache isn't
>>>> logging timeouts, I suspect the requests weren't getting through to
>>>> search.apps.ubuntu.com for some network-related reason, but I'm keen
>>>> for someone else on the store team to check the networking and logs.
>>>>
>>>> We have seen this before intermittently, so please if you see a client
>>>> timeout a

Re: Cannot install snap apps from store

2016-12-08 Thread XiaoGuo Liu
Yes, at one time, it was consistent that it did not work at all no matter
how many times I tried, and it was quite embarrassing during a training
session. I thought it was network problem. After some time, it became OK.

On Fri, Dec 9, 2016 at 3:46 PM, Manik Taneja 
wrote:

>
>
> On Dec 8, 2016, at 11:13 PM, Michael Nelson 
> wrote:
>
> On Fri, Dec 9, 2016 at 5:39 PM Manik Taneja 
> wrote:
>
>> On Dec 8, 2016, at 8:21 PM, Oliver Ries 
>> wrote:
>>
>> Hi
>>
>> On Thu, Dec 8, 2016 at 6:31 PM, XiaoGuo Liu 
>> wrote:
>>
>> Hi,
>>
>> I do not know how many of you have met the issue. When I try to install
>> an app from the store, it comes me an error like:
>>
>> liuxg@ubuntu:~$ sudo snap install tensorflow-demo --devmode --beta
>> error: cannot install "tensorflow-demo": Get https://search.apps.ubuntu.
>> com/api/v1/snaps/details/tensorflow-demo?channel=beta: net/http: request
>> canceled while waiting for connection (Client.Timeout exceeded while
>> awaiting headers)
>> liuxg@ubuntu:~$ sudo snap install tensorflow-demo --devmode --beta
>> error: cannot install "tensorflow-demo": Get https://search.apps.ubuntu.
>> com/api/v1/snaps/details/tensorflow-demo?channel=beta: net/http: request
>> canceled while waiting for connection (Client.Timeout exceeded while
>> awaiting headers)
>>
>> This has been usually because of CDN issues afaik. The store team should
>> able to confirm shortly.
>>
>
> In this case, it's an issue just with the initial connection from the
> client to search.apps.ubuntu.com, before following any CDN url to
> download the snap. I also tried to reproduce around 40mins after XiaoGuo
> and couldn't.
>
> After trying to reproduce, I checked the apache logs for
> search.apps.ubuntu.com and saw that during that time it only ever saw
> requests which resulted in 200 replies:
>
> http://paste.ubuntu.com/23602216/
>
> There were no relevant errors in the error log that I could see, nor does
> our monitoring show any high load at the time, so unless apache isn't
> logging timeouts, I suspect the requests weren't getting through to
> search.apps.ubuntu.com for some network-related reason, but I'm keen for
> someone else on the store team to check the networking and logs.
>
> We have seen this before intermittently, so please if you see a client
> timeout as above, add your data to:
>
> https://bugs.launchpad.net/click-package-index/+bug/1639981
>
> and we'll keep digging.
>
> Just to add, I have seen this issue intermittently a few times before.
> Next time, I'll capture logs and add to the bug. Please list out all that
> you need captured..
>
>
> Thanks!
> -Michael
>
>
>> Can you check status.snapcraft.io to see any outages around the date you
>> experienced this?
>>
>>
>> I just did a quick test on my classic Ubuntu (AMD64) and was able to
>> download & install the snap just fine.
>>
>>
>> In fact, I have met this this problem a number of times, and sometimes it
>> works fine. Also, my colleague said to me that he gets the same issue
>> sometimes. What is the root cause for this?
>>
>>
>> it might be good to get this into a bug report with all relevant
>> information (distribution, architecture, network setup (traceroute?) and a
>> timestamp so server logs can be matched.
>>
>> let us know the id and the team will be looking at that asap.
>>
>> thx,
>> Olli
>>
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.ubuntu.com/
>> mailman/listinfo/snapcraft
>>
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.ubuntu.com/
>> mailman/listinfo/snapcraft
>>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Cannot install snap apps from store

2016-12-08 Thread XiaoGuo Liu
Hi,

I do not know how many of you have met the issue. When I try to install an
app from the store, it comes me an error like:

liuxg@ubuntu:~$ sudo snap install tensorflow-demo --devmode --beta
error: cannot install "tensorflow-demo": Get
https://search.apps.ubuntu.com/api/v1/snaps/details/tensorflow-demo?channel=beta:
net/http: request canceled while waiting for connection (Client.Timeout
exceeded while awaiting headers)
liuxg@ubuntu:~$ sudo snap install tensorflow-demo --devmode --beta
error: cannot install "tensorflow-demo": Get
https://search.apps.ubuntu.com/api/v1/snaps/details/tensorflow-demo?channel=beta:
net/http: request canceled while waiting for connection (Client.Timeout
exceeded while awaiting headers)

In fact, I have met this this problem a number of times, and sometimes it
works fine. Also, my colleague said to me that he gets the same issue
sometimes. What is the root cause for this?

Thanks  & best regards,
XiaoGuo

-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Tutorial: How to make use of QEMU to build armhf/arm64 snap on Ubuntu desktop 16.04

2016-12-06 Thread XiaoGuo Liu
Hi Oliver,

Thanks! I will have a try with your solution.

Best regards,
XiaoGuo

On Tue, Dec 6, 2016 at 5:39 PM, Oliver Grawert  wrote:

> hi,
> Am Dienstag, den 06.12.2016, 15:31 +0800 schrieb XiaoGuo Liu:
> >
> > Hi,
> >
> > Today, I made a tutorial on how to compile a armhf/arm64 snap on
> > Ubuntu Destkop 16.04 desktop. It could be useful to those people who
> > do not have a ARM board with you. The tutorial can be found at:
> >
> > http://blog.csdn.net/ubuntutouch/article/details/53482262
> >
> you can easily replace point 2 with:
>
> wget a tarball from http://cdimage.ubuntu.com/ubuntu-base/xenial/daily/
> current/ ... even downloading through a slow connection and untarring
> will likely be a lot faster than running your own debootstrap from
> scratch. the tarballs will also have the very recent updates installed
> from xenial-updates and xenial-security and are specifically designed
> as clean build chroots.
>
> note that you need to copy /etc/resolv.conf from the host to have
> working networking inside the chroot...
>
> ciao
> oli
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Tutorial: How to make use of QEMU to build armhf/arm64 snap on Ubuntu desktop 16.04

2016-12-05 Thread XiaoGuo Liu
Hi,

Today, I made a tutorial on how to compile a armhf/arm64 snap on Ubuntu
Destkop 16.04 desktop. It could be useful to those people who do not have a
ARM board with you. The tutorial can be found at:

http://blog.csdn.net/ubuntutouch/article/details/53482262

Thanks & best regards,
-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Snapping Ubuntu phone app using "ubuntu-app-platform"

2016-11-23 Thread XiaoGuo Liu
It is done. Thanks!

On Thu, Nov 24, 2016 at 10:54 AM, Érico P  wrote:

> Very cool, when possible please add a README on the github repository.
>
> Em 24 de nov de 2016 12:44 AM, "XiaoGuo Liu" 
> escreveu:
>
>> Hi,
>>
>> I have created a Chinese blog at http://blog.csdn.net/ubuntu
>> touch/article/details/53315941. It shows how to make use of
>> ubuntu-app-platform to create a Qt-based application using content
>> interface. Hopefully, it is useful to some of you!
>>
>> Thanks & best regards,
>> XiaoGuo
>>
>> On Wed, Nov 23, 2016 at 3:48 PM, XiaoGuo Liu 
>> wrote:
>>
>>> Hi all,
>>>
>>> I just found that there was nothing wrong with my project. After some
>>> troubleshooting, I finally found the root cause of the problem. The 
>>> ubuntu-app-platform
>>> is based on Qt 5.6.1 version. However, the Qt version on my desktop is
>>> Qt 5.5.1
>>>
>>> As suggested by the blog https://developer.ubuntu.
>>> com/en/blog/2016/11/16/snapping-qt-apps/, we need to install
>>> the  stable-phone-overlay at https://launchpad.net/~ci-t
>>> rain-ppa-service/+archive/ubuntu/stable-phone-overlay/. We need to do
>>> "sudo apt upgrade" and "sudo apt dist-upgrade" to make sure our Qt version
>>> is Qt 5.6.1. Then everything will be fine.
>>>
>>> Best regards,
>>> XiaoGuo
>>>
>>>
>>>
>>>
>>>
>>> On Wed, Nov 23, 2016 at 12:21 PM, XiaoGuo Liu >> > wrote:
>>>
>>>> Hi,
>>>>
>>>> I just read a blog about snapping a Qt app at:
>>>>
>>>> https://developer.ubuntu.com/en/blog/2016/11/16/snapping-qt-apps/
>>>>
>>>> I followed the step, and I made my own project at:
>>>>
>>>> https://github.com/liu-xiao-guo/rssreader_platform
>>>>
>>>> The file size is dropped dramatically. However, there is a problem when
>>>> launching the app:
>>>>
>>>> =
>>>> "This application failed to start because it could not find or load the
>>>> Qt platform plugin "xcb".
>>>>
>>>> Reinstalling the application may fix this problem.
>>>> Aborted (core dumped)
>>>> =
>>>>
>>>> I am not sure what is missing in my project.
>>>>
>>>> However, my sample app at https://github.com/liu-xiao
>>>> -guo/rssreader_slim. It works fine, and it does not use
>>>> "ubuntu-app-platform", which uses the content sharing.
>>>>
>>>> Can anyone help me?
>>>>
>>>> Thanks & best regards,
>>>> XiaoGuo
>>>>
>>>>
>>>> --
>>>> XiaoGuo, Liu
>>>>
>>>
>>>
>>>
>>> --
>>> XiaoGuo, Liu
>>>
>>
>>
>>
>> --
>> XiaoGuo, Liu
>>
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>> an/listinfo/snapcraft
>>
>>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Snapping Ubuntu phone app using "ubuntu-app-platform"

2016-11-23 Thread XiaoGuo Liu
Hi,

I have created a Chinese blog at
http://blog.csdn.net/ubuntutouch/article/details/53315941. It shows how to
make use of ubuntu-app-platform to create a Qt-based application using
content interface. Hopefully, it is useful to some of you!

Thanks & best regards,
XiaoGuo

On Wed, Nov 23, 2016 at 3:48 PM, XiaoGuo Liu 
wrote:

> Hi all,
>
> I just found that there was nothing wrong with my project. After some
> troubleshooting, I finally found the root cause of the problem. The 
> ubuntu-app-platform
> is based on Qt 5.6.1 version. However, the Qt version on my desktop is Qt
> 5.5.1
>
> As suggested by the blog https://developer.ubuntu.
> com/en/blog/2016/11/16/snapping-qt-apps/, we need to install
> the  stable-phone-overlay at https://launchpad.net/~ci-t
> rain-ppa-service/+archive/ubuntu/stable-phone-overlay/. We need to do
> "sudo apt upgrade" and "sudo apt dist-upgrade" to make sure our Qt version
> is Qt 5.6.1. Then everything will be fine.
>
> Best regards,
> XiaoGuo
>
>
>
>
>
> On Wed, Nov 23, 2016 at 12:21 PM, XiaoGuo Liu 
> wrote:
>
>> Hi,
>>
>> I just read a blog about snapping a Qt app at:
>>
>> https://developer.ubuntu.com/en/blog/2016/11/16/snapping-qt-apps/
>>
>> I followed the step, and I made my own project at:
>>
>> https://github.com/liu-xiao-guo/rssreader_platform
>>
>> The file size is dropped dramatically. However, there is a problem when
>> launching the app:
>>
>> =
>> "This application failed to start because it could not find or load the
>> Qt platform plugin "xcb".
>>
>> Reinstalling the application may fix this problem.
>> Aborted (core dumped)
>> =
>>
>> I am not sure what is missing in my project.
>>
>> However, my sample app at https://github.com/liu-xiao-guo/rssreader_slim.
>> It works fine, and it does not use "ubuntu-app-platform", which uses the
>> content sharing.
>>
>> Can anyone help me?
>>
>> Thanks & best regards,
>> XiaoGuo
>>
>>
>> --
>> XiaoGuo, Liu
>>
>
>
>
> --
> XiaoGuo, Liu
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Snapping Ubuntu phone app using "ubuntu-app-platform"

2016-11-22 Thread XiaoGuo Liu
Hi all,

I just found that there was nothing wrong with my project. After some
troubleshooting, I finally found the root cause of the problem. The
ubuntu-app-platform
is based on Qt 5.6.1 version. However, the Qt version on my desktop is Qt
5.5.1

As suggested by the blog https://developer.ubuntu.com/en/blog/2016/11/16/
snapping-qt-apps/, we need to install the  stable-phone-overlay at
https://launchpad.net/~ci-train-ppa-service/+archive/
ubuntu/stable-phone-overlay/. We need to do "sudo apt upgrade" and "sudo
apt dist-upgrade" to make sure our Qt version is Qt 5.6.1. Then everything
will be fine.

Best regards,
XiaoGuo





On Wed, Nov 23, 2016 at 12:21 PM, XiaoGuo Liu 
wrote:

> Hi,
>
> I just read a blog about snapping a Qt app at:
>
> https://developer.ubuntu.com/en/blog/2016/11/16/snapping-qt-apps/
>
> I followed the step, and I made my own project at:
>
> https://github.com/liu-xiao-guo/rssreader_platform
>
> The file size is dropped dramatically. However, there is a problem when
> launching the app:
>
> =
> "This application failed to start because it could not find or load the Qt
> platform plugin "xcb".
>
> Reinstalling the application may fix this problem.
> Aborted (core dumped)
> =
>
> I am not sure what is missing in my project.
>
> However, my sample app at https://github.com/liu-xiao-guo/rssreader_slim.
> It works fine, and it does not use "ubuntu-app-platform", which uses the
> content sharing.
>
> Can anyone help me?
>
> Thanks & best regards,
> XiaoGuo
>
>
> --
> XiaoGuo, Liu
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Snapping Ubuntu phone app using "ubuntu-app-platform"

2016-11-22 Thread XiaoGuo Liu
Hi,

I just read a blog about snapping a Qt app at:

https://developer.ubuntu.com/en/blog/2016/11/16/snapping-qt-apps/

I followed the step, and I made my own project at:

https://github.com/liu-xiao-guo/rssreader_platform

The file size is dropped dramatically. However, there is a problem when
launching the app:

=
"This application failed to start because it could not find or load the Qt
platform plugin "xcb".

Reinstalling the application may fix this problem.
Aborted (core dumped)
=

I am not sure what is missing in my project.

However, my sample app at https://github.com/liu-xiao-guo/rssreader_slim.
It works fine, and it does not use "ubuntu-app-platform", which uses the
content sharing.

Can anyone help me?

Thanks & best regards,
XiaoGuo


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: How to install Ubuntu core into virtualbox

2016-11-21 Thread XiaoGuo Liu
I am sorry that I forgot to put the link in my last email.

The correct link is at
http://blog.csdn.net/ubuntutouch/article/details/53285110

On Tue, Nov 22, 2016 at 2:46 PM, XiaoGuo Liu 
wrote:

> Hi,
>
> Based on Kyle's blog at:
>
> https://kyrofa.com/posts/ubuntu-core-on-virtualbox
>
> I created a more detailed blog for installing Ubuntu Core 16 into
> virutalbox. Hopefully, it is useful to you!
>
> Thanks & best regards,
> XiaoGuo
>
> --
> XiaoGuo, Liu
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


How to install Ubuntu core into virtualbox

2016-11-21 Thread XiaoGuo Liu
Hi,

Based on Kyle's blog at:

https://kyrofa.com/posts/ubuntu-core-on-virtualbox

I created a more detailed blog for installing Ubuntu Core 16 into
virutalbox. Hopefully, it is useful to you!

Thanks & best regards,
XiaoGuo

-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: How to restart a simple daemon?

2016-11-20 Thread XiaoGuo Liu
Hi Enwei,

When your app is running, your app definitely knows since it is started.
You can do something there.

When your app is stopped, you can also add a "stop-command" when you define
your snapcraft.yaml. Please refer to
http://snapcraft.io/docs/build-snaps/syntax

I do not know whether there are any hooks for this purpose.

Hope this helps!
XiaoGuo

On Mon, Nov 21, 2016 at 11:22 AM, Enwei Zhang 
wrote:

> Hi Xiaoguo and folks,
> Is there a notification/callback mechanism so that when snap
> enable/disable is executed on my snap, my snap can receive notification to
> do some corresponding actions?
> Thanks.
>
> Br
> Enwei
>
> On Mon, Nov 21, 2016 at 10:50 AM, Enwei Zhang 
> wrote:
>
>> Thank you so much Xiaoguo.
>>
>> On Mon, Nov 21, 2016 at 10:30 AM, XiaoGuo Liu 
>> wrote:
>>
>>> Hi Enwei,
>>>
>>> There are a few ways to handle it.
>>>
>>> 1) You do not need to make it a daemon before it is getting stable. When
>>> your run your app, just use "sudo" to run it on command line. When it is
>>> stable, change it to daemon.
>>>
>>> 2) You can use "snap enable/disable" to toggle the state of the app.
>>> When it is enabled, it starts to run again. In your case, your daemon app
>>> will be restarted.
>>>
>>> Best regards,
>>> XiaoGuo
>>>
>>> On Mon, Nov 21, 2016 at 10:23 AM, Enwei Zhang >> > wrote:
>>>
>>>> Hello,
>>>> When I install a simple daemon snap, the daemon is started right after
>>>> it is installed.
>>>> Suppose it stops due to some condition, is there a way to restart it?
>>>> Thanks a lot.
>>>>
>>>> Br
>>>> Enwei
>>>>
>>>> --
>>>> Snapcraft mailing list
>>>> Snapcraft@lists.snapcraft.io
>>>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>>>> an/listinfo/snapcraft
>>>>
>>>>
>>>
>>>
>>> --
>>> XiaoGuo, Liu
>>>
>>> --
>>> Snapcraft mailing list
>>> Snapcraft@lists.snapcraft.io
>>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>>> an/listinfo/snapcraft
>>>
>>>
>>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: How to restart a simple daemon?

2016-11-20 Thread XiaoGuo Liu
Hi Enwei,

There are a few ways to handle it.

1) You do not need to make it a daemon before it is getting stable. When
your run your app, just use "sudo" to run it on command line. When it is
stable, change it to daemon.

2) You can use "snap enable/disable" to toggle the state of the app. When
it is enabled, it starts to run again. In your case, your daemon app will
be restarted.

Best regards,
XiaoGuo

On Mon, Nov 21, 2016 at 10:23 AM, Enwei Zhang 
wrote:

> Hello,
> When I install a simple daemon snap, the daemon is started right after it
> is installed.
> Suppose it stops due to some condition, is there a way to restart it?
> Thanks a lot.
>
> Br
> Enwei
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Multiple SSH (login) accounts

2016-11-16 Thread XiaoGuo Liu
Hi Michael,

Thanks for your solution. I just tried it and it worked. We are going to
have a hackathon event, and we will distribute some devices to the
developers. I have installed the image well. Without your solution, all of
the developers will have to be reflashed to set it up.

I just found that "create-user" is so far not supported on Raspberry Pi2.
At the mean time, I did not find "adduser" command. On Raspberry pi 3,
--force-managed option is not recognized.

I have use the command:

$ sudo snap create-user --sudoer launchpad_email_address

Based on your solution, I have created a blog article at
http://blog.csdn.net/ubuntutouch/article/details/53196732. Hopefully, it
will benefit the rest of the developers

Thanks & best regards,
XiaoGuo



On Thu, Nov 17, 2016 at 2:40 AM, Michael Hudson-Doyle <
michael.hud...@canonical.com> wrote:

>
>
> On 17 November 2016 at 07:30, Jacques Supcik  wrote:
>
>> Hello.
>>
>> During the installation of ubuntu core, we have to give an e-mail address
>> to link the device with an Ubuntu account. It is possible to then add
>> additional accounts to the device (e.g. to allow multiple sysadmins to
>> manage a device) ?
>>
>> I tried a "sudo snap create-user", but the (undocumented) command returns
>> "cannot create user: device already managed". (So this is probably why the
>> command is not documented 😊)
>>
>
> I think you can use sudo snap create-user --sudoer --force-managed. But
> you can also use adduser --extrausers.
>
> Cheers,
> mwh
>
> Thank you in advance for your reply.
>>
>> Best regards,
>>
>> █  Jacques
>>
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>> an/listinfo/snapcraft
>>
>>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Tutorial: how to create a simple snapcraft custom plugin

2016-11-13 Thread XiaoGuo Liu
Hi,

I am sorry that I pasted the wrong link for the article. The correct one is:

http://blog.csdn.net/ubuntutouch/article/details/53157531

Best regards,
XiaoGuo

On Mon, Nov 14, 2016 at 2:57 PM, XiaoGuo Liu 
wrote:

> Hi,
>
> Today, I created a very simple tutorial on how to create a snapcraft
> custom plugin. The link is at:
>
> http://blog.csdn.net/ubuntutouch/article/details/52981623
>
> Hopefully, it is useful to some of you!
>
> Best regards,
> XiaoGuo
>
> --
> XiaoGuo, Liu
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Tutorial: how to create a simple snapcraft custom plugin

2016-11-13 Thread XiaoGuo Liu
Hi,

Today, I created a very simple tutorial on how to create a snapcraft custom
plugin. The link is at:

http://blog.csdn.net/ubuntutouch/article/details/52981623

Hopefully, it is useful to some of you!

Best regards,
XiaoGuo

-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Cliqz Snap

2016-11-12 Thread XiaoGuo Liu
Hi Chris,

You may find the tips at https://github.com/snapcore/snapd/wiki/Security.
You may use the command like:

$ scmp_sys_resolver 983045
set_tls

to find out the security violation.

Best regards,
XiaoGuo

On Sun, Nov 13, 2016 at 7:13 AM, Chris  wrote:

> Has anyone gotten this snap to run? The install went fine AFAICT but
> when executed nothing happens. Syslog shows
>
> Nov 12 17:00:55 localhost /usr/lib/snapd/snapd[844]: daemon.go:174:
> DEBUG: uid=1000;@ GET /v2/snaps 31.184976ms 200
>
> Nov 12 17:00:55 localhost kernel: [250160.993225] audit: type=1326
> audit(1478991655.666:65): auid=1000 uid=1000 gid=1000 ses=3 pid=10201
> comm="cliqz" exe="/snap/cliqz/6/opt/CLIQZ/CLIQZ" sig=31 arch=c03e
> syscall=272 compat=0 ip=0x7f5d82721c19 code=0x0
>
> When executed from the cli
>
> chris@localhost:~$ cliqz
> Bad system call
>
> --
> Chris
> KeyID 0xE372A7DA98E6705C
> 31.11972; -97.90167 (Elev. 1092 ft)
> 16:59:51 up 2 days, 21:28, 1 user, load average: 0.32, 0.37, 0.36
> Ubuntu 16.04.1 LTS, kernel 4.4.0-47-generic #68-Ubuntu SMP Wed Oct 26
> 19:39:52 UTC 2016
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Snapping Chrome browser

2016-11-07 Thread XiaoGuo Liu
Sorry, There is a typo in the last email. The installation instruction is:

$ sudo snap install --beta --devmode

:)

On Tue, Nov 8, 2016 at 10:02 AM, XiaoGuo Liu 
wrote:

> Hi,
>
> After spending some effort, I finally made the Chrome browser snap working
> though it worked in "devmode". There is a small problem when I am trying to
> install it not using devmode.
>
> You can now install it like:
>
> $ sudo snap install --beta --devmoe
>
> The source code can be found at: https://github.com/liu-xiao-guo/mychrome
>
> I have created a blog at: http://blog.csdn.net/
> ubuntutouch/article/details/53078713
>
> Currently, it supports Chinese language and also Chinese input method.
>
> Thanks & best regards,
> XiaoGuo
>
> --
> XiaoGuo, Liu
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Snapping Chrome browser

2016-11-07 Thread XiaoGuo Liu
Hi,

After spending some effort, I finally made the Chrome browser snap working
though it worked in "devmode". There is a small problem when I am trying to
install it not using devmode.

You can now install it like:

$ sudo snap install --beta --devmoe

The source code can be found at: https://github.com/liu-xiao-guo/mychrome

I have created a blog at:
http://blog.csdn.net/ubuntutouch/article/details/53078713

Currently, it supports Chinese language and also Chinese input method.

Thanks & best regards,
XiaoGuo

-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Project templates in snapcraft

2016-11-04 Thread XiaoGuo Liu
+1

I think it may apply to "nodejs", "python", "tomcat", "mysql", "php",
"java" etc.

Best regards,
XiaoGuo

On Sat, Nov 5, 2016 at 1:39 AM, Benjamin Zeller <
benjamin.zel...@canonical.com> wrote:

> Just a small proposal to have templates in snapcraft, that provide some
> sort of starting point for
> people without the need to read lots of tutorials, but get started with
> their project right away.
>
> My proposal would be to add a template engine in snapcraft, that generates
> predefined projects
> or at least a predefined snapcraft.yaml for a specific use case.
>
> Something like:
>
> snapcraft init --template=ubuntu-touch-app , which would bootstrap a
> simple snapcraft project
> targeting QML/Qt APIs.
>
> I think that could help people to get their apps snapped even faster.
>
> Cheers,
>
> Benjamin
>
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
> an/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Installing Ubuntu Core system

2016-11-04 Thread XiaoGuo Liu
Hi,

I have created a tutorial on how to install Ubuntu Core systems. It can be
found at http://blog.csdn.net/ubuntutouch/article/details/53036627.
Hopefully, it is useful to the developers.

Thanks & have a nice weekend!
-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Ubuntu Core 16 Final!

2016-11-04 Thread XiaoGuo Liu
Hi Michael,

Thanks. I have found the root cause of it. I need to replace USER with my
own account "liu-xiao-guo". I think USER is different from my account name
in the Ubuntu One.

Best regards,
XiaoGuo

On Fri, Nov 4, 2016 at 3:10 PM, XiaoGuo Liu 
wrote:

> Hi Michael,
>
> First, thanks for your detailed instructions. I just followed your steps
> to install the QEMU to test the Ubuntu Core. However, I have to problems in
> logging into the Ubuntu Core. The captured screen is like
> http://imgur.com/a/Qyfc9. May I know what the correct password for
> logging into the Ubuntu core. Is it the one for Ubuntu One? or the one for
> the ssh?
>
> Thanks & best regards,
> XiaoGuo
>
> On Thu, Nov 3, 2016 at 11:47 PM, Michael Vogt 
> wrote:
>
>> Hi,
>>
>> The Snappy team is happy to announce the release of Ubuntu Core 16.
>>
>> Ubuntu Core is an operating system entirely based on snaps, including
>> its foundation. Applications, kernel, core operating system, and
>> gadget components are all managed as snaps and are installed and
>> refreshed by snapd, the daemon and tooling responsible for making it
>> all dance.
>>
>> The images are available currently for PC (amd64, i386) and
>> for Pi2/Pi3 and Dragonboard. These images can be downloaded from:
>>
>> http://releases.ubuntu.com/ubuntu-core/16/
>>
>> Once unpacked, the images are bootable, the PC image can be booted
>> directly in qemu-kvm, virtualbox or on real hardware. When running the
>> images in qemu-kvm it is helpful to use the "-redir" feature of
>> qemu-kvm. e.g.:
>>
>> $ kvm -smp 2 -m 1500 -redir tcp:10022::22 ubuntu-core-16-amd64.img
>>
>> The message from console-conf is a bit misleading in this setup. It
>> will say "ssh USER@10.0.2.15". However due to the way that the
>> qemu-kvm user networking behaves, you will actually have to run the
>> following to ssh into the images:
>>
>> $ ssh -p 10022 USER@localhost
>>
>> or if you have the following snippet in ~/.ssh/config
>>
>> Host kvm.snappy
>>  Hostname localhost
>>  Port 10022
>>  User USER
>>  UserKnownHostsFile /dev/null
>>  StrictHostKeyChecking no
>>
>> then you can just
>>
>> $ ssh kvm.snappy
>>
>> into it.
>>
>> The Pi2/Pi3/Dragonboard image can be written to a sdcard via dd. An
>> alternative way to write the image is to use "go-dd", e.g. on Ubuntu
>> 16.04:
>>
>>  $ sudo snap install --devmode --beta godd
>>  $ sudo /snap/bin/godd ubuntu-core-16-pi2.img.xz
>>  [this will print a message showing what devices are removable]
>>  $ xzcat ubuntu-core-16-pi2-rc2.img.xz | sudo /snap/bin/godd -
>> /dev/sdXX
>>
>> After booting the image you can enter your Ubuntu One email and it
>> will automatically create a matching user with the right ssh keys. If
>> you do not have an Ubuntu SSO account yet please create one at:
>>
>> https://login.ubuntu.com/
>>
>> (don't forget to add your public ssh keys to that account).
>>
>> Known issues:
>> - pi3 wlan can not be initially configured, wired network needs to be
>>   used for the initial setup (you can re-run "sudo console-conf" at
>>   any later point to re-configure the device for wlan only
>>   operation).
>>
>> Bug references for the pi3 known issues:
>> - http://pad.lv/1637153
>>   plugging in network cable during configuration can cause a traceback
>>   on pi3
>> - http://pav.lv/1624322
>>   no wlan0 device at all on first boot on pi3
>> - http://pad.lv/1632387
>>   wifi setup times out on pi3 devices on first boot
>>
>> These images follow the "stable" channel. If you find any issues,
>> please let us know via:
>>
>> https://bugs.launchpad.net/snappy/
>>
>> Ubuntu Core 16 follows a rolling release model, security updates and
>> bug fixes will come to you via regular over the air updates for the
>> lifetime of the release.
>>
>> Enjoy this release!
>>
>> Cheers,
>>  Michael Vogt (on behalf of the Snappy team)
>>
>>
>> --
>> Devices mailing list
>> devi...@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.snapcraft.io/mai
>> lman/listinfo/devices
>>
>
>
>
> --
> XiaoGuo, Liu
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Ubuntu Core 16 Final!

2016-11-04 Thread XiaoGuo Liu
Hi Michael,

First, thanks for your detailed instructions. I just followed your steps to
install the QEMU to test the Ubuntu Core. However, I have to problems in
logging into the Ubuntu Core. The captured screen is like
http://imgur.com/a/Qyfc9. May I know what the correct password for logging
into the Ubuntu core. Is it the one for Ubuntu One? or the one for the ssh?

Thanks & best regards,
XiaoGuo

On Thu, Nov 3, 2016 at 11:47 PM, Michael Vogt 
wrote:

> Hi,
>
> The Snappy team is happy to announce the release of Ubuntu Core 16.
>
> Ubuntu Core is an operating system entirely based on snaps, including
> its foundation. Applications, kernel, core operating system, and
> gadget components are all managed as snaps and are installed and
> refreshed by snapd, the daemon and tooling responsible for making it
> all dance.
>
> The images are available currently for PC (amd64, i386) and
> for Pi2/Pi3 and Dragonboard. These images can be downloaded from:
>
> http://releases.ubuntu.com/ubuntu-core/16/
>
> Once unpacked, the images are bootable, the PC image can be booted
> directly in qemu-kvm, virtualbox or on real hardware. When running the
> images in qemu-kvm it is helpful to use the "-redir" feature of
> qemu-kvm. e.g.:
>
> $ kvm -smp 2 -m 1500 -redir tcp:10022::22 ubuntu-core-16-amd64.img
>
> The message from console-conf is a bit misleading in this setup. It
> will say "ssh USER@10.0.2.15". However due to the way that the
> qemu-kvm user networking behaves, you will actually have to run the
> following to ssh into the images:
>
> $ ssh -p 10022 USER@localhost
>
> or if you have the following snippet in ~/.ssh/config
>
> Host kvm.snappy
>  Hostname localhost
>  Port 10022
>  User USER
>  UserKnownHostsFile /dev/null
>  StrictHostKeyChecking no
>
> then you can just
>
> $ ssh kvm.snappy
>
> into it.
>
> The Pi2/Pi3/Dragonboard image can be written to a sdcard via dd. An
> alternative way to write the image is to use "go-dd", e.g. on Ubuntu
> 16.04:
>
>  $ sudo snap install --devmode --beta godd
>  $ sudo /snap/bin/godd ubuntu-core-16-pi2.img.xz
>  [this will print a message showing what devices are removable]
>  $ xzcat ubuntu-core-16-pi2-rc2.img.xz | sudo /snap/bin/godd -
> /dev/sdXX
>
> After booting the image you can enter your Ubuntu One email and it
> will automatically create a matching user with the right ssh keys. If
> you do not have an Ubuntu SSO account yet please create one at:
>
> https://login.ubuntu.com/
>
> (don't forget to add your public ssh keys to that account).
>
> Known issues:
> - pi3 wlan can not be initially configured, wired network needs to be
>   used for the initial setup (you can re-run "sudo console-conf" at
>   any later point to re-configure the device for wlan only
>   operation).
>
> Bug references for the pi3 known issues:
> - http://pad.lv/1637153
>   plugging in network cable during configuration can cause a traceback
>   on pi3
> - http://pav.lv/1624322
>   no wlan0 device at all on first boot on pi3
> - http://pad.lv/1632387
>   wifi setup times out on pi3 devices on first boot
>
> These images follow the "stable" channel. If you find any issues,
> please let us know via:
>
> https://bugs.launchpad.net/snappy/
>
> Ubuntu Core 16 follows a rolling release model, security updates and
> bug fixes will come to you via regular over the air updates for the
> lifetime of the release.
>
> Enjoy this release!
>
> Cheers,
>  Michael Vogt (on behalf of the Snappy team)
>
>
> --
> Devices mailing list
> devi...@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.snapcraft.io/
> mailman/listinfo/devices
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Snap Shadowsocks and publish it to the Ubuntu Store

2016-11-02 Thread XiaoGuo Liu
Hi,

Today, I created a tutorial about how to snap shadowsocks and publish it
into Ubuntu Store.

Tutorial: 如何snap Shadowsocks并发布到Ubuntu Store

Souce code: https://github.com/liu-xiao-guo/ss-qt
Ubuntu Core link: https://uappexplorer.com/app/ss-qt.xiaoguo

You can install it using the following command:

$ sudo snap install ss-qt


Thanks & best regards,
XiaoGuo
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Ubuntu Core 16 beta images available

2016-09-12 Thread XiaoGuo Liu
Hi Lorn,

I tried it,  and I got the same result. However, the image worked on my Pi3
device :)

Best regards,
XiaoGuo

On Mon, Sep 12, 2016 at 4:13 PM, Lorn Potter 
wrote:

>
>
> On 08/09/16 07:50, Michael Vogt wrote:
> > More architectures and boards (arm64 dragonboard, pi3) will
> > follow shortly. You can download them at:
> >
> > http://cdimage.ubuntu.com/ubuntu-snappy/16.04/current/
>
> I tried the rpi3 image, when I tried unxz, I got this:
> unxz: ubuntu-core-16-rpi3.img.xz: Unexpected end of input
>
> md5sum was the same as reported on the server.
>
>
> --
> Software Engineer
> System Enablement, Canonical Ltd
> QtSystemInfo, QtSensors maintainer
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Ubuntu Core 16 beta images available

2016-09-11 Thread XiaoGuo Liu
Hi,

I have  a QualCom dragonboard 410. I have flashed the Ubuntu Core image to
the SD card, and I also set the S6 switch to boot from the SD card
according to the instruction at:

https://github.com/96boards/documentation/wiki/Dragonboard-410c-Installation-Guide-for-Linux-and-Android#installing-image-using-an-sd-card-image

When booting into the Ubuntu core, it needs to have the network access to
complete the installation. The board does not provide an Ethernet port use.
It provide the WLAN. How can we configure the WLAN to make the network
working to complete the installation? It would be good to have a complete
installation guide at our developer website.

Thanks & best regards,
XiaoGuo

On Thu, Sep 8, 2016 at 4:25 PM, Jamie Bennett 
wrote:

> On 07/09/16 at 11:50pm, Michael Vogt wrote:
> > Ubuntu Core 16 Images
> > =
> >
> > The Ubuntu snappy team is happy to announce the first beta images for
> > Ubuntu Core 16.  The images use the snapd package manager to install
> > and update all components of the system including kernel, core, gadget
> > and applications.
>
> Great news and well done all round. To squeeze so much goodness into snapd,
> snap-confine, snapcraft, store, ubuntu-image, and other components that
> make
> this possible is really an achievement.
>
> > The images are available for PC (amd64, i386) and Raspberry Pi2
> > (armhf). More architectures and boards (arm64 dragonboard, pi3) will
> > follow shortly. You can download them at:
> >
> > http://cdimage.ubuntu.com/ubuntu-snappy/16.04/current/
> >
> > The images are bootable, the pc image can be booted directly in
> > qemu-kvm or virtualenv. The pi2 image can be written to a sdcard via:
> >
> > unxz ubuntu-core-16-pc.img.xz
> > dd if= ubuntu-core-16-pc.img of=/dev/sdXX
> >
> > Where /dev/sdXX is the path of your sd card.
> >
> > After booting the image you can enter your Ubuntu SSO email and it
> > will automatically create a matching user with the right ssh keys. If
> > you do not have an Ubuntu SSO account yet you can create one at:
> >
> > https://login.ubuntu.com/
> >
> > These images follow the "beta" channel.
> >
> > Enjoy the fresh images! If you find any bugs or issues, please let us
> > know via:
> >
> > https://bugs.launchpad.net/snappy/
> >
> > Cheers,
> >  Michael (on behalf of the snappy team)
> >
> >
> >
> > --
> > Snapcraft mailing list
> > Snapcraft@lists.snapcraft.io
> > Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: File permissions within a snap

2016-08-25 Thread XiaoGuo Liu
Hi Jenny,

I do not think you need to define "SNAP_USER_DATA".It is already there.
Please check my "hello" example code at
https://github.com/liu-xiao-guo/helloworld-demo. After you install the app,
you can run the command like:

liuxg@liuxg:~$ hello.env | grep SNAP
SNAP_USER_COMMON=/home/liuxg/snap/hello/common
SNAP_LIBRARY_PATH=/var/lib/snapd/lib/gl:
SNAP_COMMON=/var/snap/hello/common
SNAP_USER_DATA=/home/liuxg/snap/hello/x1
SNAP_DATA=/var/snap/hello/x1
SNAP_REVISION=x1
SNAP_NAME=hello
SNAP_ARCH=amd64
SNAP_VERSION=1.0
SNAP=/snap/hello/x1

Basically, SNAP_USER_DATA is defined as
"/home/liuxg/snap/Your_Package_Name/version_number"

Best regards,
XiaoGuo

On Thu, Aug 25, 2016 at 7:03 PM, Jenny Murphy 
wrote:

> Hi,
>  Do I need to define the location of SNAP_USER_DATA. Currently I added
> the following line to a wrapper script that already runs in my app :
>
> echo "User Data = " $SNAP_USER_DATA
>
>
> The result is
>  User Data =
>
>
> Thanks a lot for you help. I guess this stuff is very basic but I am
> having to get up to speed quickly on snappy.
> Jenny
>
> On 24 August 2016 at 12:01, Zygmunt Krynicki  com> wrote:
>
>>
>> Wiadomość napisana przez Jenny Murphy  w
>> dniu 24.08.2016, o godz. 12:58:
>>
>> Hi,
>>  I have a java application built as a .snap.
>> As part of its normal operation it will create some files (for output).
>> However this is not successful due to permissions issue :
>> For example , I tried to create the file in /home/ubuntu/examples/ :
>> java.io.FileNotFoundException: /home/ubuntu/examples/example.txt
>> (Permission denied)
>> I got a similar result whenI tired to create it in the current dir :
>> /apps/gateway.sideload/IcNYWMFDGBeY
>>
>>
>> You can freely create files in $SNAP_USER_DATA - the per-user data
>> directory or $SNAP_DATA - the global data directory (for daemons).
>>
>> If you want to write to other locations you need an interface to do it.
>> For example you can use the home interface to get write access to most of
>> the $HOME directory.
>>
>> You can do this by just defining a „home” plug on your application.
>>
>> Best regards
>> ZK
>>
>>
>> So is there a way around this?
>>
>> Thanks in advance for any suggestions.
>>
>> --
>> *Jenny Murphy*
>> *EpiSensor, Georges Quay House, Georges Quay, Limerick, Ireland*
>> jenny.mur...@episensor.com   t | +353 (0) 61
>> 512 511  w | http://www.episensor.com
>> --
>> Snapcraft mailing list
>> Snapcraft@lists.snapcraft.io
>> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailm
>> an/listinfo/snapcraft
>>
>>
>>
>
>
> --
> *Jenny Murphy*
> *EpiSensor, Georges Quay House, Georges Quay, Limerick, Ireland*
> jenny.mur...@episensor.com   t | +353 (0) 61
> 512 511  w | http://www.episensor.com
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu (刘晓国)
Mobile: +86-13911181302
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Does anyone know how to build snap for ARM architecture?

2016-08-24 Thread XiaoGuo Liu
Hi Vicamo,

That is very good. I will try it later on. By the way, I have successfully
compiled armhf snap by using "classic" application. It is very convenient :)

Thanks & best regards,
XiaoGuo

On Thu, Aug 25, 2016 at 11:16 AM, Vicamo Yang 
wrote:

> Hi,
>
> I got some docker images in https://hub.docker.com/r/vicamo/ubuntu .
> Basically all Ubuntu suite-arch combinations are available, so you may
> want to try snapcraft on them. Dockerfile source code are available in
> https://github.com/vicamo/docker-brew-ubuntu-core . Feel free to fork
> your own and customize the images for snapcraft. :)
>
> On Thu, Aug 25, 2016 at 11:02 AM, YC Cheng  wrote:
> >
> > -- Forwarded message --
> > From: knitzsche 
> > Date: 2016-08-24 21:55 GMT+08:00
> > Subject: Re: Does anyone know how to build snap for ARM architecture?
> > To: XiaoGuo Liu ,
> snapcraft@lists.snapcraft.io
> >
> >
> > I have been able to build armhf snaps on my amd64 host using an armhf
> > pbuilder chroot.
> >
> > Cheers,
> > Kyle
> >
> > On 08/24/2016 01:34 AM, XiaoGuo Liu wrote:
> >>
> >> Hi,
> >>
> >> I just now successfully used launchpad.net <http://launchpad.net> to
> >> build snaps for ARM architecture. However, the precondition is that it
> >> works on my desktop well. I am thinking whether there is an alternative
> >> way to compile snaps for armhf in view of the fact that raspberry is now
> >> supporting the architecture. I used to come with a docker solution to it
> >> for 15.04. Now docker snap is not there any more. Can anyone tell me how
> >> to build for armhf snaps?
> >>
> >> Thanks & best regards,
> >> XiaoGuo
> >>
> >> --
> >> XiaoGuo, Liu (刘晓国)
> >> Mobile: +86-13911181302
> >>
> >>
> >
> > --
> > Snapcraft mailing list
> > Snapcraft@lists.snapcraft.io
> > Modify settings or unsubscribe at:
> > https://lists.ubuntu.com/mailman/listinfo/snapcraft
> >
>
>
>
> --
> Vicamo Yang
>



-- 
XiaoGuo, Liu (刘晓国)
Mobile: +86-13911181302
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


How to assign a hardware in my snap application?

2016-08-24 Thread XiaoGuo Liu
Hi,

On Series 16, we need to use interface to make the connection between the
Ubuntu core and Snap apps in order to make use of the hardware. Previously,
on 15.04, I used the following command do get the hardware assignment:

(RaspberryPi2)ubuntu@localhost:~$ sudo snappy hw-assign piglow.sideload
/dev/i2c-1
'piglow.sideload' is now allowed to access '/dev/i2c-1'

Currently, I list all of the interfaces from raspberry pi snappy image, but
I do not find any interface which corresponds to my requirement.  Do I need
to wait for the interface? or I did it wrongly? What should be the right
interface to use in my case?

ubuntu@localhost:~/apps$ snap interfaces
SlotPlug
:bluetooth-control  -
:firewall-control   -
:fuse-support   -
:hardware-observe   -
:home   -
:kernel-module-control  -
:locale-control -
:log-observe-
:mount-observe  -
:networkpiglow-app,snapweb
:network-bind   piglow-app,snapweb,webcam-webui
:network-control-
:network-observe-
:opengl -
:ppp-
:process-control-
:snapd-control  snapweb
:system-observe -
:system-trace   -
:timeserver-control -
:timezone-control   -
:tpm-
-   webcam-webui:camera

Also, I find that the "camera" interface is missing in the current image.

Thanks & best regards,
XiaoGuo

-- 
XiaoGuo, Liu (刘晓国)
Mobile: +86-13911181302
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Does anyone know how to build snap for ARM architecture?

2016-08-24 Thread XiaoGuo Liu
Hi Loïc,

Thanks! Yes, I want to build it for Ubuntu core series 16. I will have a
try.

Best regards,
XiaoGuo

On Wed, Aug 24, 2016 at 2:40 PM, Loïc Minier  wrote:

> Hi,
>
> On Wed, Aug 24, 2016 at 7:34 AM, XiaoGuo Liu 
> wrote:
>
>> I just now successfully used launchpad.net to build snaps for ARM
>> architecture. However, the precondition is that it works on my desktop
>> well. I am thinking whether there is an alternative way to compile snaps
>> for armhf in view of the fact that raspberry is now supporting the
>> architecture. I used to come with a docker solution to it for 15.04. Now
>> docker snap is not there any more. Can anyone tell me how to build for
>> armhf snaps?
>>
>
> Docker snap should be available for 15.04 in stable channel; it's only in
> the edge channel (and using devmode) for series 16 (install with snap
> install --devmode --edge docker). Please let me know if it's in any way
> broken or missing!
>
> Otherwise you can indeed use the classic environment, or a classic image
> as Simon mentioned.
>
> Cheers,
> - Loïc
>



-- 
XiaoGuo, Liu (刘晓国)
Mobile: +86-13911181302
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: Does anyone know how to build snap for ARM architecture?

2016-08-23 Thread XiaoGuo Liu
Hi Simon,

Thanks a lot for your reply. On 15.04, I installed docker, and inside
docker, I installed a Ubuntu Server so that I can compile for armhf. A lot
of developers may not have the luxury to have two arm devices. I am
thinking your second option could be more realistic. I do not have a Ubuntu
Core device yet. So, the right command is:

$ snap install --devmode --edge classic

In this case, it enters to the classic ubuntu mode, rightt?

By the way, how to exit the mode? Previously, I saw some instructions like:

$ sudo snappy enable-classic
$ snappy shell classic
$ sudo snappy destroy-classic

I think they were for the 15.04 Ubuntu core.

Thanks & best regards,
XiaoGuo


On Wed, Aug 24, 2016 at 1:44 PM, Simon Fels 
wrote:

> On 24.08.2016 07:34, XiaoGuo Liu wrote:
> > Hi,
> >
> > I just now successfully used launchpad.net <http://launchpad.net> to
> > build snaps for ARM architecture. However, the precondition is that it
> > works on my desktop well. I am thinking whether there is an alternative
> > way to compile snaps for armhf in view of the fact that raspberry is now
> > supporting the architecture. I used to come with a docker solution to it
> > for 15.04. Now docker snap is not there any more. Can anyone tell me how
> > to build for armhf snaps?
>
> I've installed Ubuntu Server for that purpose on one of my pi2 machines
> and doing all builds there. The classic snap from the store (not sure
> how far that is, but installing with snap install --devmode --edge
> classic should work) would be another possible way to build on an arm
> device as it gives you a full apt-get'able system on an all-snap one.
>
> regards,
> Simon
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at: https://lists.ubuntu.com/
> mailman/listinfo/snapcraft
>



-- 
XiaoGuo, Liu (刘晓国)
Mobile: +86-13911181302
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Does anyone know how to build snap for ARM architecture?

2016-08-23 Thread XiaoGuo Liu
Hi,

I just now successfully used launchpad.net to build snaps for ARM
architecture. However, the precondition is that it works on my desktop
well. I am thinking whether there is an alternative way to compile snaps
for armhf in view of the fact that raspberry is now supporting the
architecture. I used to come with a docker solution to it for 15.04. Now
docker snap is not there any more. Can anyone tell me how to build for
armhf snaps?

Thanks & best regards,
XiaoGuo

-- 
XiaoGuo, Liu (刘晓国)
Mobile: +86-13911181302
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: How to resolve same file conflicts from different parts when building a snap project?

2016-07-31 Thread XiaoGuo Liu
Hi Didier,

I think it should be the same issue as the one described there. By the way,
 my snapcraft version is:

liuxg@liuxg:~$ snapcraft --version
2.13.1

You can try my example at
https://github.com/liu-xiao-guo/rssreader_snap/blob/master/snapcraft.yaml.

You just need to take off the following line:


stage:
- -usr/share/pkgconfig/xkeyboard-config.pc

in order to duplicate the issue.


Best regards,
XiaoGuo

On Mon, Aug 1, 2016 at 2:14 PM, Didier Roche  wrote:

> Le 01/08/2016 à 04:37, XiaoGuo Liu a écrit :
>
> Hi,
>
> I finally solved the problem by adding:
>
> stage:
>   - -usr/share/pkgconfig/xkeyboard-config.pc
>
> in one of the parts to avoid the conflicts (the same file from different
> parts with the same installation path).
>
>
> Hey,
>
> I think you are getting https://bugs.launchpad.net/snapcraft/+bug/1604472,
> which was supposed to be fixed already in 2.13. Which version of snapcraft
> is it running?
>
> Sergio, do you mind confirming (he's the second to mention it)?
>
> Cheers,
> Didier
>
>
> Best regards,
> XiaoGuo
>
> On Mon, Aug 1, 2016 at 9:54 AM, XiaoGuo Liu 
> wrote:
>
>> Hi,
>>
>> Recently, I tried to convert a qmake project from Ubuntu phone SDK to a
>> snap project, and it worked well initially two weeks ago. The source code
>> can be found at:
>>
>> https://github.com/liu-xiao-guo/rssreader_snap
>>
>> However, now I try to rebuild the project, and I get the following error:
>>
>> ==
>> Removing suid/guid from
>> /home/liuxg/snappy/desktop/rssreader/parts/rssreader/install/usr/lib/x86_64-linux-gnu/oxide-qt/chrome-sandbox
>> Pulling rssreader
>> Skipping build desktop/qt5 (already ran)
>> 'rssreader' has prerequisites that need to be staged: desktop/qt5
>> Skipping pull desktop/qt5 (already ran)
>> Skipping build desktop/qt5 (already ran)
>> Parts 'desktop/qt5' and 'rssreader' have the following file paths in
>> common which have different contents:
>> usr/share/pkgconfig/xkeyboard-config.pc
>> =
>>
>> I find that the same file "xkeyboard-config.pc" is from two different
>> parts:
>>
>>  - rssreader
>>  - desktop (desktop/qt5), which is used to invoke the Qt app.
>>
>> I do not know how to resolve the conflict issue the same file comes from
>> two different parts
>>
>> Thanks & best regards,
>> XiaoGuo
>>
>> --
>> XiaoGuo, Liu (刘晓国)
>> Mobile: +86-13911181302
>>
>
>
>
> --
> XiaoGuo, Liu (刘晓国)
> Mobile: +86-13911181302
>
>
>
>
> --
> Snapcraft mailing list
> Snapcraft@lists.snapcraft.io
> Modify settings or unsubscribe at:
> https://lists.ubuntu.com/mailman/listinfo/snapcraft
>
>


-- 
XiaoGuo, Liu (刘晓国)
Mobile: +86-13911181302
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


Re: How to resolve same file conflicts from different parts when building a snap project?

2016-07-31 Thread XiaoGuo Liu
Hi,

I finally solved the problem by adding:

stage:
  - -usr/share/pkgconfig/xkeyboard-config.pc

in one of the parts to avoid the conflicts (the same file from different
parts with the same installation path).

Best regards,
XiaoGuo

On Mon, Aug 1, 2016 at 9:54 AM, XiaoGuo Liu 
wrote:

> Hi,
>
> Recently, I tried to convert a qmake project from Ubuntu phone SDK to a
> snap project, and it worked well initially two weeks ago. The source code
> can be found at:
>
> https://github.com/liu-xiao-guo/rssreader_snap
>
> However, now I try to rebuild the project, and I get the following error:
>
> ==
> Removing suid/guid from
> /home/liuxg/snappy/desktop/rssreader/parts/rssreader/install/usr/lib/x86_64-linux-gnu/oxide-qt/chrome-sandbox
> Pulling rssreader
> Skipping build desktop/qt5 (already ran)
> 'rssreader' has prerequisites that need to be staged: desktop/qt5
> Skipping pull desktop/qt5 (already ran)
> Skipping build desktop/qt5 (already ran)
> Parts 'desktop/qt5' and 'rssreader' have the following file paths in
> common which have different contents:
> usr/share/pkgconfig/xkeyboard-config.pc
> =
>
> I find that the same file "xkeyboard-config.pc" is from two different
> parts:
>
>  - rssreader
>  - desktop (desktop/qt5), which is used to invoke the Qt app.
>
> I do not know how to resolve the conflict issue the same file comes from
> two different parts
>
> Thanks & best regards,
> XiaoGuo
>
> --
> XiaoGuo, Liu (刘晓国)
> Mobile: +86-13911181302
>



-- 
XiaoGuo, Liu (刘晓国)
Mobile: +86-13911181302
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft


How to resolve same file conflicts from different parts when building a snap project?

2016-07-31 Thread XiaoGuo Liu
Hi,

Recently, I tried to convert a qmake project from Ubuntu phone SDK to a
snap project, and it worked well initially two weeks ago. The source code
can be found at:

https://github.com/liu-xiao-guo/rssreader_snap

However, now I try to rebuild the project, and I get the following error:

==
Removing suid/guid from
/home/liuxg/snappy/desktop/rssreader/parts/rssreader/install/usr/lib/x86_64-linux-gnu/oxide-qt/chrome-sandbox
Pulling rssreader
Skipping build desktop/qt5 (already ran)
'rssreader' has prerequisites that need to be staged: desktop/qt5
Skipping pull desktop/qt5 (already ran)
Skipping build desktop/qt5 (already ran)
Parts 'desktop/qt5' and 'rssreader' have the following file paths in common
which have different contents:
usr/share/pkgconfig/xkeyboard-config.pc
=

I find that the same file "xkeyboard-config.pc" is from two different parts:

 - rssreader
 - desktop (desktop/qt5), which is used to invoke the Qt app.

I do not know how to resolve the conflict issue the same file comes from
two different parts

Thanks & best regards,
XiaoGuo

-- 
XiaoGuo, Liu (刘晓国)
Mobile: +86-13911181302
-- 
Snapcraft mailing list
Snapcraft@lists.snapcraft.io
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/snapcraft