First I’m very new to developing snaps so I apologize in advance if this is something obvious. I’m trying to deploy a snap which needs the network plug. At first I thought it was working fine until I installed it on a fresh VM (multipass on macOS) and it wouldn’t work giving a networking error. When I ran snap interfaces
I got:
multipass@qavm:~$ snap interfaces
Slot Plug
- teselagen:network
When I ran the same command on my VM I use for testing I get this:
multipass@testvm:~$ snap interfaces
Slot Plug
:account-control -
:accounts-service -
:adb-support -
:alsa -
:autopilot-introspection -
:avahi-control -
:avahi-observe -
:block-devices -
:bluetooth-control -
:bluez -
:broadcom-asic-control -
:browser-support -
:calendar-service -
:camera -
:can-bus -
:cifs-mount -
:classic-support -
:contacts-service -
:core-support -
:cpu-control -
:cups-control -
:daemon-notify -
:dcdbas-control -
:desktop -
:desktop-legacy -
:device-buttons -
:display-control -
:docker-support -
:dvb -
:firewall-control -
:framebuffer -
:fuse-support -
:gpg-keys -
:gpg-public-keys -
:gpio-memory-control -
:greengrass-support -
:gsettings -
:hardware-observe -
:hardware-random-control -
:hardware-random-observe -
:home -
:hostname-control -
:intel-mei -
:io-ports-control -
:joystick -
:juju-client-observe -
:kernel-module-control -
:kernel-module-observe -
:kubernetes-support -
:kvm -
:libvirt -
:locale-control -
:log-observe snappy-debug
:lxd-support -
:modem-manager -
:mount-observe -
:multipass-support -
:netlink-audit -
:netlink-connector -
:network teselagen
:network-bind -
:network-control -
:network-manager -
:network-manager-observe -
:network-observe -
:network-setup-control -
:network-setup-observe -
:ofono -
:opengl -
:openvswitch -
:openvswitch-support -
:optical-drive -
:password-manager-service -
:personal-files -
:physical-memory-control -
:physical-memory-observe -
:ppp -
:process-control -
:pulseaudio -
:raw-usb -
:removable-media -
:screen-inhibit-control -
:screencast-legacy -
:shutdown -
:snapd-control -
:ssh-keys -
:ssh-public-keys -
:system-files -
:system-observe -
:system-trace -
:time-control -
:timeserver-control -
:timezone-control -
:tpm -
:u2f-devices -
:udisks2 -
:uhid -
:unity7 -
:upower-observe -
:wayland -
:x11 -
The only difference between the two VM’s is that on test I have snappy-debug installed. After much trial and error it appears that if I install the “core” snap then the network slot (and all of the other interfaces) appear and my network plug connects properly.
Can I not use core18 as a base if I want to use interfaces? Is there something else I need to do to get core18 to enable the interfaces?
I tried building the snap against core as the base but it fails on my mac for some reason. Most posts I read regarding the error recommend upgrading to core18 but that doesn’t seem to be sufficient in this case.
snapcraft.yml
name: teselagen
version: 0.0.12
summary: TeselaGen CLI Tool
grade: stable
description: |
Print general usage:-
$ teselagen
Print usage for Build module
$ teselagen build
Print usage for utilities
$ teselagen utils
confinement: strict
base: core18
architectures:
- build-on: [amd64]
parts:
teselagen:
# stage-snaps: [core]
source: .
plugin: nodejs
nodejs-version: "10.11.0"
apps:
teselagen:
command: teselagen
plugs: [network]
plugs:
network: