comparison src/server/server.py @ 1105:e6ff5530900e

server: fixed service profile's cache
author Goffi <goffi@goffi.org>
date Sun, 03 Jun 2018 10:32:57 +0200
parents 5976dcd42591
children 09feea19d7b9
comparison
equal deleted inserted replaced
1104:9313bcbe45b7 1105:e6ff5530900e
2074 @raise IOError: the certificate file doesn't exist 2074 @raise IOError: the certificate file doesn't exist
2075 @raise OpenSSL.crypto.Error: the certificate file is invalid 2075 @raise OpenSSL.crypto.Error: the certificate file is invalid
2076 """ 2076 """
2077 # now that we have service profile connected, we add resource for its cache 2077 # now that we have service profile connected, we add resource for its cache
2078 service_path = regex.pathEscape(C.SERVICE_PROFILE) 2078 service_path = regex.pathEscape(C.SERVICE_PROFILE)
2079 cache_dir = os.path.join(self.cache_root_dir, service_path) 2079 cache_dir = os.path.join(self.cache_root_dir, u'profiles', service_path)
2080 self.cache_resource.putChild(service_path, ProtectedFile(cache_dir)) 2080 self.cache_resource.putChild(service_path, ProtectedFile(cache_dir))
2081 self.service_cache_url = u'/' + os.path.join(C.CACHE_DIR, service_path) 2081 self.service_cache_url = u'/' + os.path.join(C.CACHE_DIR, service_path)
2082 session_iface.SATSession.service_cache_url = self.service_cache_url 2082 session_iface.SATSession.service_cache_url = self.service_cache_url
2083 2083
2084 if self.options['connection_type'] in ('https', 'both'): 2084 if self.options['connection_type'] in ('https', 'both'):