Closed segator closed 6 years ago
Hi,
Thanks for reporting, In fact there is a real error in the exception managment e.strerror
do not exists (where e
is a CalledProcessError
).
https://github.com/anybox/buttervolume/blob/master/buttervolume/plugin.py#L44
So I reopen this issue!
Well I closed the issue because I mixed servers and I didn't configure correctly the server.
This is fixed in Buttervolume 2.0 Feel free to reopen if you see another issue like that thanks !
Ubuntu 16.04 Docker 17.06.2-ce btrfs on /var/lib/docker
` docker run -d --privileged -v /var/lib/docker/volumes:/var/lib/docker/volumes -v /run/docker/plugins:/run/docker/plugins anybox/buttervolume docker volume create -d btrfs testbtrfs Error response from daemon: create testbtrfs: VolumeDriver.Create: <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
Error: 500 Internal Server Error
Sorry, the requested URL 'http://unix:/run/docker/plugins/btrfs.sock/VolumeDriver.Create' caused an error:
`
service log show `WARNING:root:No config file /etc/buttervolume/schedule.csv Traceback (most recent call last): File "/usr/local/lib/python3.5/dist-packages/buttervolume-1.3.1-py3.5.egg/buttervolume/plugin.py", line 42, in volume_create btrfs.Subvolume(volpath).create() File "/usr/local/lib/python3.5/dist-packages/buttervolume-1.3.1-py3.5.egg/buttervolume/btrfs.py", line 40, in create out = run('btrfs subvolume create "{}"'.format(self.path)) File "/usr/local/lib/python3.5/dist-packages/buttervolume-1.3.1-py3.5.egg/buttervolume/btrfs.py", line 7, in run stderr=stderr).stdout.decode() File "/usr/lib/python3.5/subprocess.py", line 398, in run output=stdout, stderr=stderr) subprocess.CalledProcessError: Command 'btrfs subvolume create "/var/lib/docker/volumes/testbtrfs"' returned non-zero exit status 1
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "/usr/local/lib/python3.5/dist-packages/bottle-0.12.13-py3.5.egg/EGG-INFO/scripts/bottle.py", line 862, in _handle return route.call(*args) File "/usr/local/lib/python3.5/dist-packages/bottle-0.12.13-py3.5.egg/EGG-INFO/scripts/bottle.py", line 1740, in wrapper rv = callback(a, **ka) File "/usr/local/lib/python3.5/dist-packages/buttervolume-1.3.1-py3.5.egg/buttervolume/plugin.py", line 44, in volume_create return json.dumps({'Err': e.strerror}) AttributeError: 'CalledProcessError' object has no attribute 'strerror' INFO:root:New scheduler job at 2018-01-07 15:54:42.349692 WARNING:root:No config file /etc/buttervolume/schedule.csv INFO:root:New scheduler job at 2018-01-07 15:55:42.351171 WARNING:root:No config file /etc/buttervolume/schedule.csv `