code: func (c *DeploymentsController) DeleteDeployment(ctx *app.DeleteDeploymentDeploymentsContext) error {
  	kc, err := c.GetKubeClient(ctx)
  	defer cleanup(kc)
  	if err != nil {
  		return jsonapi.JSONErrorResponse(ctx, err)
  	}
  
  	kubeSpaceName, err := c.getSpaceNameFromSpaceID(ctx, ctx.SpaceID)
  	if err != nil {
  		return jsonapi.JSONErrorResponse(ctx, goa.ErrNotFound(err.Error()))
  	}
  
  	err = kc.DeleteDeployment(*kubeSpaceName, ctx.AppName, ctx.DeployName)
  	if err != nil {
  		log.Error(ctx, map[string]interface{}{
  			"err":        err,
  			"space_name": *kubeSpaceName,
  		}, "error deleting deployment")
  		return jsonapi.JSONErrorResponse(ctx, err)
  	}
  
  	return ctx.OK([]byte{})
  }
docs: // DeleteDeployment runs the deleteDeployment action.