Call for testing: snapcraft 3.0


#21

Is there any way to use LXD container instead? I rather don’t like multipass as it’s a VM which (probably) has the same VM limitations(like, how does it deal with snap builds that requires lots(a few gigabytes) of memory?)


#22

3.0.1 is now on the stable channel


#23

@sergiusens @evan multpass installed from snap doesn’t work on Fedora, or am I missing something?

✗ snapcraft                       
Launching a VM.
failed to launch: Connect Failed                                                
An error occurred when trying to launch the instance with 'multipass': returned exit code 3.
Ensure that 'multipass' is setup correctly and try again.

Is there a list of Docker implications?

Now the next logical step for me is to try snapcraft in Docker, and because I switched to base: core18 it will attempt to install multipass to create VM inside Docker. :slight_smile:

I already started to port podman to snap, so I can run podman on Ubuntu, so that I can snapcraft in container without docker and build my other snap.


#24

Hey,

@abitrolly can you check the permissions of /run/multipass_socket please? If that doesn’t exist, post the output of journalctl --unit snap.multipass.* somewhere?

I’ll try it myself here in the mean time.


#25
✗ ls -la /run/multipass_socket
ls: cannot access '/run/multipass_socket': No such file or directory
✗ sudo journalctl --unit snap.multipass.*
zsh: no matches found: snap.multipass.*

EDIT (needed quotes around *):

Dec 04 17:49:37 blackred dnsmasq[5033]: started, version 2.75 cachesize 150
Dec 04 17:49:37 blackred dnsmasq[5033]: compile time options: IPv6 GNU-getopt DBus i18n IDN DHCP DHCPv6 no-Lua TFTP conntrack ipset auth DNSSEC loop-detect inotify
Dec 04 17:49:37 blackred dnsmasq-dhcp[5033]: DHCP, IP range 10.x.x.2 -- 10.x.x.254, lease time infinite
Dec 04 17:49:37 blackred dnsmasq-dhcp[5033]: DHCP, sockets bound exclusively to interface>
Dec 04 17:49:37 blackred dnsmasq[5033]: reading /etc/resolv.conf
Dec 04 17:49:37 blackred dnsmasq[5033]: using nameserver x.x.x.x#53
Dec 04 17:49:37 blackred dnsmasq[5033]: using nameserver x.x.x.x#53
Dec 04 17:49:37 blackred dnsmasq[5033]: using nameserver fe80::1%wlp3s0#53
Dec 04 17:49:37 blackred dnsmasq[5033]: read /etc/hosts - 2 addresses
Dec 04 17:49:37 blackred dnsmasq[5033]: cannot read /var/snap/multipass/common/data/multipassd/network/dnsmasq.hosts: No such file or directory
Dec 04 17:49:37 blackred multipass.multipassd[4730]: E1204 17:49:37.662490010    4730     uri_parser.cc:46]           bad uri.scheme: ''
Dec 04 17:49:37 blackred multipass.multipassd[4730]: E1204 17:49:37.662587115    4730     uri_parser.cc:52]                            ^ here
Dec 04 17:49:37 blackred multipass.multipassd[4730]: E1204 17:49:37.662603964    4730     http_proxy.cc:54]           cannot parse value of 'http_proxy' env var
Dec 04 17:49:37 blackred multipassd[4730]: gRPC listening on unix:/run/multipass_socket, SSL:on
Dec 04 17:49:37 blackred multipassd[4730]: QIODevice::write (QFile, "/var/snap/multipass/common/cache/multipassd/vault/multipassd-image-records.json"): device not open
Dec 04 17:49:37 blackred multipass.multipassd[4730]: [error] [daemon] Could not determine group id for 'sudo'.
Dec 04 17:49:37 blackred systemd[1]: snap.multipass.multipassd.service: Main process exited, code=exited, status=1/FAILURE
Dec 04 17:49:37 blackred systemd[1]: snap.multipass.multipassd.service: Failed with result 'exit-code'.
Dec 04 17:49:37 blackred systemd[1]: snap.multipass.multipassd.service: Service hold-off time over, scheduling restart.
Dec 04 17:49:37 blackred systemd[1]: snap.multipass.multipassd.service: Scheduled restart job, restart counter is at 39.
Dec 04 17:49:37 blackred systemd[1]: Stopped Service for snap application multipass.multipassd.
Dec 04 17:49:37 blackred systemd[1]: Started Service for snap application multipass.multipassd.

#26

Snapcraft 3.0 is a great step up in terms of usability.
Multipass is a lot easier to configure than lxd.
Will core18 now work on build.snapcraft.io?


#27

Hey @abitrolly , that’s this issue then:

Please add a sudo group (and yourself to it) in the mean time - we’re working on a long-term solution not involving groups at all.


#29

I can run sudo commands. I guess in Fedora the group is named wheel. https://docs.fedoraproject.org/en-US/fedora/f28/system-administrators-guide/basic-system-configuration/Gaining_Privileges/#sect-Gaining_Privileges-The_su_Command

✗ groups
anatoli wheel lxd libvirt docker

#30

I would like to mention that unless stage-snaps is implemented I’m not likely migrate to the new snap building methodology as there’s no replacement for the remote parts.


#31

I am second to ask that, because right now builds with base: core18 fail, because builder still creates LXD container with xenial.

https://launchpadlibrarian.net/400260984/buildlog_snap_ubuntu_xenial_amd64_5e09ade34babaee812c7ae3260da8e9c-xenial_BUILDING.txt.gz


#32

Also, is there an option to ignore multipass because I already run snapcraft in dedicated build container with Ubuntu 18.04?


#33

Use --destructive-mode


#34

Like @abitrolly, I too was using a dedicated multipass 18.04 container for my network-manager 1.10 snap builds (which require core18 base).

I tried --destructive-mode, and while it did build, it doesn’t seem to be work with clean:

ubuntu@bionic:~/dev/nm$ snapcraft --destructive-mode clean
'multipass' command not found: this command is necessary to build in this environment.
Install 'multipass' or if already installed, ensure it is on the system PATH, and try again.
ubuntu@bionic:~/dev/nm$ snapcraft clean --destructive-mode
Error: no such option: --destructive-mode