Environment setup

To be able to access the evroc API you need to log in and setup your environment. The steps required are described in the IAM chapter.

Run API

Get services

$ kubectl get services.run.evroclabs.net -n customer-test
NAME     URL                                                            READY   REASON
jptest   https://run-2afuh6ghzrhf7lp4tgng3npb3e.staging.ev-traffic.eu   True    Ready

Describe a service

$ kubectl describe  services.run.evroclabs.net -n customer-test
Name:         jptest
Namespace:    customer-test
Labels:       <none>
Annotations:  kcp.io/cluster: 23p8iuybcrp7e5n6
API Version:  run.evroclabs.net/v1alpha2
Kind:         Service
Metadata:
  Creation Timestamp:  2024-07-03T10:53:04Z
  Finalizers:
    service.run.evroclabs.net
  Generation:        1
  Resource Version:  22884334
  UID:               1e2a9eda-41b6-4c52-ba64-6eb6570aa35e
Spec:
  Autoscaling:
    Max Latency:  10
  Containers:
    Image:  registry.prod.evroclabs.net/helloworld-go
    Ports:
      Container Port:  80
      Protocol:        TCP
    Resources:
      Limits:
        Cpu:     100m
        Memory:  256Mi
      Requests:
        Cpu:     100m
        Memory:  256Mi
Status:
  Conditions:
    Last Transition Time:  2024-07-03T12:33:31Z
    Message:
    Reason:                ContainerHealthy
    Status:                True
    Type:                  ContainerHealthy
    Last Transition Time:  2024-07-03T12:33:31Z
    Message:
    Reason:                Ready
    Status:                True
    Type:                  Ready
  URL:                     https://run-2afuh6ghzrhf7lp4tgng3npb3e.staging.ev-traffic.eu
Events:                    <none>

Create a service

$ cat svc.yaml
apiVersion: run.evroclabs.net/v1alpha2
kind: Service
metadata:
  name: test
  namespace: customer-test
spec:
  autoscaling:
    maxLatency: 10
  containers:
  - image: registry.prod.evroclabs.net/helloworld-go

$ kubectl apply -f svc.yaml
service.run.evroclabs.net/svc-rhyfrpn3eqk4fuu2 created

Update a service

$ cat svc.yaml
apiVersion: run.evroclabs.net/v1alpha2
kind: Service
metadata:
  name: jptest
  namespace: customer-test
spec:
  autoscaling:
    maxLatency: 12
  containers:
  - image: registry.prod.evroclabs.net/helloworld-go

$ kubectl apply -f svc.yaml
service.run.evroclabs.net/svc-rhyfrpn3eqk4fuu2 configured

Delete a service

$ kubectl delete services -n customer-test test
service.run.evroclabs.net "test" deleted