How to manage Anbox Cloud#

To use Anbox Cloud, you will need to enable it directly through the Ubuntu Pro Client (pro), which will install all the necessary snaps and set up the APT sources needed for the service.

Note

Anbox Cloud is supported on all recent Ubuntu LTS releases (from 20.04 LTS onward). Refer to the Anbox Cloud requirements page for more details.

Make sure pro is up-to-date#

All systems come with pro pre-installed through the ubuntu-advantage-tools package. To make sure that you’re running the latest version of pro, run the following commands:

sudo apt update && sudo apt install ubuntu-advantage-tools

Check the status of the services#

After you have attached your subscription and updated the ubuntu-advantage-tools package, you can check which services are enabled by running the following command:

pro status

This will show you which services are enabled or disabled on your machine (output truncated for brevity):

SERVICE          ENTITLED  STATUS    DESCRIPTION
esm-apps         yes       enabled   Expanded Security Maintenance for Applications
esm-infra        yes       enabled   Expanded Security Maintenance for Infrastructure
livepatch        yes       enabled   Canonical Livepatch service
realtime-kernel  yes       disabled  Ubuntu kernel with PREEMPT_RT patches integrated

Enable Anbox#

To enable Anbox Cloud, run:

$ sudo pro enable anbox-cloud

Important

The Anbox Cloud service can only be installed on containers using the --access-only flag. This option will only set up the APT sources for Anbox, but not install any of the snaps.

You should see output like the following, indicating that Anbox Cloud was correctly enabled on your system:

One moment, checking your subscription first
Installing required snaps
Installing required snap: amc
Installing required snap: anbox-cloud-appliance
Installing required snap: lxd
Updating package lists
Anbox Cloud enabled
To finish setting up the Anbox Cloud Appliance, run:

$ sudo anbox-cloud-appliance init

You can accept the default answers if you do not have any specific
configuration changes.
For more information, see https://anbox-cloud.io/docs/tut/installing-appliance

You have probably noticed that the output states an additional step is required to complete the Anbox Cloud setup. Let us run the required command:

$ sudo anbox-cloud-appliance init

You can now confirm that the service is enabled by running the pro status command again. It should contain the following line for anbox-cloud:

SERVICE          ENTITLED  STATUS    DESCRIPTION
anbox-cloud      yes       enabled   Scalable Android in the cloud

Disable the service#

If you wish to disable Anbox, you can use the following command to disable it:

sudo pro disable anbox-cloud

Note that this command will only remove the APT sources, but will not uninstall the snaps.

To also purge the service, removing all the APT packages installed with it, see how to disable and purge services.