Skip to content

Commit eb07bef

Browse files
authored
Feat: Org and project management (#181)
1 parent 87baf29 commit eb07bef

23 files changed

+5395
-2
lines changed

Makefile

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,11 @@ fetch-rps-openapi:
9898
@# Help: Fetch the OpenDMT RPS OpenAPI spec
9999
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
100100

101-
fetch-openapi: fetch-catalog-openapi fetch-cluster-openapi fetch-infra-openapi
101+
fetch-utils-openapi:
102+
@# Help: Fetch the Utils API OpenAPI spec
103+
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
104+
105+
fetch-openapi: fetch-catalog-openapi fetch-cluster-openapi fetch-infra-openapi fetch-rps-openapi fetch-utils-openapi
102106
@# Help: Fetch OpenAPI specs for all components
103107

104108
rest-client-gen:
@@ -115,6 +119,8 @@ rest-client-gen:
115119
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
116120
oapi-codegen -generate client -old-config-style -package rps -o pkg/rest/rps/client.go pkg/rest/rps/amc-opendmt-rps-openapi.yaml
117121
oapi-codegen -generate types -old-config-style -package rps -o pkg/rest/rps/types.go pkg/rest/rps/amc-opendmt-rps-openapi.yaml
122+
oapi-codegen -generate client -old-config-style -package tenancy -o pkg/rest/tenancy/client.go pkg/rest/tenancy/orch-utils.tenancy-datamodel.openapi.yaml
123+
oapi-codegen -generate types -old-config-style -package tenancy -o pkg/rest/tenancy/types.go pkg/rest/tenancy/orch-utils.tenancy-datamodel.openapi.yaml
118124

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

130137
cli-docs:
131138
@# Help: Generates markdowns for the orchestrator cli

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.12.16
1+
0.12.17
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
## orch-cli create organization
2+
3+
Creates a organization
4+
5+
```
6+
orch-cli create organization [flags]
7+
```
8+
9+
### Examples
10+
11+
```
12+
# Create a organization with a given name
13+
orch-cli create organization myorganization
14+
15+
# Create a organization with a given name and description
16+
orch-cli create organization myorganization --description "my description"
17+
18+
```
19+
20+
### Options
21+
22+
```
23+
-d, --description string Optional flag used to provide a description to a cloud init config resource
24+
-h, --help help for organization
25+
```
26+
27+
### Options inherited from parent commands
28+
29+
```
30+
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
31+
--debug-headers emit debug-style headers separating columns via '|' character
32+
-n, --noauth use without authentication checks
33+
-p, --project string Active project name (default "itep")
34+
-v, --verbose produce verbose output
35+
```
36+
37+
### SEE ALSO
38+
39+
* [orch-cli create](orch-cli_create.md) - Create various orchestrator service entities
40+
41+
###### Auto generated by spf13/cobra on 30-Oct-2025
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
## orch-cli create project
2+
3+
Creates a project
4+
5+
```
6+
orch-cli create project [flags]
7+
```
8+
9+
### Examples
10+
11+
```
12+
# Create a project with a given name
13+
orch-cli create project myproject
14+
15+
# Create a project with a given name and description
16+
orch-cli create project myproject --description "my description"
17+
18+
```
19+
20+
### Options
21+
22+
```
23+
-d, --description string Optional flag used to provide a description to a cloud init config resource
24+
-h, --help help for project
25+
```
26+
27+
### Options inherited from parent commands
28+
29+
```
30+
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
31+
--debug-headers emit debug-style headers separating columns via '|' character
32+
-n, --noauth use without authentication checks
33+
-p, --project string Active project name (default "itep")
34+
-v, --verbose produce verbose output
35+
```
36+
37+
### SEE ALSO
38+
39+
* [orch-cli create](orch-cli_create.md) - Create various orchestrator service entities
40+
41+
###### Auto generated by spf13/cobra on 30-Oct-2025
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
## orch-cli delete organization
2+
3+
Delete a organization
4+
5+
```
6+
orch-cli delete organization <name> [flags]
7+
```
8+
9+
### Examples
10+
11+
```
12+
#Delete a organization using it's name
13+
orch-cli delete organization myorganization
14+
```
15+
16+
### Options
17+
18+
```
19+
-h, --help help for organization
20+
```
21+
22+
### Options inherited from parent commands
23+
24+
```
25+
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
26+
--debug-headers emit debug-style headers separating columns via '|' character
27+
-n, --noauth use without authentication checks
28+
-p, --project string Active project name (default "itep")
29+
-v, --verbose produce verbose output
30+
```
31+
32+
### SEE ALSO
33+
34+
* [orch-cli delete](orch-cli_delete.md) - Delete various orchestrator service entities
35+
36+
###### Auto generated by spf13/cobra on 30-Oct-2025
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
## orch-cli delete project
2+
3+
Delete a project
4+
5+
```
6+
orch-cli delete project <name> [flags]
7+
```
8+
9+
### Examples
10+
11+
```
12+
#Delete a project using it's name
13+
orch-cli delete project myproject
14+
```
15+
16+
### Options
17+
18+
```
19+
-h, --help help for project
20+
```
21+
22+
### Options inherited from parent commands
23+
24+
```
25+
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
26+
--debug-headers emit debug-style headers separating columns via '|' character
27+
-n, --noauth use without authentication checks
28+
-p, --project string Active project name (default "itep")
29+
-v, --verbose produce verbose output
30+
```
31+
32+
### SEE ALSO
33+
34+
* [orch-cli delete](orch-cli_delete.md) - Delete various orchestrator service entities
35+
36+
###### Auto generated by spf13/cobra on 30-Oct-2025
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
## orch-cli get organization
2+
3+
Get a organization
4+
5+
```
6+
orch-cli get organization <name> [flags]
7+
```
8+
9+
### Examples
10+
11+
```
12+
# Get detailed information about specific organization
13+
orch-cli get organization myorganization
14+
15+
```
16+
17+
### Options
18+
19+
```
20+
-h, --help help for organization
21+
```
22+
23+
### Options inherited from parent commands
24+
25+
```
26+
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
27+
--debug-headers emit debug-style headers separating columns via '|' character
28+
-n, --noauth use without authentication checks
29+
-p, --project string Active project name (default "itep")
30+
-v, --verbose produce verbose output
31+
```
32+
33+
### SEE ALSO
34+
35+
* [orch-cli get](orch-cli_get.md) - Get various orchestrator service entities
36+
37+
###### Auto generated by spf13/cobra on 30-Oct-2025

docs/cli/orch-cli_get_project.md

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
## orch-cli get project
2+
3+
Get a project
4+
5+
```
6+
orch-cli get project <name> [flags]
7+
```
8+
9+
### Examples
10+
11+
```
12+
# Get detailed information about specific project
13+
orch-cli get project myproject
14+
15+
```
16+
17+
### Options
18+
19+
```
20+
-h, --help help for project
21+
```
22+
23+
### Options inherited from parent commands
24+
25+
```
26+
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
27+
--debug-headers emit debug-style headers separating columns via '|' character
28+
-n, --noauth use without authentication checks
29+
-p, --project string Active project name (default "itep")
30+
-v, --verbose produce verbose output
31+
```
32+
33+
### SEE ALSO
34+
35+
* [orch-cli get](orch-cli_get.md) - Get various orchestrator service entities
36+
37+
###### Auto generated by spf13/cobra on 30-Oct-2025
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
## orch-cli list organization
2+
3+
List all organizations
4+
5+
```
6+
orch-cli list organization [flags]
7+
```
8+
9+
### Examples
10+
11+
```
12+
# List all organizations in the organization
13+
orch-cli list organizations
14+
15+
```
16+
17+
### Options
18+
19+
```
20+
-h, --help help for organization
21+
```
22+
23+
### Options inherited from parent commands
24+
25+
```
26+
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
27+
--debug-headers emit debug-style headers separating columns via '|' character
28+
-n, --noauth use without authentication checks
29+
-p, --project string Active project name (default "itep")
30+
-v, --verbose produce verbose output
31+
```
32+
33+
### SEE ALSO
34+
35+
* [orch-cli list](orch-cli_list.md) - List various orchestrator service entities
36+
37+
###### Auto generated by spf13/cobra on 30-Oct-2025

docs/cli/orch-cli_list_project.md

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
## orch-cli list project
2+
3+
List all projects
4+
5+
```
6+
orch-cli list project [flags]
7+
```
8+
9+
### Examples
10+
11+
```
12+
# List all projects in the organization
13+
orch-cli list projects
14+
15+
```
16+
17+
### Options
18+
19+
```
20+
-h, --help help for project
21+
```
22+
23+
### Options inherited from parent commands
24+
25+
```
26+
--api-endpoint string API Service Endpoint (default "https://api.orch-10-114-181-120.espdqa.infra-host.com")
27+
--debug-headers emit debug-style headers separating columns via '|' character
28+
-n, --noauth use without authentication checks
29+
-p, --project string Active project name (default "itep")
30+
-v, --verbose produce verbose output
31+
```
32+
33+
### SEE ALSO
34+
35+
* [orch-cli list](orch-cli_list.md) - List various orchestrator service entities
36+
37+
###### Auto generated by spf13/cobra on 30-Oct-2025

0 commit comments

Comments
 (0)