misleading warning when building base: core18 snap with 16.04 snapcore/snapcraft docker
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Snapcraft |
New
|
Undecided
|
Unassigned |
Bug Description
Following https:/
Snapcraft gives a very misleading warning about core18 being missing but needed when building in a 16.04 Docker. It goes on to say that the environment should, vaguely, be "properly set up" and in the very next breath says you can dismiss the warning if, again vaguely, "appropriate measures have been taken."
Shouldn't this just error out with "The specified base and Docker image do not match. Use an Ubuntu 18.04-based Docker image to match 'base: core18' in your snap/snapcraft.
~/example❯ cat snap/snapcraft.yaml
name: my-snap-name # you probably want to 'snapcraft register <name>'
base: core18 # the base snap is the execution environment for this snap
version: '0.1' # just for humans, typically '1.2+git' or '1.3.2'
summary: Single-line elevator pitch for your amazing snap # 79 char long summary
description: |
This is my-snap's description. You have a paragraph or two to tell the
most important story about your snap. Keep it under 100 words though,
we live in tweetspace and your description wants to look good in the snap
store.
grade: devel # must be 'stable' to release into candidate/stable channels
confinement: devmode # use 'strict' once you have the right plugs and slots
parts:
my-part:
# See 'snapcraft plugins'
plugin: nil
~/example❯ docker run -v $(pwd):$(pwd) -w $(pwd) snapcore/
Locale not set! Snapcraft will temporarily use C.UTF-8
Using 'snap/snapcraft
The following snaps are required but not installed as snapcraft is running inside docker: core18.
Please ensure the environment is properly setup before continuing.
Ignore this message if the appropriate measures have already been taken
Pulling my-part
Building my-part
Staging my-part
Priming my-part
Snapping 'my-snap-name' ...
Snapped my-snap-
~/example❯ docker run -v $(pwd):$(pwd) -w $(pwd) snapcore/
DISTRIB_ID=Ubuntu
DISTRIB_
DISTRIB_
DISTRIB_