Skip to content

Support wildcard stack for command pack buildpack package #1379

@fg-j

Description

@fg-j

Summary

When attempting to use pack buildpack package to package a composite buildpack that contains a buildpack whose [[stacks]] only contains one entry -- id = '*' and a buildpack that contains non-wildcard stacks, packaging fails with a stack incompatibility error

ERROR: no compatible stacks among provided buildpacks

despite the buildpacks actually being compatible.


Reproduction

Steps
  1. Clone my fork of the buildpacks samples repo and checkout the package-repro branch

  2. Using pack v0.24, run

 pack buildpack package my-buildpack --config ./package.toml
Current behavior

Packaging step fails with:

ERROR: saving image: no compatible stacks among provided buildpacks
Expected behavior

Expected packaging to succeed because the git buildpack specifies stack wildcard
and since * is an allowed stack id.


Environment

pack info
 pack report
Pack:
  Version:  0.24.0+git-79a40b7.build-3148
  OS/Arch:  darwin/amd64

Default Lifecycle Version:  0.13.3

Supported Platform APIs:  0.3, 0.4, 0.5, 0.6, 0.7, 0.8

Config:
  default-builder-image = "[REDACTED]"
  experimental = true

  [[trusted-builders]]
    name = "[REDACTED]"
docker info
docker info
Client:
 Context:    default
 Debug Mode: false
 Plugins:
  buildx: Docker Buildx (Docker Inc., v0.7.1)
  compose: Docker Compose (Docker Inc., v2.2.3)
  scan: Docker Scan (Docker Inc., v0.17.0)

Server:
 Containers: 4
  Running: 0
  Paused: 0
  Stopped: 4
 Images: 50
 Server Version: 20.10.12
 Storage Driver: overlay2
  Backing Filesystem: extfs
  Supports d_type: true
  Native Overlay Diff: true
  userxattr: false
 Logging Driver: json-file
 Cgroup Driver: cgroupfs
 Cgroup Version: 2
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
 Swarm: inactive
 Runtimes: io.containerd.runc.v2 io.containerd.runtime.v1.linux runc
 Default Runtime: runc
 Init Binary: docker-init
 containerd version: 7b11cfaabd73bb80907dd23182b9347b4245eb5d
 runc version: v1.0.2-0-g52b36a2
 init version: de40ad0
 Security Options:
  seccomp
   Profile: default
  cgroupns
 Kernel Version: 5.10.76-linuxkit
 Operating System: Docker Desktop
 OSType: linux
 Architecture: x86_64
 CPUs: 6
 Total Memory: 1.939GiB
 Name: docker-desktop
 ID: R35P:PIQ5:I7KO:2RSM:Y42L:OKP2:FUI4:PGQN:WGD4:YMJL:B55D:ND7S
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 HTTP Proxy: http.docker.internal:3128
 HTTPS Proxy: http.docker.internal:3128
 No Proxy: hubproxy.docker.internal
 Registry: https://index.docker.io/v1/
 Labels:
 Experimental: false
 Insecure Registries:
  hubproxy.docker.internal:5000
  127.0.0.0/8
 Live Restore Enabled: false

Metadata

Metadata

Assignees

No one assigned

    Labels

    good first issueA good first issue to get started with.status/readyIssue ready to be worked on.type/enhancementIssue that requests a new feature or improvement.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions