<commit_before># Creating an Azure image

## Prerequisites

* A Libvirt master with the standard Alces setup
* Azure credentials configured on the machine, the command-line utility must be installed
* `qemu-img` version 2.9.0 or above available as a binary in `/opt/vm` (or change the pathname in the script)

## Creating an image

* Run the `create` script, this will build an Azure ready image and place it in the `/opt/vm` directory. The `create` script accepts some basic options, including customizing the name of the image.

## Uploading the image

* Run the `make-azure-image` script, with the full image path as the only argument, e.g.

```bash
./make-azure-image /opt/vm/my-image-1234.qcow2
```

This will upload the image for use on Azure. You can now create a virtual machine from the created image.
<commit_msg>Note reason for `qemu-img` version requirement<commit_after># Creating an Azure image

## Prerequisites

* A Libvirt master with the standard Alces setup
* Azure credentials configured on the machine, the command-line utility must be installed
* `qemu-img` version 2.9.0 or above available as a binary in `/opt/vm` (or change the pathname in the script). This can be obtained from Julius. The latest version is required in order to use the `subformat=force_size` option when converting the image.

## Creating an image

* Run the `create` script, this will build an Azure ready image and place it in the `/opt/vm` directory. The `create` script accepts some basic options, including customizing the name of the image.

## Uploading the image

* Run the `make-azure-image` script, with the full image path as the only argument, e.g.

```bash
./make-azure-image /opt/vm/my-image-1234.qcow2
```

This will upload the image for use on Azure. You can now create a virtual machine from the created image.

{'fraction_non_alphanumeric': 0.07738748627881449, 'fraction_numerical': 0.008781558726673985, 'mean_word_length': 4.120786516853933, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '317319', 'n_tokens_mistral': 522, 'n_tokens_neox': 499, 'n_words': 265}