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
c2ecb473
Commit
c2ecb473
authored
Apr 25, 2017
by
Leigh B Stoller
Browse files
Enable profile/image deletion for all users.
parent
96794781
Changes
3
Hide whitespace changes
Inline
Side-by-side
apt/manage_images.in
View file @
c2ecb473
...
...
@@ -497,7 +497,7 @@ sub DoDeleteImage()
my
$opt
=
(
$impotent
?
"
-n
"
:
"");
my
$output
=
emutil::
ExecQuiet
("
$MANAGEPROFILE
delete
--
-k
$opt
$uuid
");
emutil::
ExecQuiet
("
$MANAGEPROFILE
delete -k
$opt
$uuid
");
print
$output
;
if
(
$?
)
{
fatal
("
Could not delete version
$vers
");
...
...
apt/manage_profile.in
View file @
c2ecb473
...
...
@@ -1060,7 +1060,7 @@ sub DeleteProfile()
my
$profile
=
APT_Profile
->
Lookup
(
$ARGV
[
0
]);
if
(
!
defined
(
$profile
))
{
fatal
("
No such profile exists
"
);
fatal
("
No such profile exists
:
"
.
$ARGV
[
0
]
);
}
if
(
$profile
->
isLocked
())
{
$errmsg
=
"
This profile has its nodelete flag set.
";
...
...
@@ -1071,7 +1071,8 @@ sub DeleteProfile()
goto
uerror
;
}
# For now, mere users do not see new image deletion stuff unless
# feature enabled.
# feature enabled.
if
(
0
)
{
if
(
!
(
$this_user
->
admin
()
||
$this_user
->
stud
()))
{
my
$project
=
Project
->
Lookup
(
$profile
->
pid_idx
());
if
(
!
EmulabFeatures
->
FeatureEnabled
("
APT_ImageDeletion
",
...
...
@@ -1079,6 +1080,7 @@ sub DeleteProfile()
$keepimages
=
1
;
}
}
}
# If deleting the only version of a profile, then force $all.
if
(
$profile
->
VersionCount
()
==
1
)
{
...
...
www/aptui/quickvm_sup.php
View file @
c2ecb473
...
...
@@ -400,7 +400,7 @@ echo " <li class='divider'></li>
<li><a href='create-dataset.php'>Create Dataset</a></li>
<li><a href='user-dashboard.php#datasets'>
My Datasets</a></li>
<li><a href='images.php'>
List
Disk Images</a></li>
<li><a href='
list-
images.php'>
My
Disk Images</a></li>
</ul>
</li>
"
;
...
...
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