1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
|
.. Open Infrastructure: compute-tools
.. Copyright (C) 2014-2021 Daniel Baumann <daniel.baumann@open-infrastructure.net>
..
.. SPDX-License-Identifier: GPL-3.0+
..
.. This program is free software: you can redistribute it and/or modify
.. it under the terms of the GNU General Public License as published by
.. the Free Software Foundation, either version 3 of the License, or
.. (at your option) any later version.
..
.. This program is distributed in the hope that it will be useful,
.. but WITHOUT ANY WARRANTY; without even the implied warranty of
.. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
.. GNU General Public License for more details.
..
.. You should have received a copy of the GNU General Public License
.. along with this program. If not, see <https://www.gnu.org/licenses/>.
=======================
container-build-debconf
=======================
-----------------------------------------------------
Build an advanced Debian based container with debconf
-----------------------------------------------------
:manual section: 1
:manual group: Open Infrastructure
Synopsis
========
| **container build -s debconf** ['OPTIONS']
| **cnt b -s debconf** ['OPTIONS']
| **container build -s debian** ['OPTIONS']
| **cnt b -s debian** ['OPTIONS']
| **container build -s progress-linux** ['OPTIONS']
| **cnt b -s progress-linux** ['OPTIONS']
Description
===========
The debconf container build script uses debconf(1) to automatically build a
Debian based container.
Scope
-----
Note that this container build script can do a few things more than just
automatically debootstrap based on a preseed file. It also allows you to set a
root password, configure the network, install certain packages and execute
hooks.
But: this is *not* a replacement for a configuration management system (like
ansible, puppet, etc.). The intenion of this script is to build the initial
container to that extend that a configuration management system can take over.
As an analogy, think of debian-installer: d-i sets up your system to make it
ready to boot and connect to the network. Everything after that is out of scope.
Same goes for this script.
Functions
---------
This script performs the following configuration on top of a Debian based
system:
* network
* root password
* apt repositories
* \.\.\.
Modes
-----
This container build script can be used under two different names: debian and
progress-linux.
Alternative, calling it under the debconf name is equal to the debian mode.
Preseeding
----------
Hierarchy of Preseed Files:
* The debconf script can be fully preseeded. Such preseed files can include
one or more preseed files themselfs (currently, only one layer of includes
is supported, no nested or recursive includes).
* The general rule of 'the later preseed file overwrites the earlier' applies.
The debconf script reads the main preseed file (specified either on command
line or by debconf selection/input dialog) after any included preseed files
in there.
* That means that debconf values after the include statement in the main
preseed file can overwrite any values specified in the included preseed
files.
Options
=======
The following script options are available:
-n, --name='NAME':
Specify container name.
-p, --preseed-file='FILE':
Specify the preseed file.
Examples
========
Build a Debian based container:
sudo container build -s debian -n debian.example.net
Build a Progress Linux container:
sudo container build -s progress-linux -n progress.example.net
Files
=====
The following files are used:
/etc/compute-tools/config:
Container configuration files.
/usr/share/compute-tools/build-scripts:
Container build scripts.
/usr/share/doc/compute-tools:
Container documentation.
/var/lib/machines:
Container directory.
/var/cache/container:
Container cache directory.
/tmp/compute-tools:
Container temporary directory.
See also
========
| compute-tools(7),
| container(1).
Homepage
========
More information about compute-tools and the Open Infrastructure project can be
found on the homepage (https://open-infrastructure.net).
Contact
=======
Bug reports, feature requests, help, patches, support and everything else are
welcome on the Open Infrastructure Software Mailing List
<software@lists.open-infrastructure.net>.
Debian specific bugs can also be reported in the Debian Bug Tracking System
(https://bugs.debian.org).
Authors
=======
compute-tools were written by Daniel Baumann
<daniel.baumann@open-infrastructure.net> and others.
|