mirror of https://github.com/docker/compose.git
Deploy with user-defined vpc id
Signed-off-by: aiordache <anca.iordache@docker.com> Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
This commit is contained in:
parent
b6be4a0ac3
commit
39a59ae55f
|
@ -81,6 +81,7 @@ func ComposeCommand(clusteropts *clusterOptions) *cobra.Command {
|
|||
|
||||
type upOptions struct {
|
||||
loadBalancerArn string
|
||||
vpcID string
|
||||
}
|
||||
|
||||
func (o upOptions) LoadBalancerArn() *string {
|
||||
|
@ -89,6 +90,12 @@ func (o upOptions) LoadBalancerArn() *string {
|
|||
}
|
||||
return &o.loadBalancerArn
|
||||
}
|
||||
func (o upOptions) GetVPC() *string {
|
||||
if o.vpcID == "" {
|
||||
return nil
|
||||
}
|
||||
return &o.vpcID
|
||||
}
|
||||
|
||||
func ConvertCommand(clusteropts *clusterOptions, projectOpts *compose.ProjectOptions) *cobra.Command {
|
||||
cmd := &cobra.Command{
|
||||
|
@ -128,6 +135,7 @@ func UpCommand(clusteropts *clusterOptions, projectOpts *compose.ProjectOptions)
|
|||
}),
|
||||
}
|
||||
cmd.Flags().StringVar(&opts.loadBalancerArn, "load-balancer", "", "")
|
||||
cmd.Flags().StringVar(&opts.vpcID, "vpc-id", "", "")
|
||||
return cmd
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue