scottdware/go-bigip

Attach iRule to Virtual server

Opened this issue · 2 comments

Is it possible to attach an iRule to virtual server with your API ?

@Menta2L Yes!

You would have to add the iRules using the AddVirtualServer method and build the structure yourself.
So

// Adds VirtualServer with iRules
config := &bigip.VirtualServer{
	Name:      "someVSname",
	Partition: "Common",
	Rules: []string{
		"/Common/Rule1",
		"/Common/Rule2",
	},
}
f5.AddVirtualServer(config)

I believe that should work.
@scottdware

You are right, @kenmaglio