Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleanup the images documentation #46

Merged
merged 1 commit into from
Apr 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 0 additions & 9 deletions images/cloud-init-data.rst

This file was deleted.

16 changes: 16 additions & 0 deletions images/cloud-init.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
==========
Cloud-init
==========

`Cloud-init <https://cloudinit.readthedocs.io/en/latest/>`_ is the industry standard multi-distribution method for cross-platform
cloud instance initialization. It is supported across all major public cloud providers, provisioning systems for private cloud
infrastructure, and bare-metal installations.

During boot, cloud-init identifies the cloud it is running on and initialises the system accordingly. Cloud instances will automatically
be provisioned during first boot with networking, storage, SSH keys, packages and various other system aspects already configured.

Cloud-init is very powerful and users can send their own cloud-user data to cloud-init to accomplish customized configuration. See the
`examples here <https://cloudinit.readthedocs.io/en/latest/reference/examples.html>`_.

.. seealso::
- :doc:`index`
30 changes: 22 additions & 8 deletions images/create-rescue-image.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,34 @@
Create rescue image
===================

To :doc:`boot your instance from a rescue image </compute/boot-from-rescue>` you will need to first have a rescue image available. A rescue image can be an operating system installation media (for instance) or a live-cd that boots an entire operating system from an ISO file.
To :doc:`boot your instance from a rescue image </compute/boot-from-rescue>` you will
need to first have a rescue image available.

Because you need to set various properties on the image to use it as a rescue image, its nessecary to use the :doc:`/getting-started/managing-your-cloud/openstack-terminal-client` to create the image.
A rescue image can be an operating system installation media, Live-CD that boots an
entire operating system from an ISO file or any other rescue media

Since you need to set custom properties on the rescue image this can only be done using
the :doc:`/getting-started/managing-your-cloud/openstack-terminal-client` or :doc:`/getting-started/managing-your-cloud/openstack-horizon`.

OpenStack Terminal Client
-------------------------
To create a rescue image to boot from using the :doc:`/getting-started/managing-your-cloud/openstack-terminal-client`, follow these steps:

- Download the ISO that you want to use and save it on your computer.
- Run this command: ``$ openstack image create <ISO_NAME> --property hw_rescue_device=cdrom --property hw_rescue_bus=scsi --disk-format iso --file <LOCAL_FILENAME>.iso --private --progress``
- Note the <ISO_NAME> as you will need this to boot from the image.
This will guide you through creating a rescue image using the :doc:`/getting-started/managing-your-cloud/openstack-terminal-client`

- Download the rescue media ISO to your computer

- Upload it as a new image

.. note:: Replace name and file with the correct information in below command.

::

openstack image create [NAME] --property hw_rescue_device=cdrom --property hw_rescue_bus=scsi --disk-format iso --file [FILENAME] --private --progress

Your rescue image can now be used, make a note of the name of the image.

.. Note::
The image can be deleted or remain on your account for future use once you have unmounted it from your instance. If you opt to save the image, please note that it will consume disk-space and therefore have an hourly cost as per our price list.
.. note:: You will be charged based on the price list for the image unless it's deleted, when you
are done using the image it can be deleted to save on the hourly cost for storing the image.

.. seealso::
- :doc:`index`
70 changes: 56 additions & 14 deletions images/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,38 +2,80 @@
Images
======

A image is a prepared operating system disk that can be used to populate a :doc:`volume </storage/persistent-block-storage/index>` or boot an :doc:`instance </compute/index>` from.
The image service in Binero cloud allows you to store and retrieve virtual machine images that
you can be used to populate a :doc:`volume </storage/persistent-block-storage/index>` or boot
an :doc:`instance </compute/index>` from.

The pricing for uploaded images is per gigabyte hour (GB/h) for the combined used space for
all your private images. See our pricing list for more details.

Public images
-------------

Binero cloud provides images of popular operating systems that are publicly available in the platform. The public images is most common operating systems or appliances.
Binero cloud provides images of popular virtual machine images and operating systems from
official sources that are publicly available in the platform so that you can get started quickly.

Each image is configured to honour :doc:`cloud-init data <cloud-init-data>`. An included image is publicly available in the platform but an instance will instantiate its own block device with the image *as base* - meaning that nothing will never write to the actual image.
Each image is configured to honor :doc:`cloud-init <cloud-init>`. Images is always used
as a source from volumes or instances and the images themselves are never written to.

Private images
--------------

Its possible to create (based on an existing instance) or upload your own image. This might for instance be useful if you have a certain installation that you would frequently re-use (maybe a boot-strapped base installation that does check-in with some sort of automation framework). Alternatively, you might have had an installation at another cloud supplier and would like to re-use it in Binero cloud.
You can upload and store images that only you have access to on your account. You can create a
image from an existing :doc:`instance </compute/index>`, this can be useful if you already have
a certain configuration that you want to re-use.

You can bring any image that you want to use, for example from other cloud providers where you
already have a image that you want to use in Binero cloud as well.

Uploading an image
^^^^^^^^^^^^^^^^^^
To upload an image using the :doc:`/getting-started/managing-your-cloud/cloud-management-portal`, follow these steps:

- Press "Compute" and then "Images" in the sidebar menu.
- Enter an image name.
- Select and OS-distro and version, as well as architecture.
- Either select "URL" (and if so, enter the URL to the downloadable image) or "File" (and if so, select a compatible disk image file on your computer for upload).
- Leave remaining fields empty.
- Press "Create image".
.. note:: Customers can only upload private images and cannot set image visibility to public
or community as that would open up a security vulnerability for malicious images.

To upload an image using the :doc:`/getting-started/managing-your-cloud/cloud-management-portal`

