func (c *Connect) Exchange(options *options.DaemonOptions, origin *v1.Deployment, clientset *kubernetes.Clientset, labels map[string]string) (workload string, err error) {
	workload = origin.GetObjectMeta().GetName() + "-kt-" + strings.ToLower(util.RandomString(5))
	podIP, podName, err := c.createExchangeShadow(origin, options.Namespace, workload, clientset, labels, options.Image)
	options.RuntimeOptions.Shadow = workload
	down := int32(0)
	scaleTo(origin, options.Namespace, clientset, &down)
	remotePortForward(options.ExchangeOptions.Expose, options.KubeConfig, options.Namespace, podName, podIP, options.Debug)
	return
}
// Exchange exchange request to local
Exchange exchange request to local
// Exchange exchange request to local
func (c *Connect) Exchange(options *options.DaemonOptions, origin *v1.Deployment, clientset *kubernetes.Clientset, labels map[string]string) (workload string, err error) {
	workload = origin.GetObjectMeta().GetName() + "-kt-" + strings.ToLower(util.RandomString(5))
	podIP, podName, err := c.createExchangeShadow(origin, options.Namespace, workload, clientset, labels, options.Image)
	options.RuntimeOptions.Shadow = workload
	down := int32(0)
	scaleTo(origin, options.Namespace, clientset, &down)
	remotePortForward(options.ExchangeOptions.Expose, options.KubeConfig, options.Namespace, podName, podIP, options.Debug)
	return
}
func ( c * Connect ) Exchange ( options * options . DaemonOptions , origin * v1 . Deployment , clientset * kubernetes . Clientset , labels map [ string ] string ) ( workload string , err error ) { workload = origin . GetObjectMeta ( ) . GetName ( ) + " " + strings . ToLower ( util . RandomString ( 5 ) ) podIP , podName , err := c . createExchangeShadow ( origin , options . Namespace , workload , clientset , labels , options . Image ) options . RuntimeOptions . Shadow = workload down := int32 ( 0 ) scaleTo ( origin , options . Namespace , clientset , & down ) remotePortForward ( options . ExchangeOptions . Expose , options . KubeConfig , options . Namespace , podName , podIP , options . Debug ) return }
Exchange exchange request to local
Exchange exchange request to local