Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
emulab
emulab-devel
Commits
cfd91409
Commit
cfd91409
authored
Nov 08, 2014
by
Mike Hibler
Browse files
Hack to recognize /proj, /users, etc paths as valid in the AMD case.
parent
2eab9b24
Changes
4
Hide whitespace changes
Inline
Side-by-side
clientside/os/frisbee.redux/config_emulab.c
View file @
cfd91409
...
@@ -764,6 +764,24 @@ allow_stddirs(char *imageid,
...
@@ -764,6 +764,24 @@ allow_stddirs(char *imageid,
FrisInfo
(
"%s: exists=%d, resolves to: '%s'"
,
FrisInfo
(
"%s: exists=%d, resolves to: '%s'"
,
imageid
,
exists
,
tpath
);
imageid
,
exists
,
tpath
);
#ifdef WITHAMD
/*
* We have to explicitly check for the AMD prefix.
* The realpath resolution in emulab_init checks the root of
* each filesystem (e.g. "/proj") which won't be an AMD symlink,
* only the contents of the directories will be
* (e.g. "/proj/emulab-ops"). And, as of right now, we do not
* know which of /users, /proj, /groups and /share might be an
* AMD mount point.
*/
if
(
strncmp
(
AMD_ROOT
,
tpath
,
strlen
(
AMD_ROOT
))
==
0
)
{
free
(
fpath
);
fpath
=
mystrdup
(
tpath
+
strlen
(
AMD_ROOT
));
if
(
debug
)
FrisInfo
(
"%s: stripped AMD prefix"
,
fpath
);
}
#endif
/*
/*
* Make the appropriate access checks for get/put
* Make the appropriate access checks for get/put
*/
*/
...
...
config.h.in
View file @
cfd91409
...
@@ -68,5 +68,6 @@
...
@@ -68,5 +68,6 @@
#undef NOVIRTNFSMOUNTS
#undef NOVIRTNFSMOUNTS
#undef WITHZFS
#undef WITHZFS
#undef WITHAMD
#undef WITHAMD
#undef AMD_ROOT
#undef BS_IQN_PREFIX
#undef BS_IQN_PREFIX
configure
View file @
cfd91409
...
@@ -5524,6 +5524,10 @@ fi
...
@@ -5524,6 +5524,10 @@ fi
if
test
$WITHAMD
-eq
1
;
then
if
test
$WITHAMD
-eq
1
;
then
cat
>>
confdefs.h
<<
_ACEOF
cat
>>
confdefs.h
<<
_ACEOF
#define WITHAMD 1
#define WITHAMD 1
_ACEOF
cat
>>
confdefs.h
<<
_ACEOF
#define AMD_ROOT "
$AMD_ROOT
"
_ACEOF
_ACEOF
fi
fi
...
...
configure.in
View file @
cfd91409
...
@@ -665,6 +665,7 @@ if test $WITHZFS -eq 1; then
...
@@ -665,6 +665,7 @@ if test $WITHZFS -eq 1; then
fi
fi
if test $WITHAMD -eq 1; then
if test $WITHAMD -eq 1; then
AC_DEFINE_UNQUOTED(WITHAMD, 1)
AC_DEFINE_UNQUOTED(WITHAMD, 1)
AC_DEFINE_UNQUOTED(AMD_ROOT, "$AMD_ROOT")
fi
fi
AC_DEFINE_UNQUOTED(IMPORT_TMPDIR, "$IMPORT_TMPDIR")
AC_DEFINE_UNQUOTED(IMPORT_TMPDIR, "$IMPORT_TMPDIR")
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment