Forum Discussion

mblachford_3582's avatar
mblachford_3582
Icon for Nimbostratus rankNimbostratus
Dec 12, 2018

iRules/iRules LX distribution question

All,

 

Working with developing a nice iRules/iRulesLX package to federate some object storage systems. I've been developing it under a BigIP VE on my local machine, and exported it to a .tgz for import onto the F5 appliance. However, it encountered errors on import because the TMOS version I developed under was 13.X and the appliance (can't be upgraded) was on a revision of 12.X.

 

So the question is this; is there a guide on packaging iRules/iRules LX that spells out how to distribute these software packages? Aside from using the BigIP VE version that the appliance is using, what are the other options?

 

Thanks for taking the time to respond.

 

3 Replies

  • Although it is not clearly documented, you cannot export a workspace archive (a tgz file created by clicking the "Export..." button) created on a higher version to a lower version: e.g., v13 archive to v12. When you attempt, plugin creation would fail with the following error even "Import" (which is just gunzip + untar of the file) was successful.

    Data Input Error: Can't create plugin "/Common/TestPlugin", the workspace version is greater
    than the BigIP version. Workspace: "/Common/Test" Version: "13.1.1.2" BigIP version: "12.1.3.7" 
    

    If you really want to migrate your "workspace" from higher to lower, here's an unofficial way (hack) for migration. At least it worked for me. In short, do file by file copying.

    1. Create the workspace on the target box (e.g., v12) with the same name.
    2. Create the iRule and extension (Node). You do not need to actually write any code.
    3. Gunzip + untar the archive file (e.g., from v13) on the target box (anywhere. say $1).
    4. Copy the iRule file(s) under $1 to the $1. This should overwrite the file created in Step 2.
    5. Do the same for extension(s) (index.js): $1.

    Please note that BIG-IP V13.1 and later use Node.js version 6.9.1 by default, while the older versions use 0.12.18. ECMA6 features available on 6.9.1 do not run on 0.12.18, so code carefully.

    I hope this would help.

  • This is a really interesting question.

     

    The approach I recommend and promote taking your code off the F5 and build an independent development environment.

     

    Currently myself and others where I work have been working on a TypeScript iRule LX development framework with unit testing, code coverage and a delivery pipeline (auto compile to JS and deployment to F5)

     

    The current issue we are facing is delivery to a F5 device, currently this is being done manually with copying files like Satoshi has already suggested, but working to find a better way (via iControl REST would be best) sadly this is still a work in progress so cannot help beyond what Satoshi has already provided but if you find a good way to do this would love to see your method.