Merge pull request #512 from docker/warn_on_aws_context

Ask to recreate context when running on an `aws` type
This commit is contained in:
Nicolas De loof 2020-08-20 09:33:19 +02:00 committed by GitHub
commit 56979d2ba4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -82,6 +82,10 @@ func checkComposeSupport(ctx context.Context) error {
if err != nil {
return err
}
if cc.Type() == store.AwsContextType {
return errors.Errorf(`%q context type has been renamed. Recreate the context by running:
$ docker context create %s <name>`, cc.Type(), store.EcsContextType)
}
return errors.Wrapf(errdefs.ErrNotImplemented, "compose command not supported on context type %q", cc.Type())
}
return err