File tree 1 file changed +4
-3
lines changed
1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -141,10 +141,10 @@ function dmhelper() {
141
141
commands=(env inspect ip kill ls regenerate-certs restart rm ssh scp start status stop upgrade url help)
142
142
if [ -d /mnt/c ]; then
143
143
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
145
145
else
146
146
case "${commands[@]}" in *"$1"*) docker-machine $* ; return ;; esac
147
- eval $( docker-machine env $1)
147
+ docker context use $1
148
148
fi
149
149
}
150
150
@@ -162,6 +162,7 @@ function vagrantdm() {
162
162
if [ "$1" == "status" ]; then vg status $2; return; fi
163
163
if [ "$1" == "rdp" ]; then vg rdp $2; return; fi
164
164
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
165
166
dmhelper $*
166
167
}
167
168
@@ -176,7 +177,7 @@ function azuredm() {
176
177
function dm() {
177
178
vagrantmachines=(2016 2016-box 1709 1803 1809 2019 2019-box insider lcow)
178
179
case "${vagrantmachines[@]}" in *"${!#}"*) vagrantdm $* ; return ;; esac
179
- azuremachines=(az2019 az2016 az1709)
180
+ azuremachines=(az2019 az2016 az1709 az1803 )
180
181
case "${azuremachines[@]}" in *"${!#}"*) azuredm $* ; return ;; esac
181
182
dmhelper $*
182
183
}
You can’t perform that action at this time.
0 commit comments