- Press **Compute** and then **Images** in the sidebar menu

- Click the plus sign (+) in the bottom right corner

- Specify a image name

- Select the disk format that the image has

- Select a OS distro and version that matches what your image contains

- Set the architecture to x86_64 as this is the only supported architecture

- Set the visibility to private

- You can upload a image either using an URL that will be downloaded or
from a file on your computer, select what you prefer.

- You can leave any remaining fields empty unless you want to fill them
in as well.

- If you want to prevent your image from being accidentally deleted you
can set the image as protected which means it will need to be unprotected
in order for a delete on the image to be successful.

- Click **Create Image**

Creating image from instance
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Creating a private image from a current instance (that is, an instance which is running in the cloud) is done with the snapshot instance feature. Please see our :doc:`/storage/snapshots/create-snapshot` article which will detail creating an instance snapshot which is the same thing as creating a private image from a current instance.

Creating a private image from an existing instance that is available in the cloud
is done with the snapshot instance feature.

See the :doc:`/storage/snapshots/create-snapshot` documentation that details creating
an instance snapshot that can then be uploaded as an image.

Create instance from image
--------------------------
To create a new compute instance from an image, see our :doc:`launch-instance-from-image` article.

To create a new compute instance from an image, see the :doc:`launch-instance-from-image`
documentation.


.. toctree::
Expand All @@ -42,4 +84,4 @@ To create a new compute instance from an image, see our :doc:`launch-instance-fr

launch-instance-from-image
create-rescue-image
cloud-init-data
cloud-init
63 changes: 44 additions & 19 deletions images/launch-instance-from-image.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,44 +2,69 @@
Launch instance from image
==========================

When :doc:`snapshotting </storage/snapshots/index>` and entire instance, the end result is an :doc:`image <index>`. Restoring from a snapshot (assuming the entire instance was restored) is then the same as creating an instance from a private image.
When :doc:`snapshotting </storage/snapshots/index>` and entire instance, the end result is
an :doc:`image <index>`. Restoring from a snapshot (assuming the entire instance was restored) is
then the same as creating an instance from a private image.

When restoring an entire instance from a snapshot, which might be the case if for instance an upgrade failed post snapshot and you want to revert to the previous state, you would create a new instance from the image that was generated. This is a good method because it allows you to safely ensure that your new instance is up and running before deleting the old one (and not doing major changes to the only copy of the image).
When restoring an entire instance from a snapshot, which might be the case if for instance an
upgrade failed post snapshot and you want to revert to the previous state, you would create a
new instance from the image that was generated.

.. note:: While there is a feature in the cloud management portal to do an in place restore to the current instance, we *do not recommend it*, but rather that you follow below guide to create a new instance from the image.
This is a good method because it allows you to safely ensure that your new instance is up and
running before deleting the old one (and not doing major changes to the only copy of the image).

.. note:: While there is a feature in the cloud management portal to do an in place restore to
the current instance, we *do not recommend it*, but rather that you follow below guide
to create a new instance from the image.

Please follow our below guide from creating an instance from a private image using our various tools.

Cloud management portal
-----------------------

To create a snapshot using the :doc:`/getting-started/managing-your-cloud/cloud-management-portal`, follow these steps:
To create a snapshot using the :doc:`/getting-started/managing-your-cloud/cloud-management-portal`

- Click **Compute** and then **Images** in the sidebar menu

- On the image that you want to use as base, press the small arrow **Create from image**

- Enter a name

- Select a :doc:`flavor </compute/flavors>` in the **Configuration** field

- Choose a :doc:`availability zone </compute/regions-and-availability-zones>`

- If applicable choose a :doc:`SSH key </compute/ssh-keys>`

- Press "Compute" and then "Images" in the sidebar menu.
- On the image that you want to use as base, press the small arrow "create from image".
- Enter a name.
- Select a :doc:`flavor </compute/flavors>` under the "configuration" field.
- Choose and :doc:`availability zone </compute/regions-and-availability-zones>`.
- If applicable choose an :doc:`ssh-key </compute/ssh-keys>`.
- Choose a :doc:`private subnet </networking/router/private-subnet/index>`.
- Press "create".
- Choose a :doc:`private subnet </networking/router/private-subnet/index>`

- Click **Create**

OpenStack Horizon
-----------------

To create a snapshot using :doc:`/getting-started/managing-your-cloud/openstack-horizon`, follow these steps:
To create a snapshot using :doc:`/getting-started/managing-your-cloud/openstack-horizon`

- Under **Project**, click **Compute** and then **Images** in the sidebar menu

- Press **Launch** to the right on the row of the image

- Under "project", click "Compute" and then "Images" in the sidebar menu.
- Press "launch" to the right on the row of the image.
- Follow the remainder of the instructions in our :doc:`/compute/launching-an-instance/openstack-horizon` guide.
- Follow the the instructions in our :doc:`/compute/launching-an-instance/openstack-horizon` guide

OpenStack Terminal Client
-------------------------

To create a snapshot using the :doc:`/getting-started/managing-your-cloud/openstack-terminal-client`, follow these steps:
To create a snapshot using the :doc:`/getting-started/managing-your-cloud/openstack-terminal-client`

- List the images and save the name of the image you want to create a new
instance from

::

openstack image list --private

- Run this command: ``openstack image list --private``, save the name of the image you want to create a new instance from.
- Follow the instructions in our :doc:`/compute/launching-an-instance/openstack-terminal-client` guide, replacing the ``--image`` value from the public image in the example to your private image.
- Follow the instructions in our :doc:`/compute/launching-an-instance/openstack-terminal-client` guide
replacing the ``--image`` value from the public image in the example to your private image

.. seealso::
- :doc:`index`