Ingress
Bases: DuploTenantResourceV3
apply
Apply a Ingress
Create or Update a Ingress resource with Duplocloud cli.
CLI Usage
Contents of theingress.yaml
file
labels: null
annotations: null
lbConfig:
listeners:
https:
- 443
http:
- 80
dnsPrefix: "duploctl"
isPublic: true
certArn:
rules:
- path: "/"
pathType: "Prefix"
serviceName: "nginx"
port: 80
host: "duploctl-nginx.duplocloud.net"
portName: null
name: "duploctl"
ingressClassName: "alb"
otherSpecs:
tls: []
Parameters:
Name | Type | Description | Default |
---|---|---|---|
body
|
BODY
|
The resource to apply. |
required |
wait
|
WAIT
|
Wait for the resource to be created. |
False
|
patches
|
PATCHES
|
The patches to apply to the resource. |
None
|
Returns:
Name | Type | Description |
---|---|---|
message |
dict
|
Success message. |
create
Create an Ingress. Usage: CLI Usage
Contents of theingress.yaml
file
labels: null
annotations: null
lbConfig:
listeners:
https:
- 443
http:
- 80
dnsPrefix: "duploctl"
isPublic: true
certArn:
rules:
- path: "/"
pathType: "Prefix"
serviceName: "nginx"
port: 80
host: "duploctl-nginx.duplocloud.net"
portName: null
name: "duploctl"
ingressClassName: "alb"
otherSpecs:
tls: []
echo """
labels: null
annotations: null
lbConfig:
listeners:
https:
- 443
http:
- 80
dnsPrefix: "duploctl"
isPublic: true
certArn:
rules:
- path: "/"
pathType: "Prefix"
serviceName: "nginx"
port: 80
host: "duploctl-nginx.duplocloud.net"
portName: null
name: "duploctl"
ingressClassName: "alb"
otherSpecs:
tls: []
""" | duploctl ingress create -f -
delete
Delete a Ingress resource by name.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
name
|
NAME
|
The name of the Ingress resource to delete. |
required |
Returns:
Name | Type | Description |
---|---|---|
message |
dict
|
A success message. |
Raises:
Type | Description |
---|---|
DuploError
|
If the {{kind}} resource could not be found or deleted. |
find
Find Ingress resources by name.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
name
|
NAME
|
The name of the Ingress resource to find. |
required |
Returns:
Name | Type | Description |
---|---|---|
resource |
dict
|
The Ingress object. |
Raises:
Type | Description |
---|---|
DuploError
|
If the {{kind}} could not be found. |
list
update
Update an Ingress. Usage: CLI Usage
Contents of theingress.yaml
file
labels: null
annotations: null
lbConfig:
listeners:
https:
- 443
http:
- 80
dnsPrefix: "duploctl"
isPublic: true
certArn:
rules:
- path: "/"
pathType: "Prefix"
serviceName: "nginx"
port: 80
host: "duploctl-nginx.duplocloud.net"
portName: null
name: "duploctl"
ingressClassName: "alb"
otherSpecs:
tls: []
echo """
labels: null
annotations: null
lbConfig:
listeners:
https:
- 443
http:
- 80
dnsPrefix: "duploctl"
isPublic: true
certArn:
rules:
- path: "/"
pathType: "Prefix"
serviceName: "nginx"
port: 80
host: "duploctl-nginx.duplocloud.net"
portName: null
name: "duploctl"
ingressClassName: "alb"
otherSpecs:
tls: []
""" | duploctl ingress update -f -