silarsis / docker-proxy

Transparent proxy for docker containers, run in a docker container

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Traps with /bin/sh not works under Ubuntu

kmmbvnr opened this issue · comments

Ubuntu /bin/sh links to dash which doesn't support the pseudo-signal ERR,

 trap: SIGINT: bad trap

You could use #!/bin/bash instead.

I've updated the script code to use INT instead of SIGINT - my reading of the dash docs suggests that should be correct behaviour. This change is as yet untested, but I will get someone with an ubuntu system to test later today.

I have confirmed that the changes made fix the script for dash. Please let me know if you have any other issues, and thanks for the heads-up on this one :)