File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -141,10 +141,10 @@ function dmhelper() {
141141 commands=(env inspect ip kill ls regenerate-certs restart rm ssh scp start status stop upgrade url help)
142142 if [ -d /mnt/c ]; then
143143 case "${commands[@]}" in *"$1"*) docker-machine.exe $* ; return ;; esac
144- eval $( docker-machine.exe env -shell bash $1 | sed 's/C://' | sed 's/\\/\//g')
144+ docker context use $1
145145 else
146146 case "${commands[@]}" in *"$1"*) docker-machine $* ; return ;; esac
147- eval $( docker-machine env $1)
147+ docker context use $1
148148 fi
149149}
150150
@@ -162,6 +162,7 @@ function vagrantdm() {
162162 if [ "$1" == "status" ]; then vg status $2; return; fi
163163 if [ "$1" == "rdp" ]; then vg rdp $2; return; fi
164164 if [ "$1" == "regenerate-certs" ]; then vg provision $2; return; fi
165+ if [ "$1" == "ip" ]; then docker context inspect $2 | jq -r '.[0].Endpoints.docker.Host | .[6:] | .[:-5]'; return; fi
165166 dmhelper $*
166167}
167168
@@ -176,7 +177,7 @@ function azuredm() {
176177function dm() {
177178 vagrantmachines=(2016 2016-box 1709 1803 1809 2019 2019-box insider lcow)
178179 case "${vagrantmachines[@]}" in *"${!#}"*) vagrantdm $* ; return ;; esac
179- azuremachines=(az2019 az2016 az1709)
180+ azuremachines=(az2019 az2016 az1709 az1803 )
180181 case "${azuremachines[@]}" in *"${!#}"*) azuredm $* ; return ;; esac
181182 dmhelper $*
182183}
You can’t perform that action at this time.
0 commit comments