Searched refs:path (Results 1 - 25 of 195) sorted by relevance

12345678

/pkg/src/tests/api/
H A Dtestutils.py29 # Set the path so that modules can be found
30 path_to_parent = os.path.join(os.path.dirname(__file__), "..")
31 sys.path.insert(0, path_to_parent)
H A Dt_file_manager.py47 return os.path.join(s[0:2], s[2:8], s)
52 p = os.path.join(self.base_dir, self.old_hash(s))
53 if not os.path.exists(os.path.dirname(p)):
54 os.makedirs(os.path.dirname(p))
74 self.assertTrue(os.path.isfile(p))
81 self.assertTrue(os.path.isfile(p))
86 self.assertTrue(os.path.isfile(p))
90 self.assertTrue(os.path.isfile(p))
96 self.base_dir = os.path
[all...]
H A Dt_altroot.py55 path = os.path.join(self.test_path,
57 self.imgs_path[i] = path
59 # image path
67 self.p_d_f1 = os.path.join(self.p_d, "f1")
68 self.p_d_f2 = os.path.join(self.p_d, "f2")
69 self.p_d_none = os.path.join(self.p_d, "none")
73 self.p_d_f1_redir = os.path.join(self.p_d_redir, "f1")
74 self.p_d_f2_redir = os.path.join(self.p_d_redir, "f2")
75 self.p_d_none_redir = os.path
[all...]
/pkg/src/tests/cli/
H A Dtestutils.py29 # Set the path so that modules can be found
30 path_to_parent = os.path.join(os.path.dirname(__file__), "..")
31 sys.path.insert(0, path_to_parent)
H A Dt_util_update_file_layout.py48 self.base_dir = os.path.join(self.test_root, "fm")
53 return os.path.join(s[0:2], s[2:8], s)
56 p = os.path.join(self.base_dir, self.old_hash(s))
57 if not os.path.exists(os.path.dirname(p)):
58 os.makedirs(os.path.dirname(p))
85 if os.path.exists(p):
87 if os.path.exists(os.path.dirname(p)):
92 if not os.path
[all...]
H A Dt_pkg_initinstall.py46 add dir path=etc group=sys owner=root mode=0555
47 add dir path=etc/ftpd group=sys owner=root mode=0555
48 add file path=etc/ftpd/ftpusers group=sys preserve=true owner=root mode=0444
49 add link path=etc/ftpusers target=./ftpd/ftpusers
50 add file path=etc/group group=sys preserve=true owner=root mode=0444
51 add file path=etc/passwd group=sys preserve=true owner=root mode=0444
52 add file path=etc/shadow group=sys mode=0400 preserve=true owner=root
87 def file_in_image(self, path):
88 return open(os.path.join(self.get_img_path(), path))
[all...]
H A Dt_https.py50 add file tmp/example_file mode=0555 owner=root group=bin path=/usr/bin/example_path
92 cert=os.path.join(self.cs_dir, self.get_cli_cert("test")),
93 key=os.path.join(self.keys_dir, self.get_cli_key("test")),
101 cert=os.path.join(self.cs_dir, self.get_cli_cert("test")),
102 key=os.path.join(self.keys_dir, self.get_cli_key("test")),
121 assert os.path.join("new.image", "var", "pkg", "ssl") in \
135 cert=os.path.join(self.cs_dir, self.get_cli_cert("test")),
136 key=os.path.join(self.keys_dir, self.get_cli_key("test")),
150 cert=os.path.join(self.cs_dir, self.get_cli_cert("test")),
151 key=os.path
[all...]
/pkg/src/tests/testsuite/
H A Dtestutils.py29 # Set the path so that modules can be found
30 path_to_parent = os.path.join(os.path.dirname(__file__), "..")
31 sys.path.insert(0, path_to_parent)
/pkg/src/modules/actions/
H A Dhardlink.py49 """ return a path for target that is relative to image"""
53 # paths are either relative to path or absolute;
54 # both need to be passed through os.path.normpath to ensure
58 path = self.attrs["path"]
59 target = os.path.normpath(
60 os.path.join(os.path.split(path)[0], target))
62 target = os.path
[all...]
H A Dlicense.py67 # Set attrs["path"] so filelist can handle this action;
68 # the path must be relative to the root of the image.
69 self.attrs["path"] = misc.relpath(os.path.join(
79 # ensure "path" is initialized. it may not be if we've loaded
85 path = self.get_installed_path(pkgplan.image.get_root())
88 if not os.path.exists(os.path.dirname(path)):
89 self.makedirs(os.path
[all...]
H A Ddirectory.py46 key_attr = "path"
47 unique_attrs = "path", "mode", "owner", "group"
50 namespace_group = "path"
54 return (self.attrs["path"] > other.attrs["path"]) - \
55 (self.attrs["path"] < other.attrs["path"])
73 return [os.path.normpath(self.attrs["path"])]
75 def __create_directory(self, pkgplan, path, mod
[all...]
H A Dlink.py50 key_attr = "path"
51 unique_attrs = "path", "target"
54 namespace_group = "path"
61 path = self.get_installed_path(pkgplan.image.get_root())
64 self.fsobj_checkpath(pkgplan, path)
66 if not os.path.exists(os.path.dirname(path)):
67 self.makedirs(os.path.dirname(path),
[all...]
/pkg/src/modules/file_layout/
H A Dlayout.py28 (or file name since those are equivalent in our system) and a relative path
68 """Return the path to the file with name "hashval"."""
71 def path_to_hash(self, path):
72 """Return the hash which would map to "path"."""
86 """Return the path to the file with name "hashval"."""
87 return os.path.join(hashval[0:2], hashval[2:8], hashval)
89 def path_to_hash(self, path):
90 """Return the hash which would map to "path"."""
91 return os.path.basename(path)
[all...]
/pkg/src/modules/
H A Daltroot.py29 routines guarantee that if you perform operations on a specified path, and
30 that path is contained within "root", then those operations will not affect
50 def __path_abs_to_relative(path):
51 """Strip the leading '/' from a path using os.path.split()."""
55 (path, tail) = os.path.split(path)
59 path_new = os.path.join(tail, path_new)
65 """Given a file descriptor return the path t
[all...]
H A Dsyscallat.py34 def mkdirat(fd, path, mode):
39 if not isinstance(path, six.string_types):
40 raise TypeError("path must be a string")
44 rv = lib.mkdirat(fd, force_bytes(path), mode)
46 raise OSError(ffi.errno, os.strerror(ffi.errno), path)
49 def openat(fildes, path, oflag, mode):
54 if not isinstance(path, six.string_types):
55 raise TypeError("path must be a string")
61 rv = lib.openat(fildes, force_bytes(path), oflag, mode)
63 raise OSError(ffi.errno, os.strerror(ffi.errno), path)
[all...]
H A Dpkgtarfile.py51 def extract_to(self, member, path="", filename=""):
53 method allows you to specify a new filename and path, using
54 the filename and path arguments, where the file will be
56 Extract() only allows the caller to prepend a directory path
71 os.path.join(path, tarinfo.linkname)
77 upperdirs = os.path.dirname(os.path.join(path, filename))
79 if upperdirs and not os.path
[all...]
/pkg/src/modules/flavor/
H A Dhardlink.py33 hardlink to a path."""
34 def __init__(self, action, path, pkg_vars):
35 base_names = [os.path.basename(path)]
36 paths = [os.path.dirname(path)]
/pkg/src/modules/bundle/
H A DDirectoryBundle.py51 def __init__(self, path, targetpaths=(), use_default_owner=True):
54 path = os.path.normpath(path)
55 self.filename = path
56 self.rootdir = path
57 self.pkgname = os.path.basename(self.rootdir)
68 fp = os.path.join(self.rootdir, p)
74 path = os.path
[all...]
H A DTarBundle.py39 filename = os.path.normpath(filename)
42 self.pkgname = os.path.basename(filename)
53 for path, data in self._walk_bundle():
63 path=tarinfo.name,
69 path=tarinfo.name)
71 return link.LinkAction(path=tarinfo.name,
74 return hardlink.HardLinkAction(path=tarinfo.name,
77 return unknown.UnknownAction(path=tarinfo.name)
/pkg/src/modules/portable/
H A Dos_windows.py99 def chown(path, owner, group):
137 # quickly find the trash directory for a path without having to create an
142 def get_trashdir(path):
144 Use path to determine the trash directory. This method does not create
145 the directory. If path is not contained within an image, return None.
156 if path.startswith(iroot):
160 img = image.Image(os.path.dirname(path),
163 # path is not within an image, no trash dir
165 trashdir = os.path
[all...]
H A Dos_aix.py38 def chown(path, owner, group):
43 return os.chown(path, owner, group)
46 return os.chown(path, -1, group)
H A D__init__.py143 def chown(path, owner, group):
148 EnvironmentError (or subclass) if the path does not exist
156 OSError (or subclass) if the source path does not exist
163 OSError (or subclass) if the source path does not exist or the link
167 def remove(path):
170 OSError (or subclass) if the source path does not exist or
177 path names given as strings.
185 def split_path(path):
186 """ Splits a path and gives back the components of the path
[all...]
/pkg/src/modules/server/
H A Dface.py69 def __render_template(depot, request, path, pub, http_depot=None):
70 template = tlookup.get_template(path)
77 def __handle_error(path, error):
83 "template: {0}\n".format(path), traceback=True)
91 path = request.path_info.strip("/")
92 if pub and os.path.exists(os.path.join(depot.web_root, pub)):
101 # Strip publisher from path as it can't be used to determine
103 path = path
[all...]
/pkg/src/util/apache2/
H A Dcache-example.conf47 CacheRoot /path/to/cache
/pkg/src/tests/
H A Dpkg5testenv.py39 path_to_proto should be a relative path indicating a path
45 path to the proto area; this is nice because you can then
73 cmddir, cmdname = os.path.split(sys.argv[0])
74 cmddir = os.path.realpath(cmddir)
87 # Clean up relative ../../, etc. out of path to proto
88 pkg_path = os.path.realpath(pkg_path)
89 proto_area = os.path.realpath(proto_area)
91 pkgs = os.path.join(pkg_path, "usr/lib/python{0}/vendor-packages".format(
93 bins = os.path
[all...]

Completed in 27 milliseconds

12345678