| 806 | } |
| 807 | |
| 808 | func (cmd Push) ValidateContextAndAppParams(appsFromManifest []models.AppParams, appFromContext models.AppParams) error { |
| 809 | if appFromContext.NoHostname != nil && *appFromContext.NoHostname { |
| 810 | for _, app := range appsFromManifest { |
| 811 | if app.Routes != nil { |
| 812 | return errors.New(T("Option '--no-hostname' cannot be used with an app manifest containing the 'routes' attribute")) |
| 813 | } |
| 814 | } |
| 815 | } |
| 816 | |
| 817 | return nil |
| 818 | } |
| 819 | |
| 820 | func (cmd *Push) uploadApp(appGUID, appDir, appDirOrZipFile string, localFiles []models.AppFileFields) error { |
| 821 | uploadDir, err := ioutil.TempDir("", "apps") |