Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
itminedu
snf-image
Commits
b2b9a247
Commit
b2b9a247
authored
Oct 07, 2013
by
Nikos Skalkotos
Browse files
docs: Fix minor typos
parent
64a4d9d4
Changes
3
Hide whitespace changes
Inline
Side-by-side
docs/advanced.rst
View file @
b2b9a247
...
...
@@ -76,7 +76,7 @@ type.
image-info
++++++++++
This message type is used to display
random
progress information. It has an
This message type is used to display
arbitrary
progress information. It has an
extra *messages* field whose value is a list of strings. A valid ``image-info``
message looks like this:
...
...
docs/architecture.rst
View file @
b2b9a247
...
...
@@ -15,10 +15,11 @@ separate steps:
| 1. Fill the newly provisioned disk with Image data
| 2. Customize the Image accordingly
For (1), snf-image can fetch the Image from a number of backends, as we describe
later. For (2) snf-image spawns a helper VM and runs a number of configuration
tasks inside the isolated environment. Once the last task returns successfully,
the helper VM ceases and snf-image returns the newly configured disk to Ganeti.
For (1), snf-image can fetch the Image from a number of back-ends, as we
describe later. For (2) snf-image spawns a helper VM and runs a number of
configuration tasks inside the isolated environment. Once the last task returns
successfully, the helper VM ceases and snf-image returns the newly configured
disk to Ganeti.
The whole procedure is configurable via OS interface parameters, that can be
passed to snf-image from the Ganeti command line or RAPI.
...
...
@@ -47,10 +48,10 @@ creation of a helper VM image based on Debian Stable, using multistrap.
The snf-image-helper component runs inside a specific environment, which is
created and ensured by snf-image:
* The VM features a virtual floppy, containing an ext2 filesystem with all
* The VM features a virtual floppy, containing an ext2 file
system with all
parameters needed for image customization.
* The hard disk provided by Ganeti that we want to deploy and customize is
accessible as the first
v
irt
io
hard disk.
accessible as the first
V
irt
IO
hard disk.
* All kernel/console output is redirected to the first virtual serial console,
and eventually finds its way into the OS definition log files that Ganeti
maintains.
...
...
@@ -66,7 +67,7 @@ created and ensured by snf-image:
snf-image-helper
^^^^^^^^^^^^^^^^
This part runs inside the helper VM during bootup and undertakes customization
This part runs inside the helper VM during boot
-
up and undertakes customization
of the target disk. It does so, by running a number of :ref:`configuration
tasks <image-configuration-tasks>`. The exact tasks that should run, are
specified by rules found in the virtual floppy, placed there by *snf-image*,
...
...
@@ -83,37 +84,37 @@ The architecture is presented below:
.. _storage-backends:
Storage backends
^^^^^^^^^^^^^^^^
Storage back
-
ends
^^^^^^^^^^^^^^^^
^
As stated above, for step (1), *snf-image* is capable of fetching images that
are stored in a variety of different backends and then extracting them onto
the
newly created block device. The following backends are supported:
* **Local backend**:
The local backend is used to retrieve images that are stored on the Ganeti
node that the image deployment takes place. All local images are expected to
be
found under a pred
i
fined image directory. By default */var/lib/snf-image*
is
used, but the user may change this by overwriting the value of the
are stored in a variety of different back
-
ends and then extracting them onto
the
newly created block device. The following back
-
ends are supported:
* **Local back
-
end**:
The local back
-
end is used to retrieve images that are stored on the Ganeti
node that the image deployment takes place. All local images are expected to
be
found under a pred
e
fined image directory. By default */var/lib/snf-image*
is
used, but the user may change this by overwriting the value of the
*IMAGE_DIR* variable under ``/etc/default/snf-image``.
* **Network backend**:
The network backend is used to retrieve images that are accessible from the
network. snf-image can fetch images via *http:*, *https:*, *ftp:* or
*ftps:*,
using `cURL <http://curl.haxx.se/>`_.
* **Network back
-
end**:
The network back
-
end is used to retrieve images that are accessible from the
network. snf-image can fetch images via *http:*, *https:*, *ftp:* or
*ftps:*,
using `cURL <http://curl.haxx.se/>`_.
* **Pithos backend**:
* **Pithos back
-
end**:
*snf-image* contains a special command-line tool (*pithcat*) for retrieving
images residing on a Pithos installation. To set up snf-image's Pithos
backend
the user needs to setup the ``PITHOS_DATA`` and ``PITHOS_DB``
variables inside
``/etc/default/snf-image`` accordingly.
images residing on a Pithos installation. To set up snf-image's Pithos
back-end
the user needs to setup the ``PITHOS_DATA`` and ``PITHOS_DB``
variables inside
``/etc/default/snf-image`` accordingly.
* **Null backend**:
If the null backend is selected, no image copying is performed. This
actually
is meant for bypassing step (1) al
l
together. This is useful, if the
disk
provisioned by Ganeti already contains an OS installation before
*snf-image* is
executed (for example if the disk was created as a clone of
an existing VM's
hard disk).
* **Null back
-
end**:
If the null back
-
end is selected, no image copying is performed. This
actually
is meant for bypassing step (1) altogether. This is useful, if the
disk
provisioned by Ganeti already contains an OS installation before
*snf-image* is
executed (for example if the disk was created as a clone of
an existing VM's
hard disk).
.. _image-configuration-tasks:
...
...
@@ -138,13 +139,13 @@ by *SNF_IMAGE_PROPERTY_ROOT_PARTITION* variable under the directory specified
by *SNF_IMAGE_TARGET*. The script will fail if any of those 3 variables has a
non-sane value.
**AddSwap**: Formats the swap partion added by *FixPartitionTable* task and
**AddSwap**: Formats the swap parti
ti
on added by *FixPartitionTable* task and
adds an appropriate swap entry in the system's ``/etc/fstab``. The script will
only run if *SNF_IMAGE_PROPERTY_SWAP* is present and will fail if
*SNF_IMAGE_TARGET* in not defined.
**DeleteSSHKeys**: For
l
inux images, this script will clear out any ssh keys
found in the image and for
d
ebian, it will recreate them too. In order to find
**DeleteSSHKeys**: For
L
inux images, this script will clear out any ssh keys
found in the image and for
D
ebian, it will recreate them too. In order to find
the ssh keys, the script looks in default locations (/etc/ssh/ssh_*_key) and
also parses ``/etc/ssh/sshd_config`` file if present. The script will fail if
*SNF_IMAGE_TARGET* is not set.
...
...
@@ -158,24 +159,27 @@ of the Windows setup. The task will fail if *SNF_IMAGE_TARGET* is not defined.
needed by windows in order to perform an unattended setup. The
*SNF_IMAGE_TARGET* variables needs to be present for this task to run.
**SELinuxAutorelabel**: Creates *.autorelabel* file in RedHat images. This is
**SELinuxAutorelabel**: Creates *.autorelabel* file in Red
Hat images. This is
needed if SELinux is enabled to enforce an automatic file system relabeling at
the next boot. The only enviromental variable required by this task is
the next boot. The only enviro
n
mental variable required by this task is
*SNF_IMAGE_TARGET*.
**AssignHostname**: Assigns or changes the hostname in a Linux or Windows
image. The task will fail if the Linux distribution is not supported. For now,
we support Debian, Red
h
at, Slackware, SUSE and Gentoo derived distr
os. The
hostname is read from *SNF_IMAGE_HOSTNAME* variable. In addition to the
latter,
*SNF_IMAGE_TARGET* is also required.
we support Debian, Red
H
at, Slackware, SUSE and Gentoo derived distr
ibutions.
The
hostname is read from *SNF_IMAGE_HOSTNAME* variable. In addition to the
latter,
*SNF_IMAGE_TARGET* is also required.
**ChangePassword**: Changes the password for a list of users. For Linux systems
this is accomplished by directly altering the image's ``/etc/shadow`` file. For
Windows systems a script is injected into the VM's hard disk. This script will
be executed during the specialize pass of the Windows setup. The list of users
whose passwords will changed is determined by the *SNF_IMAGE_PROPERTY_USERS*
variable (see :ref:`image-properties`). For this task to run *SNF_IMAGE_TARGET*
and *SNF_IMAGE_PASSWORD* variables need to be present.
be executed during the specialize pass of the Windows setup. For FreeBSD
``/etc/master.passwd`` is altered, ``/etc/spwd.db`` is removed and a script is
injected into the VM's hard disk that will recreate the aforementioned file.
The list of users whose passwords will changed is determined by the
*SNF_IMAGE_PROPERTY_USERS* variable (see :ref:`image-properties`). For this
task to run *SNF_IMAGE_TARGET* and *SNF_IMAGE_PASSWORD* variables need to be
present.
**FilesystemResizeMounted**: Injects a script into a Windows image file system
that will enlarge the last file system to cover up the whole partition. The
...
...
docs/interface.rst
View file @
b2b9a247
...
...
@@ -116,7 +116,7 @@ Optional properties
+++++++++++++++++++
* **USERS="username1 username2...."**
This is a space-sep
e
rated list of users, whose password will be reset by
This is a space-sep
a
rated list of users, whose password will be reset by
*snf-image*. The use of this property is optional, but highly recommended.
For now, if this property is missing, the users are chosen according to a
set of rules, but those rules may change or even be dropped in the future.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment