Date: Sat, 11 Mar 2000 18:11:52 +0000 From: dom@happygiraffe.net (Dominic Mitchell) To: Brian Somers <brian@Awfulhak.org>, Nik Clayton <nik@FreeBSD.org>, Lee Johnston <lee@uk.freebsd.org>, freebsd-users@uk.freebsd.org, brian@hak.lan.awfulhak.org, freebsd-isp@FreeBSD.org Subject: ispsetup (was: Re: FreeBSD in Dixons) Message-ID: <20000311181152.A1206@myrddin.demon.co.uk> In-Reply-To: <20000311000931.A349@myrddin.demon.co.uk>; from Dominic Mitchell on Sat, Mar 11, 2000 at 12:09:31AM %2B0000 References: <nik@FreeBSD.org> <200003100835.IAA00469@hak.lan.Awfulhak.org> <20000311000931.A349@myrddin.demon.co.uk>
index | next in thread | previous in thread | raw e-mail
[-- Attachment #1 --]
On Sat, Mar 11, 2000 at 12:09:31AM +0000, Dominic Mitchell wrote:
> On Fri, Mar 10, 2000 at 08:35:30AM +0000, Brian Somers wrote:
> > So, how about
> >
> > /usr/share/isp/defaults
> > /usr/share/isp/uk/defaults
> > /usr/share/isp/uk/pavilion
> > /usr/share/isp/uk/demon
> > /usr/share/isp/uk/bt
> > /usr/share/isp/uk/force9
> >
> > etc ? These files would contain the standard bourne shell variable
> > assignments, and then there'd be
> >
> > genconfig [-pnmlis] [otheroptions]
> >
> > where the above flags generate configurations for ppp, named, mail,
> > leafnode, innd and squid respectively. We'd also want flags like
> > -d domain to auto-specify your domain etc.
> >
> > Any interest in something like this ?
>
> Sounds like an excellent idea. Whilst one can shoehorn everything into
> one big ppp.conf and call it as necessary, the other config files would
> be a lot more difficult.
>
> > I think the main thing here is to make it easy to add new options -
> > for example:
> >
> > /usr/share/isp/uk/someisp
> > phone=1234567
> > services=ppp
> > domain=someisp.co.uk
> >
> > Would tell the program that it can generate a ppp.conf with the
> > standard template and only the phone number specified. It would then
> > prompt for your authname/authkey and ask if you want to use a login
> > script (it would generate one with \\U & \\P). Or
> >
> > /usr/share/isp/uk/demon
> > phone=1234567
> > pppdns=false
> > proxy=www-cache.demon.co.uk
> > services=ppp,squid,leafnode
> >
> > where it prompts for your host/domain, authname and authkey, and allows
> > you to configure squid using the given proxy) and leafnode using the
> > standard news.domain.
>
> This sounds more and more interesting. Why didn't somebody do this
> years ago?
>
> I'll have a go at throwing together a sample implementation tonight
> (it's only midnight and I'm bored :) and see what I come up with.
Right, I have a simple prototype ready. I've attached a file called
ispsetup.tar.gz. Extract it in ~/tmp. I've only implemented ppp.conf
setup, but others can work along similiar lines. Basically, it just
collects parameters and m4's them into config files.
It uses two file-hierarchies, .../isp, which is where the shell-style
isp definition files are stored. Also, there is .../isp-templates which
contains template configuration files, one per service. I've also set
up the script to dump config files into .../isp-destdir, just so it
doesn't overwrite your own config files!
ispsetup also uses defaults files, like Brian described.
To run it, just give it a filename, relative to .../isp. eg:
$ ispsetup.sh uk/demon
Optionally, you give a list of which services to configure on the
command line after the file. This will be more useful when I've
implemented more than one. :-)
Comments:
* It *really* needs a better interface. I think dialog would be good
and would match tzsetup(8).
* It really shows why you should do stuff like this in perl or python.
Some of sh's programming constructs are very obscure and
unmaintanable...
* We need to sit down together and figure out 90% of the variables
needed to configure each service for an isp. There are a number of
issues involved. The biggie for me is how to do resolv.conf
correctly, even in the case of multiple isp's (not all of them give
DNS configuration through IPCP).
* A number of configuration issues depend on which port/package has been
installed. eg: sendmail vs postifx vs exim vs qmail or perhaps squid
vs. wwwoffle. I'm not entirely sure how best to approach this.
Anyway, have a look and let me know what you think.
-Dom
[-- Attachment #2 --]
t8 Y{sFѧΘ-;]86ɺgs,||nrع6f{z݃''jY6 'j
сh6Z6&xAf!ò9z^d&߶MeV$T{ؖj}X~}, n5d=CQ/#!<?&I^؛}Й1}jFѐ"\!;a4EǴ>mv7
̫df`!Bg8^u{Ζ47:RZf|iwLin7jvcV4h)Hd˧&j~/E{D*g.pI ao-)t,dHP<iP& .b'js 2ߦkK䏖.Xs'_]{x8nۭm4
+
Hҁ :yP?~rqՉ&Ĉn(|,v7-)#i
*zLLTrbBAʅI#u.1H1a9s
(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