Results 1 to 5 of 5

Thread: First attempt at something useful with Python

Hybrid View

  1. #1

    First attempt at something useful with Python

    So I wrote a python script to run with our Red Hat/Fedora kickstart installs. This runs in the %pre section, which is done before anything else, and then later on in the file, I can %include the files I write out to with this script.

    Basically this script will probe for what disk drives are on the system, and then set up partitioning schemes accordingly, with some rules about the size of the first disk, the amount of free space found on other disks, or if there are any Linux partitions on other disks for which to take over. Also it looks at the cmdline (all boot time options show up in /proc/cmdline) for arguments for the package set and whether or not to do an interactive install.

    Feel free to point and laugh, but please do offer any criticism you see fit.

    http://geek.j2solutions.net/stuff/autokickfc2.py

  2. #2
    Mentor coltrane's Avatar
    Join Date
    May 2001
    Location
    North Carolina
    Posts
    1,390

    Re:First attempt at something useful with Python

    I have no clue about anything related to Python, but what a cool idea....

  3. #3
    Senior Member
    Join Date
    Nov 2001
    Posts
    419

    Re:First attempt at something useful with Python

    I'll take a look at it. I'm no expert Python coder, but I've dabbled in it a bit. When it comes to PHP I'm a bit better. Few more years of experience. ;-)

    Seems like a neat idea. Too bad I don't use Fedora.

  4. #4
    Guest

    Re:First attempt at something useful with Python

    that script looks pretty good to me

    i would seperate the packages from the code and put them in a config file though, but other than that, it looks good

  5. #5

    Re:First attempt at something useful with Python

    [quote author=Ralinx link=board=9;threadid=9510;start=0#msg86752 date=1090146860]
    that script looks pretty good to me

    i would seperate the packages from the code and put them in a config file though, but other than that, it looks good
    [/quote]

    Sure, if it was standalone or something. As it stands, during the pre-script section of kickstart, I have to wget this file from a server then execute it. So I wanted it all in one file. But yeah, otherwise it would have gone into it's own file for use by other things as well.

Similar Threads

  1. Python Help
    By jmn0729 in forum Linux - General Topics
    Replies: 1
    Last Post: 11-02-2008, 11:44 AM
  2. Linuxfoo logo attempt
    By Wildheart in forum General Chat
    Replies: 5
    Last Post: 06-25-2005, 05:26 AM
  3. Python or C
    By wmartino in forum Linux - Software, Applications & Programming
    Replies: 2
    Last Post: 01-20-2005, 09:06 PM
  4. Python Rocks!
    By cga in forum Linux - Software, Applications & Programming
    Replies: 9
    Last Post: 11-29-2002, 02:52 PM
  5. Python
    By behnam in forum Linux - Software, Applications & Programming
    Replies: 2
    Last Post: 09-26-2002, 11:34 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •