9

I'd like to prepare an iso for unattended installation. So I generated a preeseed file to run through the installer automatically. Is it possible to download a bash script with wget and run it with bash directly in the first user's homedir (where the first user is the user account created by the installer)? What would the commands in the preseed file look like?

  • Does the answer have to include only an answer to Is it possible to download a bash script with wget and run it with bash directly in the first users homedir? ? Also, please define first users – hytromo May 12 '13 at 13:33
  • The first user is the user that is created by the installer – Josh May 18 '13 at 7:15
13

Here is how:

d-i preseed/late_command string in-target wget -P /tmp/ $server/script.sh; in-target chmod $+x /tmp/script.sh; in-target /tmp/script.sh`

Put this line into a preseed file and you can do everything in your system you are familiar with bash.

You have to replace $server with a webhost or a local ip of course.

| improve this answer | |
6

You can also use:

d-i preseed/run string run.sh

The run.sh file must be stored in the same directory from which the preseed file was downloaded.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.