Feat/stackitcli 70 cdn distribution beta cmds 2#1138
Merged
cgoetz-inovex merged 8 commits intofeat/STACKITCLI-70-add-cdn-distribution-beta-cmdsfrom Dec 2, 2025
Conversation
rubenhoenle
reviewed
Dec 1, 2025
| table.AddSeparator() | ||
| table.AddRow("HTTP ORIGIN URL", utils.PtrString(h.OriginUrl)) | ||
| table.AddSeparator() | ||
| table.AddRow("HTTP ORIGIN REQUEST HEADERS", utils.JoinStringMap(*h.OriginRequestHeaders, ": ", ", ")) |
Member
There was a problem hiding this comment.
Potential nil pointer dereference
Member
There was a problem hiding this comment.
if h.OriginRequestHeaders != nil {
table.AddRow("HTTP ORIGIN REQUEST HEADERS", utils.JoinStringMap(*h.OriginRequestHeaders, ": ", ", "))
table.AddSeparator()
}
rubenhoenle
reviewed
Dec 1, 2025
| } else if d.Config.Backend.HttpBackend != nil { | ||
| h := d.Config.Backend.HttpBackend | ||
| var geofencing []string | ||
| for k, v := range *h.Geofencing { |
rubenhoenle
reviewed
Dec 1, 2025
| } | ||
|
|
||
| // JoinStringMap concatenates the key-value pairs of a string map, key and value separated by kvSep, key value pairs separated by sep. | ||
| func JoinStringMap(m map[string]string, kvSep, sep string) string { |
Member
There was a problem hiding this comment.
Could we please have unit tests for this? Also maybe worth to add this to the SDK core utils pkgs instead the CLI utils pkg.
rubenhoenle
reviewed
Dec 1, 2025
| return *s | ||
| } | ||
|
|
||
| func Min[T constraints.Ordered](a, b T) T { |
Member
There was a problem hiding this comment.
Could we please have unit tests for this? Also maybe worth to add this to the SDK core utils pkgs instead the CLI utils pkg.
rubenhoenle
reviewed
Dec 1, 2025
| @@ -0,0 +1 @@ | |||
| package describe | |||
rubenhoenle
reviewed
Dec 1, 2025
| "k8s.io/utils/ptr" | ||
| ) | ||
|
|
||
| var projectIdFlag = globalflags.ProjectIdFlag |
Member
There was a problem hiding this comment.
I don't see the point of duplicating a constant into a variable? Why not just use the constant directly?
Contributor
Author
There was a problem hiding this comment.
me neither, probably copied this from some other place
dbfea3d
into
feat/STACKITCLI-70-add-cdn-distribution-beta-cmds
5 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
add distirbutions describe/delete/create/update
relates to STACKITCLI-70
Checklist
make fmtmake generate-docs(will be checked by CI)make test(will be checked by CI)make lint(will be checked by CI)