[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Extra files with simple-cdd



Hi list!

I'm trying to build a debian install cd using simple-cdd with custom
packages and configuration files like SSH keys for remote access an so
on.

I'm using the default profile, and the default.packages works fine.
The command to build the iso is the following:


# pwd
/root/my-custom-cdd

# ./build-simple-cdd --profiles default --local-packages
$(pwd)/simple-cdd-profiles_*.udeb --extras
/root/my-custom-cdd/extras/authorized_keys2 --locale es_MX

Once the iso is created, the extra files are located in the simple-cdd
directory within the cd image, with the profile files:

# cd /media/cdrom/simple-cdd
# ls -1
authorized_keys2
default.downloads
default.packages
default.postinst
default.preseed
default.udebs


The problem is my default.postinst file, when I try to copy the
authorized_keys2 to the installed system. The permissions of this file
are

-r-xr-xr-x 1 root root    1437 2007-06-11 16:35 default.postinst

the content of this file is

#!/bin/sh
DIR=/target/media/cdrom/simple-cdd

mkdir -p /home/sensor/.ssh
cp $DIR/authorized_keys2 /home/sensor/.ssh/authorized_keys2

The user sensor is created in the default.preseed file, the mkdir
works but the copy isn't. I'd tried diferent values for the DIR
variable

/target/media/cdrom/simple-cdd
/cdrom/simple-cdd

but the cp can't find "make stat" the file authorized_keys2. What's wrong??

I found in /usr/lib/finish-install.d/14simple-cdd that the
default.postinst is executed using a copy located in
/target/usr/local/simple-cdd using a function called "in-target", but
I couldn't find any reference to that.

How can I copy an extra file to the installed system??


Thanks



--
------------------
DJD
 _



Reply to: