Skip to content

Commit

Permalink
feat(docs): add generated openapi docs (#7975)
Browse files Browse the repository at this point in the history
Use all openapis in the repo to generate a complete
1 file version in `docs/generated/openapi.yaml`

Part of #318
Signed-off-by: Charly Molter <[email protected]>
  • Loading branch information
lahabana authored Oct 10, 2023
1 parent 64641a0 commit 65a5e0c
Show file tree
Hide file tree
Showing 20 changed files with 6,758 additions and 734 deletions.
59 changes: 30 additions & 29 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,13 +125,27 @@ commands:
echo "PR doesn't have label <<parameters.label>> keep running job"
exit 0
executors:
golang:
golang-amd64:
resource_class: xlarge
docker:
- image: "cimg/go:<< pipeline.parameters.go_version >>"
environment:
KUMA_DIR: .
GO_VERSION: << pipeline.parameters.go_version >>
golang-arm64:
resource_class: arm.xlarge
docker:
- image: "cimg/go:<< pipeline.parameters.go_version >>"
environment:
KUMA_DIR: .
GO_VERSION: << pipeline.parameters.go_version >>
vm-xlarge-amd64:
resource_class: xlarge
machine:
image: << pipeline.parameters.ubuntu_image >>
environment:
KUMA_DIR: .
GO_VERSION: << pipeline.parameters.go_version >>
vm-amd64:
resource_class: large
machine:
Expand All @@ -148,34 +162,24 @@ executors:
GO_VERSION: << pipeline.parameters.go_version >>
jobs:
go_cache:
executor: << parameters.executor >>
executor: golang-<< parameters.arch >>
parameters:
executor:
arch:
description: the executor to run on
type: string
default: golang
steps:
- when:
condition: {equal: [vm-amd64, << parameters.executor >>]}
steps:
- install_build_tools:
go_arch: amd64
- when:
condition: {equal: [vm-arm64, << parameters.executor >>]}
steps:
- install_build_tools:
go_arch: arm64
- checkout
- restore_cache:
key: << parameters.executor >>_go.mod_{{ checksum "go.sum" }}_{{ checksum "mk/dependencies/deps.lock" }}_{{ checksum ".circleci/config.yml" }}
key: vm-<< parameters.arch >>_go.mod_{{ checksum "go.sum" }}_{{ checksum "mk/dependencies/deps.lock" }}_{{ checksum ".circleci/config.yml" }}
- run:
command: make dev/tools
- run:
name: "Download Go modules"
command: |
go mod download -x
- save_cache:
key: << parameters.executor >>_go.mod_{{ checksum "go.sum" }}_{{ checksum "mk/dependencies/deps.lock" }}_{{ checksum ".circleci/config.yml" }}
key: vm-<< parameters.arch >>_go.mod_{{ checksum "go.sum" }}_{{ checksum "mk/dependencies/deps.lock" }}_{{ checksum ".circleci/config.yml" }}
paths:
- "/home/circleci/go/pkg/mod"
- "/home/circleci/.kuma-dev"
Expand Down Expand Up @@ -353,19 +357,16 @@ jobs:
name: "Store logs"
path: /tmp/e2e
build:
executor:
name: golang
executor: vm-xlarge-amd64
steps:
- install_build_tools
- checkout
- setup_remote_docker
- run:
command: ssh remote-docker "sudo apt-get update; sudo apt-get install -y qemu-user-static binfmt-support"
- setenv_depending_on_priority:
label: "ci/run-full-matrix"
env: ENABLED_GOARCHES="arm64 amd64" ENABLED_GOOSES="linux darwin"
- restore_cache:
keys:
- docker_go.mod_{{ checksum "go.sum" }}_{{ checksum "mk/dependencies/deps.lock" }}_{{ checksum ".circleci/config.yml" }}
- build_go.mod_{{ checksum "go.sum" }}_{{ checksum "mk/dependencies/deps.lock" }}_{{ checksum ".circleci/config.yml" }}
- run:
command: make dev/tools
- run:
Expand All @@ -381,7 +382,7 @@ jobs:
- run:
command: make -j docker/save
- save_cache:
key: docker_go.mod_{{ checksum "go.sum" }}_{{ checksum "mk/dependencies/deps.lock" }}_{{ checksum ".circleci/config.yml" }}
key: build_go.mod_{{ checksum "go.sum" }}_{{ checksum "mk/dependencies/deps.lock" }}_{{ checksum ".circleci/config.yml" }}
paths:
- "/home/circleci/go/pkg/mod"
- "/home/circleci/.kuma-dev"
Expand Down Expand Up @@ -455,11 +456,11 @@ workflows:
kuma-commit:
jobs:
- go_cache:
name: go_cache-<< matrix.executor >>
name: go_cache-<< matrix.arch >>
matrix:
alias: go_cache
parameters:
executor: [vm-amd64, vm-arm64]
arch: [amd64, arm64]
- build:
name: build
- test:
Expand All @@ -468,7 +469,7 @@ workflows:
alias: test
parameters:
arch: [amd64, arm64]
requires: [build, go_cache-vm-<< matrix.arch >>]
requires: [build, go_cache-<< matrix.arch >>]
- e2e:
name: legacy-k8s:<< matrix.arch >>-<< matrix.k8sVersion >>
matrix:
Expand All @@ -478,7 +479,7 @@ workflows:
arch: [amd64, arm64]
parallelism: 3
target: ""
requires: [build, go_cache-vm-<< matrix.arch >>]
requires: [build, go_cache-<< matrix.arch >>]
- e2e:
name: << matrix.target >>:<< matrix.arch >>-<< matrix.k8sVersion >>
matrix:
Expand All @@ -487,7 +488,7 @@ workflows:
k8sVersion: [<< pipeline.parameters.first_k8s_version >>, << pipeline.parameters.last_k8s_version >>, kind, kindIpv6]
target: [kubernetes, universal, multizone]
arch: [amd64, arm64]
requires: [build, go_cache-vm-<< matrix.arch >>]
requires: [build, go_cache-<< matrix.arch >>]
- e2e:
name: << matrix.target >>:<< matrix.arch >>-<< matrix.k8sVersion >>-delta-kds
matrix:
Expand All @@ -497,7 +498,7 @@ workflows:
target: [multizone]
arch: [amd64]
deltaKDS: [true]
requires: [build, go_cache-vm-amd64]
requires: [build, go_cache-amd64]
- e2e:
name: << matrix.target >>:<< matrix.arch >>-<< matrix.k8sVersion >>-calico
matrix:
Expand All @@ -507,7 +508,7 @@ workflows:
target: [multizone]
arch: [amd64]
cniNetworkPlugin: [calico]
requires: [build, go_cache-vm-amd64]
requires: [build, go_cache-amd64]
- container-structure:
name: container-structure
requires: [build]
Expand Down
3 changes: 2 additions & 1 deletion api/openapi/specs/global_insight.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ paths:
/global-insight:
get:
summary: Get Global Insight
tags: ["GlobalInsight"]
responses:
'200':
$ref: '#/components/responses/GlobalInsightResponse'
Expand Down Expand Up @@ -232,4 +233,4 @@ components:
policies:
total: 100
meshes:
total: 3
total: 3
Loading

0 comments on commit 65a5e0c

Please sign in to comment.