Make ws working between cli and daemon.

+ remove deprecated files