jpetazzo / pipework

Software-Defined Networking tools for LXC (LinuX Containers)
Apache License 2.0
4.21k stars 727 forks source link

/usr/local/bin/pipework: 209: /usr/local/bin/pipework: Bad substitution #203

Closed ns500 closed 4 years ago

ns500 commented 8 years ago

root@test5:~# pipework br0 test3 dhclient /usr/local/bin/pipework: 209: /usr/local/bin/pipework: Bad substitution root@test5:~# lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 16.04 LTS Release: 16.04 Codename: xenial

ns500 commented 8 years ago

root@test5:~# brctl show bridge name bridge id STP enabled interfaces br0 8000.000c29644146 yes ens33 root@test5:~# docker ps -a CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES efd0b6d3ebf3 nginx "/bin/bash" 26 minutes ago Up 26 minutes 80/tcp, 443/tcp test3

hammertank commented 8 years ago

@ns500 , I have the same problem. It is because ubuntu use dash as the default shell instead of bash. After I change the first line in pipework from "#!/bin/sh" to "#!/bin/bash", this problem is solved.

ns500 commented 8 years ago

@hammertank Thank you !

leondltt commented 7 years ago

@jpetazzo thanks for the dank tool you developed. @hammertank that solved the issue, thank you too!

peace.