Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Next challenges

Recent achievements

  • Global
  • Personal

Recognition

  • Give kudos
  • Received
  • Given

Leaderboard

  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

How to prevent a Space Administrator from delete their Space?

How do you configure Confluence to prevent a Space Administrator from deleting their Space. We want to make this a Confluence Administrator task. We are having to restore Spaces that were deleted and then needed by the Space users. Thanks,

3 answers

1 accepted

0 votes
Answer accepted

Hi @Bill Brinkley .

This is really not something you could configure on Confluence out-of-the-box.

If you need to give Space Deletion permissions only to Confluence Administrators, then you are able to do that by applying non-standard customization to your Confluence.

The contents of the <confluence-install>/confluence/spaces/removespace.vm file controls the appearance of the Delete Space feature in the UI.
This is how it looks when using the default contents for that file.

space-delete-1.png


You could customize it in a way that only Confluence Administrators would be able to see this information and, therefore, delete the Space.
Other users, such as Space Administrators, would see something as the sample below.

space-delete-2.png

 


If this is something that is valuable to you, you could use the following content on the <confluence-install>/confluence/spaces/removespace.vm file.

<html>
<head>
<title>$action.getText("title.remove.space")</title>
</head>

#applyDecorator("root")
#decoratorParam("helper" $action.helper)
#decoratorParam("context" "space-administration")
#decoratorParam("mode" "view-space-administration")

<body>
#applyDecorator ("root")
#decoratorParam ("context" "spaceadminpanel")
#decoratorParam ("selection" "removespace")
#decoratorParam ("title" "$action.getText('title.remove.space')")
#decoratorParam ("selectedTab" "admin")
#decoratorParam ("selectedSpaceToolsWebItem", "removespace")
#decoratorParam("helper" $action.helper)

#if( $permissionHelper.isConfluenceAdministrator($remoteUser) )

#applyDecorator ("confirm")

<p>$action.getText("remove.space.desc")</p>
#if( $action.showLargeQueueWarning)
#applyDecorator("message" "$action.getText('info.word')")
#decoratorParam("type" "info")
$action.getText("com.atlassian.confluence.spaces.actions.RemoveSpaceAction.warn.large.indexqueue", [$action.indexQueueSize])
#end
#end
#applyDecorator ("message" "$action.getText('warning.word')")
#decoratorParam("type" "warning")
$action.getText('removespace.operation.cannot.be.undone')
#end

#decoratorParam ("formAction" "doremovespace.action?key=$htmlUtil.urlEncode($space.key)")
#decoratorParam ("formName" "removespaceform")

$action.getText("alert.remove.space", [$htmlUtil.htmlEncodeAndReplaceSpaces($space.key), $webwork.htmlEncode($space.name)])
#end

#else

#applyDecorator ("message" "$action.getText('warning.word')")
#decoratorParam("type" "warning")
<p>You don't have permission to delete this Space.</br>Please contact your Confluence administrator.</p>
#end

#end

#end

</body>

#end
</html>


You don't need to restart Confluence after making changes to this file.
You would also need to check this file after every upgrade to see if the same modifications would still be valid and reapply them.

 

Let us know if that works to you.

Kind regards,
Thiago Masutti

0 votes
Tansu Akdeniz Community Leader Jan 19, 2021

Hi @Bill Brinkley 

If you give space admin permission, they can delete it. 

There is an open ticket for it. Please watch and vote it.

Best

0 votes

Hi @Bill Brinkley ,

I think we can't restrict space admin for deleting space from instance.

Please check the below link

 

https://support.atlassian.com/confluence-cloud/docs/delete-a-space/ 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
VERSION
7.4.3
TAGS
Community showcase
Published in Confluence

Announcing Team Calendars in Confluence Data Center

Hi Community! We're thrilled to share that Team Calendars for Confluence is now a built-in feature for Confluence Data Center releases 7.11 and beyond.  A long time favorite,  Team Cale...

146 views 0 5
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you