cloudfoundry / korifi

Cloud Foundry on Kubernetes
Apache License 2.0
314 stars 61 forks source link

[Feature]: Specifying an unsupported stack errors #1158

Open matt-royal opened 2 years ago

matt-royal commented 2 years ago

Blockers/Dependencies

1054

Background

As a cf CLI user I want to receive an error message when I select a stack other than io.buildpacks.stacks.bionic (or whatever the current supported stack is) So that I understand that I cannot build images based on that stack (right now we silently ignore the requested stack)

Acceptance Criteria

GIVEN a korifi cluster WHEN I run cf push -s no-such-stack THEN I should see that the build fails with an error explaining that no stack with that name exists


WHEN I run cf push -s io.buildpacks.stacks.bionic or cf push THEN I should see that the build succeeds AND that cf app <AppName> shows stack io.buildpacks.stacks.bionic

Dev Notes

This story spans korifi/api, korifi/controllers, and korifi/kpack-image-builder.

When a stack is specified to cf push, the manifest will look like this:

applications:
- name: my-app
  # ...
  stack: stack
matt-royal commented 2 years ago

I'm writing this story for an interview this week. It hasn't been IPMed, and we may choose not to merge the result.