mirror of https://github.com/docker/docs.git
				
				
				
			Update bash completion for `docker service {create,update} {--mode,--endpoint-mode}`
Signed-off-by: Harald Albers <github@albersweb.de> (cherry picked from commit a394490d3895fe0122b44a3f89acc04946b83bda) Signed-off-by: Tibor Vass <tibor@docker.com>
This commit is contained in:
		
							parent
							
								
									fc4c8d927a
								
							
						
					
					
						commit
						9b0ebd26e8
					
				| 
						 | 
				
			
			@ -1710,7 +1710,6 @@ _docker_service_update() {
 | 
			
		|||
		--label -l
 | 
			
		||||
		--limit-cpu
 | 
			
		||||
		--limit-memory
 | 
			
		||||
		--mode
 | 
			
		||||
		--mount -m
 | 
			
		||||
		--name
 | 
			
		||||
		--network
 | 
			
		||||
| 
						 | 
				
			
			@ -1734,6 +1733,18 @@ _docker_service_update() {
 | 
			
		|||
		--registry-auth
 | 
			
		||||
	"
 | 
			
		||||
 | 
			
		||||
	if [ "$subcommand" = "create" ] ; then
 | 
			
		||||
		options_with_args="$options_with_args
 | 
			
		||||
			--mode
 | 
			
		||||
		"
 | 
			
		||||
 | 
			
		||||
		case "$prev" in
 | 
			
		||||
			--mode)
 | 
			
		||||
				COMPREPLY=( $( compgen -W "global replicated" -- "$cur" ) )
 | 
			
		||||
				return
 | 
			
		||||
				;;
 | 
			
		||||
		esac
 | 
			
		||||
	fi
 | 
			
		||||
	if [ "$subcommand" = "update" ] ; then
 | 
			
		||||
		options_with_args="$options_with_args
 | 
			
		||||
			--arg
 | 
			
		||||
| 
						 | 
				
			
			@ -1751,7 +1762,7 @@ _docker_service_update() {
 | 
			
		|||
 | 
			
		||||
	case "$prev" in
 | 
			
		||||
		--endpoint-mode)
 | 
			
		||||
			COMPREPLY=( $( compgen -W "DNSRR VIP" -- "$cur" ) )
 | 
			
		||||
			COMPREPLY=( $( compgen -W "dnsrr vip" -- "$cur" ) )
 | 
			
		||||
			return
 | 
			
		||||
			;;
 | 
			
		||||
		--env|-e)
 | 
			
		||||
| 
						 | 
				
			
			@ -1759,10 +1770,6 @@ _docker_service_update() {
 | 
			
		|||
			__docker_nospace
 | 
			
		||||
			return
 | 
			
		||||
			;;
 | 
			
		||||
		--mode)
 | 
			
		||||
			COMPREPLY=( $( compgen -W "global replicated" -- "$cur" ) )
 | 
			
		||||
			return
 | 
			
		||||
			;;
 | 
			
		||||
		--network)
 | 
			
		||||
			__docker_complete_networks
 | 
			
		||||
			return
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue