Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,11 @@ fetch-rps-openapi:
@# Help: Fetch the OpenDMT RPS OpenAPI spec
curl -sSL https://raw.githubusercontent.com/open-edge-platform/orch-utils/main/tenancy-api-mapping/openapispecs/generated/amc-opendmt-rps-openapi.yaml -o pkg/rest/rps/amc-opendmt-rps-openapi.yaml

fetch-openapi: fetch-catalog-openapi fetch-cluster-openapi fetch-infra-openapi
fetch-utils-openapi:
@# Help: Fetch the Utils API OpenAPI spec
curl -sSL https://raw.githubusercontent.com/open-edge-platform/orch-utils/main/tenancy-api-mapping/openapispecs/generated/orch-utils.tenancy-datamodel.openapi.yaml -o pkg/rest/tenancy/orch-utils.tenancy-datamodel.openapi.yaml

fetch-openapi: fetch-catalog-openapi fetch-cluster-openapi fetch-infra-openapi fetch-rps-openapi fetch-utils-openapi
@# Help: Fetch OpenAPI specs for all components

rest-client-gen:
Expand All @@ -115,6 +119,8 @@ rest-client-gen:
oapi-codegen -generate types -old-config-style -package infra -o pkg/rest/infra/types.go pkg/rest/infra/amc-infra-core-edge-infrastructure-manager-openapi-all.yaml
oapi-codegen -generate client -old-config-style -package rps -o pkg/rest/rps/client.go pkg/rest/rps/amc-opendmt-rps-openapi.yaml
oapi-codegen -generate types -old-config-style -package rps -o pkg/rest/rps/types.go pkg/rest/rps/amc-opendmt-rps-openapi.yaml
oapi-codegen -generate client -old-config-style -package tenancy -o pkg/rest/tenancy/client.go pkg/rest/tenancy/orch-utils.tenancy-datamodel.openapi.yaml
oapi-codegen -generate types -old-config-style -package tenancy -o pkg/rest/tenancy/types.go pkg/rest/tenancy/orch-utils.tenancy-datamodel.openapi.yaml

# Supported mockgen version v0.5.2
# install command: go install go.uber.org/mock/[email protected]
Expand All @@ -126,6 +132,7 @@ mock-client-gen:
mockgen -source=pkg/rest/cluster/client.go -destination=pkg/rest/cluster/mock_client.go -package=cluster
mockgen -source=pkg/rest/infra/client.go -destination=pkg/rest/infra/mock_client.go -package=infra
mockgen -source=pkg/rest/rps/client.go -destination=pkg/rest/rps/mock_client.go -package=rps
mockgen -source=pkg/rest/tenancy/client.go -destination=pkg/rest/tenancy/mock_client.go -package=tenancy

cli-docs:
@# Help: Generates markdowns for the orchestrator cli
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.12.16
0.12.17
41 changes: 41 additions & 0 deletions docs/cli/orch-cli_create_organization.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
## orch-cli create organization

Creates a organization

```
orch-cli create organization [flags]
```

### Examples

```
# Create a organization with a given name
orch-cli create organization myorganization

# Create a organization with a given name and description
orch-cli create organization myorganization --description "my description"

```

### Options

```
-d, --description string Optional flag used to provide a description to a cloud init config resource
-h, --help help for organization
```

### Options inherited from parent commands

```
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
--debug-headers emit debug-style headers separating columns via '|' character
-n, --noauth use without authentication checks
-p, --project string Active project name (default "itep")
-v, --verbose produce verbose output
```

### SEE ALSO

* [orch-cli create](orch-cli_create.md) - Create various orchestrator service entities

###### Auto generated by spf13/cobra on 30-Oct-2025
41 changes: 41 additions & 0 deletions docs/cli/orch-cli_create_project.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
## orch-cli create project

Creates a project

```
orch-cli create project [flags]
```

### Examples

```
# Create a project with a given name
orch-cli create project myproject

# Create a project with a given name and description
orch-cli create project myproject --description "my description"

```

### Options

```
-d, --description string Optional flag used to provide a description to a cloud init config resource
-h, --help help for project
```

### Options inherited from parent commands

```
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
--debug-headers emit debug-style headers separating columns via '|' character
-n, --noauth use without authentication checks
-p, --project string Active project name (default "itep")
-v, --verbose produce verbose output
```

### SEE ALSO

* [orch-cli create](orch-cli_create.md) - Create various orchestrator service entities

###### Auto generated by spf13/cobra on 30-Oct-2025
36 changes: 36 additions & 0 deletions docs/cli/orch-cli_delete_organization.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
## orch-cli delete organization

Delete a organization

```
orch-cli delete organization <name> [flags]
```

### Examples

```
#Delete a organization using it's name
orch-cli delete organization myorganization
```

### Options

```
-h, --help help for organization
```

### Options inherited from parent commands

```
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
--debug-headers emit debug-style headers separating columns via '|' character
-n, --noauth use without authentication checks
-p, --project string Active project name (default "itep")
-v, --verbose produce verbose output
```

### SEE ALSO

