Skip to content

Commit

Permalink
Updates from comments
Browse files Browse the repository at this point in the history
  • Loading branch information
dheyay committed Jan 15, 2025
1 parent 6ad88bd commit 4262ae7
Show file tree
Hide file tree
Showing 3 changed files with 65 additions and 50 deletions.
4 changes: 2 additions & 2 deletions docs/howtoguides/attach_index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ configuration file:

You can also use your Ubuntu Pro subscription across multiple machines:

* :ref:`Configure Ubuntu Pro across multiple machines <roll_out_multiple_machines>`
* :ref:`Attach multiple machines <attach_multiple_machines>`

.. TOC
Expand All @@ -31,4 +31,4 @@ You can also use your Ubuntu Pro subscription across multiple machines:
How to attach <how_to_attach>
Simulate attaching <how_to_simulate_attach>
Attach with a configuration file <how_to_attach_with_config_file>
Configure Ubuntu Pro across multiple machines <how_to_roll_out_across_multiple_machines>
Configure Ubuntu Pro across multiple machines <how_to_attach_multiple_machines>
63 changes: 63 additions & 0 deletions docs/howtoguides/how_to_attach_multiple_machines.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
.. _attach_multiple_machines:

Attach multiple machines
========================

When attaching machines to a Pro subscription, you have several options. For a single machine, refer to :ref:`How to attach <attach>` for CLI instructions or :ref:`How to attach using a config file <attach-with-config>` for configuration file steps.

For deploying Pro across multiple machines, Cloud-init provides the most efficient solution. This guide demonstrates how to use Cloud-init to distribute your Pro token and configure Pro services across multiple machines at once.

Configure using Cloud-init
--------------------------

The next step is to use cloud-init to configure your machines with the pro token.

To do this, a cloud-init configuratioin file is required. Here, we will first create a file with the name "cloud-init.yaml" and add the pro token to it by copying the following code block to the file:

.. code-block:: yaml
#cloud-config
ubuntu_pro:
token: <YOUR_PRO_TOKEN>
Replace <YOUR_PRO_TOKEN> with the pro token you received from the Ubuntu Pro Dashboard. For more information on how to obtain a pro token, see `Ubuntu Pro <Pro_>`_.

For more information on how to configure Pro with cloud-init, take a look at the guide here: `Configure Pro in cloud-init <CLOUD_INIT_PRO_>`_.

Cloud-init also has comprehensive guides on configuring cloud-init for different platforms:

- `QEMU`_
- `LXD`_
- `Ansible`_

Verifying deployment
--------------------

After deployment, execute these commands on the host to confirm Pro subscription is attached:

.. code-block:: bash
$ sudo pro status
You should see the following (output truncated):

.. code-block:: text
SERVICE ENTITLED STATUS DESCRIPTION
esm-apps yes enabled Expanded Security Maintenance for Applications
esm-infra yes enabled Expanded Security Maintenance for Infrastructure
fips yes disabled NIST-certified core packages
fips-updates yes disabled NIST-certified core packages with priority security updates
livepatch yes enabled Canonical Livepatch service
Here, the columns "ENTITLED" and "STATUS" indicate whether the service is entitled to the subscription and whether it is enabled or disabled. For more information on understanding the output of the status command, refer to :ref:`this explanation <pro-status-output>`.

.. LINKS
.. include:: ../links.txt

.. _CLOUD_INIT_PRO: https://cloudinit.readthedocs.io/en/latest/reference/modules.html#ubuntu-pro
.. _QEMU: https://cloudinit.readthedocs.io/en/latest/tutorial/qemu.html
.. _LXD: https://cloudinit.readthedocs.io/en/latest/tutorial/lxd.html
.. _Ansible: https://cloudinit.readthedocs.io/en/latest/reference/yaml_examples/ansible_managed.html
48 changes: 0 additions & 48 deletions docs/howtoguides/how_to_roll_out_across_multiple_machines.rst

This file was deleted.

0 comments on commit 4262ae7

Please sign in to comment.