How to restrict the Nextcloud ONLYOFFICE to groups

If you're the Nextcloud admin for your company or home office, you might want to restrict who has access to the ONLYOFFICE suite of tools. Jack Wallen shows you how.

nextcloudhero.jpg

Image: Jack Wallen

The new normal is the home office. When the dust settles on the COVID-19 pandemic, you can be certain that many companies are going to opt to keep a good portion of their staff at home. It makes perfect sense--not only is it safer for the employees, it's also cheaper for the company.

Fortunately, there are plenty of tools available to help make your home office just as efficient and productive as that of your regular office. One such tool is the on premises cloud server platform, Nextcloud. With plenty of features and a user-friendly interface, Nextcloud will have you feeling right at home with your own cloud server.

One such feature that puts Nextcloud heads above the competition is the built-in office suite, powered by ONLYOFFICE. With this inclusion, you can create, edit, and share documents, spreadsheets, and presentations--all from within your own personal/private cloud. 

However, you might have run into a situation where you're having to share that instance of Nextcloud with other users. What happens when you want to restrict the ONLYOFFICE editor access to certain users? What do you do? 

The Nextcloud and ONLYOFFICE developers have thought of that very situation with group restriction. Effectively, you can create a group, add users to that group, and then restrict ONLYOFFICE access to that group.

Let me show you how.

SEE: Hybrid cloud: A guide for IT pros (TechRepublic download)

What you'll need

  • A running instance of Nextcloud Hub (Nextcloud 18)

  • A Nextcloud admin user

How to create a group and add users

The first thing we must do is create a group. To do this, log in to Nextcloud with your admin account and click on your profile icon in the upper-right corner. From the popup menu, click Users. In the resulting window, click Add Group (Figure A).

Figure A

nextcloudrestrictb.jpg

The Nextcloud Users window.

Type the name of the new group and click the right-pointing arrow to save the group.

To add users to the new group, you have to do so one at a time. Click on Everyone (from the left navigation) and then click the pencil icon associated with the user to be added. Type the name of the new group in the group text area and hit Enter on your keyboard. When/if prompted, type your admin password. Once you've successfully authenticated, click the check mark to save the changes.

Continue that process until you have everyone you want to give access to ONLYOFFICE added to the group.

How to restrict ONLYOFFICE to the new group

Click your profile icon in the upper-right corner of the Nextcloud window again and select Settings. In the resulting window, click ONLYOFFICE in the left navigation. In the ONLYOFFICE Settings window, click the check box for Restrict Access To Editors To The Following Groups (Figure B). 

Figure B

nextcloudrestricth.jpg

The Nextcloud ONLYOFFICE Settings window is where you restrict users.

Click the resulting text area to open the groups drop-down and select the group you want to give access to the ONLYOFFICE editors. Make sure to also add the admin group to the access list, otherwise your admin user will not be able to use the ONLYOFFICE suite of tools. Scroll down and click Save to save the changes.  

Once you've taken care of this, log in with a Nextcloud user who is not a member of the group and you will see the ONLYOFFICE feature in Files is no longer available (Figure C).

Figure C

nextcloudrestrictj.jpg

On the left side is a user who is a member of the allowed group, while on the right is a user who is not.

And that's all there is to restricting the ONLYOFFICE feature in Nextcloud Hub to certain groups. Use this access control wisely, to prevent certain users from gaining access to a feature you might not want them using.

Also see