~serge-hallyn/ubuntu/natty/lxc/lxc-fix-3bugs

« back to all changes in this revision

Viewing changes to scripts/lxc-debian.in

  • Committer: Bazaar Package Importer
  • Author(s): Guido Trotter
  • Date: 2009-07-25 12:24:30 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20090725122430-dxv1wb7ds07fc0sk
Tags: 0.6.3-1
* New Upstream Version
* Remove duplicate build-dependency on autotools-dev
* Build depend on linux-libc-dev
* Disable checking of netlink headers from configure
  (currently fails under sid)
* Upgrade standards-version to 3.8.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
5
5
 
6
6
NAME="debian"
7
7
CONFFILE="lxc.conf"
8
 
MNTFILE="mount.conf"
 
8
MNTFILE=
 
9
TMPMNTFILE=
9
10
UTSNAME=
10
11
IPV4="172.20.0.21"
11
12
GATEWAY="172.20.0.1"
135
136
lxc.network.link = br0
136
137
lxc.network.name = eth0
137
138
lxc.network.mtu = $MTU
138
 
lxc.mount = $MNTFILE
 
139
lxc.mount = $TMPMNTFILE
139
140
lxc.rootfs = $ROOTFS
140
141
lxc.cgroup.devices.deny = a
141
142
# /dev/null and zero
157
158
}
158
159
 
159
160
write_lxc_mounts() {
160
 
cat <<EOF > $MNTFILE
161
 
 
162
 
EOF
 
161
 
 
162
    TMPMNTFILE=$(mktemp lxc.XXXXXXXXXX)
 
163
 
 
164
    if [ ! -z "$MNTFILE" ]; then
 
165
        cp $MNTFILE $TMPMNTFILE
 
166
    fi
163
167
}
164
168
 
165
169
collect_information() {
214
218
    if [ ! -z "$_ROOTFS_" ]; then
215
219
        ROOTFS=$_ROOTFS_
216
220
    fi
 
221
 
 
222
    echo -n "Specify the location for an extra fstab file [(none)] "
 
223
    read _MNTFILE_
 
224
 
 
225
    if [ ! -z "$_MNTFILE_" ]; then
 
226
        MNTFILE=$_MNTFILE_
 
227
    fi
217
228
}
218
229
 
219
230
install_debian()
301
312
 
302
313
    # remove the configuration files
303
314
    rm -f $CONFFILE
304
 
    rm -f $MNTFILE
 
315
    rm -f $TMPMNTFILE
305
316
 
306
317
    if [ "$RES" != "0" ]; then
307
318
        echo "Failed to create '$NAME'"