14

We have started replacing some Windows desktops with Ubuntu for some users in the organization I work. Because of our policies we need to globally disable the following features:

  • The Include online search results from the Search tab of Security & Privacy
  • The Amazon launcher icon from the launcher

I noticed that when I manually un-click the "Include online search results" it changes the ~/.config/dconf/user. But this file in in some GVariant binary format so I cannot tweak it with a text editor or a script.

I also tried this command I found on another post, but it does not appear to have an effect and suggestions still work:

$ gsettings set com.canonical.Unity.Lenses disabled-scopes "['more_suggestions-amazon.scope', 'more_suggestions-u1ms.scope', 'more_suggestions-populartracks.scope', 'music-musicstore.scope', 'more_suggestions-ebay.scope', 'more_suggestions-ubuntushop.scope', 'more_suggestions-skimlinks.scope']"

Is there a way to disable these features to comply with the my organization's policy? We are using 14.042 LTS but it would be ideal if the solution works for later versions as well.

1
  • 1
    You may also block productsearch.ubuntu.com in /etc/hosts.
    – user12205
    May 28, 2015 at 13:26

2 Answers 2

16

The command you are looking for is:

gsettings set com.canonical.Unity.Lenses remote-content-search 'none'

To make the command globally (for all users) on log in, you'd have to add a launcher in /etc/xdg/autostart, running the command:

/bin/bash -c "gsettings set com.canonical.Unity.Lenses remote-content-search 'none'"

The file would look like:

[Desktop Entry]
Name=Disable Search
Exec=/bin/bash -c "gsettings set com.canonical.Unity.Lenses remote-content-search 'none'"
Type=Application

Save it as disable_onlinesearch.desktop in /etc/xdg/autostart

Remove the Amazon launcher

To make sure no user can use the Amazon launcher, it is best to remove it globally: go to /usr/share/applications and look for the file:

ubuntu-amazon-default.desktop

and remove it.

Alternatively

If for some reason, you'd like to keep the file ubuntu-amazon-default.desktop, but (temporarily?) disable it (make it invisible in Dash/Unity) add a line to the file:

NoDisplay=true

Later versions

The solution(s) above works for the current versions of Ubuntu, at least from 14.04 and higher. (as on May 28, 2015).

1
  • Thanks Jacob. The solution for the "suggestions" worked great. I tested it by creating a new user. It works like charm. As for the Amazon launcher, I took more drastic measures: > sudo apt-get purge unity-webapps-common > sudo apt-mark hold unity-webapps-common May 29, 2015 at 4:32
4

you can completely remove unity-webapps-common to remove the shopping lens, including amazon.

sudo apt-get purge unity-webapps-common

You then need to log out and back in.

3
  • Alas, this package is no longer included in 14.04 and on May 28, 2015 at 8:18
  • @TheodotosAndreou my fault. miss the version
    – Maythux
    May 28, 2015 at 8:21
  • interestingly, I had the package... Ubuntu 14.04 LTS
    – mBardos
    Sep 13, 2017 at 8:55

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .