2

I'm configuring a kickstart profile and I'd like to create some script file.

I'm doing like this:

cat <<EOF >>/scripts/myfile.pl
#!/usr/bin/perl
...
my $int;
`useradd me`;
...
EOF

After the PXE boot and installation process, when I check the file, everything starting with "$", and line starting with backquote disappeared.

Back-slashing backquotes seems to have worked, but not $.

Is there a way to make this work ?

dmourati
  • 25,540
  • 2
  • 42
  • 72
Bastien974
  • 1,896
  • 12
  • 44
  • 62

1 Answers1

3

Try: cat <<'EOF' >>/scripts/myfile.pl

This is a parameter substitution issue.

dmourati
  • 25,540
  • 2
  • 42
  • 72