#Create Dagger Service In Function

1 messages · Page 1 of 1 (latest)

umbral zephyr
#

Hey Guys,

I have a dagger pipeline that does the following:

  • Creates a container and pushes
  • Uses a helm chart to deploy a set of local dependencies (with resource constraints)
  • Deploys the app to kube

The bit that i need to do here is then check the service is up, that we can connect to the app before running the test against that host.

What I believe I need to do is create a ServiceBinding to allow for communication between dagger and the destination. What I dont know how to do is create a dagger.Service in code i.e.

testContainer..WithServiceBinding("", dagger.Service{
        endpoint: "something.svc:8080"
    })

Obvs doesn't work, as endpoint isn't exported. Has anyone done this or can tell me how please?

clever sparrow