You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
calculate-overlay/sys-apps/calculate-toolkit/files/calculate-toolkit-0.3.0-che...

55 lines
1.7 KiB

diff --git a/cl-lxc b/cl-lxc
index bc19594..2cdcc11 100755
--- a/cl-lxc
+++ b/cl-lxc
@@ -323,17 +323,17 @@ check_vars(){
if [ ! -e $path_lxc ]
then
printf $"No operation specified. Call %s to create a container.\n" \
- "'$program_name -c $name_lxc'" >&2
+ "'$program_name --create $name_lxc'" >&2
exit 1
elif [ ! -d $path_lxc_prepare ]
then
printf $"No operation specified. Call %s to prepare an update image for the container.\n" \
- "'$program_name -p $name_lxc'" >&2
+ "'$program_name --prepare $name_lxc'" >&2
exit 1
elif [ -d $path_lxc_prepare ]
then
printf $"No operation specified. Call %s to update the container.\n" \
- "'$program_name -u $name_lxc'" >&2
+ "'$program_name --upgrade $name_lxc'" >&2
exit 1
else
print_help "usage" >&2
@@ -534,7 +534,10 @@ update_prepare() {
ebegin $"Creating mount points"
for mount_point in $(grep '^lxc.mount.entry' $path_work/$name_upgrading/config | awk {'print $4'})
do
- mkdir -p "$path_lxc/rootfs/$mount_point"
+ if [ ! -e "$path_lxc/rootfs/$mount_point" ]
+ then
+ mkdir -p "$path_lxc/rootfs/$mount_point"
+ fi
done
eend
@@ -551,6 +554,7 @@ update_prepare() {
einfo $"Launching package update"
lxc-attach $name_lxc -- cl-update -f
rm -rf "$path_lxc/rootfs/var/calculate/{tmp/*,templates/*}"
+ find $path_lxc/rootfs/etc/init.d -type l -name net.* -exec unlink {} \;
cd $path_lxc/rootfs/etc/runlevels/boot
ln -s /etc/init.d/calculate .
cd - &>/dev/null
@@ -582,7 +586,7 @@ update_prepare() {
[ $diff_ == 1 ] && diff_pkg
- einfo $"Image for update ready. Now you can run '$program_name -u $name_upgrading' to update."
+ einfo $"Image for update ready. Now you can run '$program_name --upgrade $name_upgrading' to update."
return
}