Exporting

Ben Leibig leibig at interfaze.net
Wed Jun 23 13:58:13 PDT 1999



> -----Original Message-----
> From: Ivan Kohler [mailto:ivan at sisd.com]
> Sent: Wednesday, June 23, 1999 5:23 AM
> To: ivan-freeside at sisd.com
> Subject: Re: Exporting
>
>
> On Wed, Jun 23, 1999 at 02:25:34AM -0600, Ben Leibig wrote:
> > I'm trying to export user shell accounts to systems which ALREADY have a
> > password file... I tried it, and freeside overwrote the passwd
> and shadow
> > files with new ones that only had one entry.
>
> You could have imported the passwd and shadow files first.
>
Yeah, realize that now, but this still doesn't really do what I want since I
have all sorts of other utlities(such as unix passwd) that make changes to
the password and shadow files and would get overwritten by freeside each
night.
> > What I'd really like to do is change freeside so instead of
> writing a whole
> > new password file every time it just creates the new entries necessary,
> > copies them to passwd.new on the remote system, and then
> appends them to the
> > end of the file
> >
> > cat passwd.new >> passwd
> >
> > Is this possable?
>
> With the source, anything is possible.  ;)
>
> For a transaction (adding a single user), you probably want to add a
> `shellmachine' (as opposed to `shellmachines') configuration file.  See
> htdocs/docs/export.html.  You can then modify the insert method in
> site_perl/svc_acct.pm to do what you want.  You will probably also need to
> edit the replace and delete methods.
Why, what is the difference between shellmachine and shellmachines?
>
> MHO is to import first.  The socratic question I'd ask about what you plan
> to do is "How do you prevent duplicate usernames?"
>
Simple, in my case the freeside machine and the shell machine are the same
system, what I would like to do is just check if that username is already
used on system which freeside is running on, and, well, that's that.  I'm
not really sure how to do this however.  I am just learning perl, can you
atleast point me to the right place to start poking around...

> (Not that the hooks in svc_acct.pm couldn't be changable via config files)
>
???


You'll have to excuse me, I'm not a great perl programmer, but if you could
help me hack this out it would be great.  This solution offers a method
which makes freeside much more integrateable into other systems... Maybe I'm
being silly and there's ways to do all of this with the import method, I'd
be interested in using it if that was the case.  Where can I find more
info...

	Ben




More information about the freeside-users mailing list