* [orch-cli delete](orch-cli_delete.md) - Delete various orchestrator service entities

###### Auto generated by spf13/cobra on 30-Oct-2025
36 changes: 36 additions & 0 deletions docs/cli/orch-cli_delete_project.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
## orch-cli delete project

Delete a project

```
orch-cli delete project <name> [flags]
```

### Examples

```
#Delete a project using it's name
orch-cli delete project myproject
```

### Options

```
-h, --help help for project
```

### Options inherited from parent commands

```
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
--debug-headers emit debug-style headers separating columns via '|' character
-n, --noauth use without authentication checks
-p, --project string Active project name (default "itep")
-v, --verbose produce verbose output
```

### SEE ALSO

* [orch-cli delete](orch-cli_delete.md) - Delete various orchestrator service entities

###### Auto generated by spf13/cobra on 30-Oct-2025
37 changes: 37 additions & 0 deletions docs/cli/orch-cli_get_organization.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
## orch-cli get organization

Get a organization

```
orch-cli get organization <name> [flags]
```

### Examples

```
# Get detailed information about specific organization
orch-cli get organization myorganization

```

### Options

```
-h, --help help for organization
```

### Options inherited from parent commands

```
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
--debug-headers emit debug-style headers separating columns via '|' character
-n, --noauth use without authentication checks
-p, --project string Active project name (default "itep")
-v, --verbose produce verbose output
```

### SEE ALSO

* [orch-cli get](orch-cli_get.md) - Get various orchestrator service entities

###### Auto generated by spf13/cobra on 30-Oct-2025
37 changes: 37 additions & 0 deletions docs/cli/orch-cli_get_project.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
## orch-cli get project

Get a project

```
orch-cli get project <name> [flags]
```

### Examples

```
# Get detailed information about specific project
orch-cli get project myproject

```

### Options

```
-h, --help help for project
```

### Options inherited from parent commands

```
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
--debug-headers emit debug-style headers separating columns via '|' character
-n, --noauth use without authentication checks
-p, --project string Active project name (default "itep")
-v, --verbose produce verbose output
```

### SEE ALSO

* [orch-cli get](orch-cli_get.md) - Get various orchestrator service entities

###### Auto generated by spf13/cobra on 30-Oct-2025
37 changes: 37 additions & 0 deletions docs/cli/orch-cli_list_organization.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
## orch-cli list organization

List all organizations

```
orch-cli list organization [flags]
```

### Examples

```
# List all organizations in the organization
orch-cli list organizations

```

### Options

```
-h, --help help for organization
```

### Options inherited from parent commands

```
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
--debug-headers emit debug-style headers separating columns via '|' character
-n, --noauth use without authentication checks
-p, --project string Active project name (default "itep")
-v, --verbose produce verbose output
```

### SEE ALSO

* [orch-cli list](orch-cli_list.md) - List various orchestrator service entities

###### Auto generated by spf13/cobra on 30-Oct-2025
37 changes: 37 additions & 0 deletions docs/cli/orch-cli_list_project.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
## orch-cli list project

List all projects

```
orch-cli list project [flags]
```

### Examples

```
# List all projects in the organization
orch-cli list projects

```

### Options

```
-h, --help help for project
```

### Options inherited from parent commands

```
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
--debug-headers emit debug-style headers separating columns via '|' character
-n, --noauth use without authentication checks
-p, --project string Active project name (default "itep")
-v, --verbose produce verbose output
```

### SEE ALSO

* [orch-cli list](orch-cli_list.md) - List various orchestrator service entities

###### Auto generated by spf13/cobra on 30-Oct-2025
5 changes: 5 additions & 0 deletions internal/cli/cli_suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ import (
deploymentmock "github.com/open-edge-platform/cli/internal/cli/mocks/deployment"
inframock "github.com/open-edge-platform/cli/internal/cli/mocks/infra"
rpsmock "github.com/open-edge-platform/cli/internal/cli/mocks/rps"
tenancymock "github.com/open-edge-platform/cli/internal/cli/mocks/tenancy"

"github.com/open-edge-platform/cli/pkg/auth"
"github.com/spf13/viper"
Expand Down Expand Up @@ -67,6 +68,7 @@ func (s *CLITestSuite) SetupSuite() {
ClusterFactory = clustermock.CreateClusterMock(mctrl)
RpsFactory = rpsmock.CreateRpsMock(mctrl)
DeploymentFactory = deploymentmock.CreateDeploymentMock(mctrl)
TenancyFactory = tenancymock.CreateTenancyMock(mctrl)

//Mock server for network tests - TODO rework network
s.testServer = httptest.NewTLSServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
Expand Down Expand Up @@ -98,6 +100,9 @@ func (s *CLITestSuite) TearDownSuite() {
InfraFactory = nil
ClusterFactory = nil
RpsFactory = nil
DeploymentFactory = nil
TenancyFactory = nil

viper.Set(auth.UserName, "")
viper.Set(auth.RefreshTokenField, "")
viper.Set(auth.ClientIDField, "")
Expand Down
Loading
Loading