I'm doing this now. Attached is a VERY simple shell script (netload.sh)
that downloads and installs the lrp files, using the tftp binary (aprox
19k, uncompressed) that I've compiled from the www.linuxassembly.org
project. The config file (netload.conf) just contains the tftp
instructions (one per line). The init.d file (netload) just makes it so
that the packages are downloaded and installed upon startup. I've
noticed the machine will hang on startup if it cannot access the tftp
server though... I haven't taken the time to diagnose that issue...

In the netload.sh file, "server.domain.com" should be the name of your
tftp server.

I'm planning on getting this to work for the ipsec.lrp package as well.
The only change to the sshd.lrp and ipsec.lrp packages, is that I've
moved the config files out of their packages, and into the main etc.lrp
backup (ie: I removed the /etc/sshd/* and /etc/ipsec.* lines from the
corresponding /var/lib/lrpkg/sshd.list and ipsec.list files). This way I
can keep the private key data private, and have a central (and simple)
repository for all of my VPN servers and firewalls to pull the packages
from when needed. 

I'd like to someday add the capability to md5 the .lrp files so that I
can feel safe pulling them across the internet (ie: reduce the chance of
a MITM attack). Of-course, I'd like to add some basic error checking,
and also get these files rolled into a .lrp, but for now...

To install it:
 download and compile the tftp tool from www.linuxassembly.org
 copy the compiled tftp binary to /usr/local/bin/
 copy netload.sh to /usr/local/bin/
 set /usr/local/bin/netload.sh and /usr/local/bin/tftp as executable
 copy netload to /etc/init.d/
 copy netload.conf to /etc/
 backup etc.lrp, and local.lrp

I hope this helps,
Gregg Berkholtz

On Mon, Jun 03, 2002 at 06:22:16AM -0700, T Burt wrote:
> If I can come up to speed quickly enough, I would be glad to help.
> 
> One feature that I particularly liked in Trinux, is the ability to 
> download packages from an ftp or http server during system startup.  
> 
> This takes the pressure off the space limitations of the floppy, and 
> allows one to include more functionality if you have the RAM to spare.
> 
> There are security considerations if you are booting a firewall, but for 
> other purposes, it can be very useful.
> 
> Has anyone considered using snarf to retrieve packages from a nearby 
> server?  Just think..  A real shell, a real vi and sshd without giving up 
> something important!
> 
> Also...
> 
> In Trinux, Matt dynamically sets up the size of the ramdisk based on the 
> available memory.  More memory = more ramdisk.
> 
> If there is the possiblity of getting these features into your release, I 
> might take the initiative.
> 
> Thanks!
> 
> -- 
> --------------------
> Timothy Burt
> Internet Specialist
> 
> 
> _______________________________________________________________
> 
> Don't miss the 2002 Sprint PCS Application Developer's Conference
> August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm
> 
> ------------------------------------------------------------------------
> leaf-user mailing list: [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/leaf-user
> SR FAQ: http://leaf-project.org/pub/doc/docmanager/docid_1891.html

#! /bin/sh

# /etc/init.d/sshd: start/stop sshd daemon

RCDLINKS="2,S90"

test -x /usr/local/bin/tftp || exit 0
 
/usr/local/bin/netload.sh

exit 0
get sshd.lrp
get libz.lrp
#!/bin/sh
#
# Ad-hock netload script using tftp.
# Download, install and activiate the SSH daemon on this host.
#
# Copyright (C) Gregg Berkholtz
# 
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
# 
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
# 
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
# 

cd /tmp
if [ -e /tmp/sshd.lrp ] ; then
  rm sshd.lrp
fi
if [ -e /tmp/libz.lrp ] ; then
  rm libz.lrp
fi

cat /etc/netload.conf |/usr/local/bin/tftp server.domain.com
echo " "
lrpkg -i sshd
lrpkg -i libz
rm sshd.lrp
rm libz.lrp

Attachment: msg07226/pgp00000.pgp
Description: PGP signature

Reply via email to