Skip to content
This repository has been archived by the owner on Nov 3, 2021. It is now read-only.

Introduce "cf_on_k8s": true into the / response #91

Merged
merged 1 commit into from
Sep 29, 2021
Merged

Conversation

danail-branekov
Copy link
Member

Is there a related GitHub Issue?

#10

What is this change about?

Introduce a cf_on_k8s property into the GET / response which is always true in CF-on-K8S API. This property will be processed by the CLI to figure out that it is talking to CF-on-K8s rather than CF-on-VMs. See eirini-forks/cli#1 for details.

The change is compatible with the CF-on-VMs CC API as the absence of that field defaults to false on the CLI side, i.e. CLI would know that it talks to CF-on-VMs without actually changing the CC API there.

Does this PR introduce a breaking change?

No

Acceptance Steps

  1. Start the API
  2. curl localhost:9000
  3. See "cf_on_k8s": true in the response body

Tag your pair

@georgethebeatle

apis/root_handler_test.go Show resolved Hide resolved
apis/root_handler.go Outdated Show resolved Hide resolved
Copy link
Member

@tcdowney tcdowney left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM once Birdrock's concerns are addressed and conflicts are resolved. 👍

Also introduce root response presenter and response type

Issue: #10

Co-authored-by: Georgi Sabev <georgethebeatle@gmail.com>
@Birdrock Birdrock merged commit 9d319a8 into main Sep 29, 2021
@Birdrock Birdrock deleted the cf-on-k8s-info branch September 29, 2021 20:45
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants