Commit 8e1c9ddf authored by Daniele Venzano's avatar Daniele Venzano

Fix volume description for home workspace

parent 5c85f83d
......@@ -43,8 +43,8 @@ def gen_environment(execution: Execution, service: Service, env_subst_dict: Dict
env_list.append(('SERVICE_NAME', service.name))
env_list.append(('PROXY_PATH', get_conf().proxy_path))
fswk = ZoeFSWorkspace()
env_list.append(('ZOE_WORKSPACE', fswk.get_mountpoint()))
wk_vol = ZoeFSWorkspace().get(execution.user_id)
env_list.append(('ZOE_WORKSPACE', wk_vol.mount_point))
return env_list
......
......@@ -19,7 +19,7 @@ import logging
import os.path
import zoe_lib.config as config
from zoe_lib.state import VolumeDescription
from zoe_lib.state import VolumeDescriptionHostPath
import zoe_master.workspace.base
log = logging.getLogger(__name__)
......@@ -46,8 +46,8 @@ class ZoeFSWorkspace(zoe_master.workspace.base.ZoeWorkspaceBase):
@classmethod
def get_mountpoint(cls):
"""Get the volume mount point."""
return '/workspace'
return 'workspace'
def get(self, user_id):
"""Return a VolumeDescription for the user workspace."""
return VolumeDescription((self.get_path(user_id), self.get_mountpoint(), False))
return VolumeDescriptionHostPath(path=self.get_path(user_id), name=self.get_mountpoint(), readonly=False)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment