Project

General

Profile

Feature #39258

Allow branch selection for iocage plugins

Added by Aaron St. John over 1 year ago. Updated over 1 year ago.

Status:
Done
Priority:
No priority
Assignee:
Brandon Schneider
Category:
Middleware
Target version:
Estimated time:
Severity:
Med High
Reason for Closing:
Reason for Blocked:
Needs QA:
No
Needs Doc:
No
Needs Merging:
No
Needs Automation:
No
Support Suite Ticket:
n/a
Hardware Configuration:

Description

Is there a way to make plugins disappear while in development? Perhaps an option in the INDEX or something in the plugin itself?

I have talked to Martin as well as Dru. This seems to be a desired feature among them. Reason being is that during development, if the plugin is available, users are trying to download it and it's not working. Thus, more unnecessary bug tickets about it.


Related issues

Related to FreeNAS - Bug #39638: Change iocage plugin mechanism to use branchesDone

Associated revisions

Revision 51b2c17e (diff)
Added by Brandon Schneider over 1 year ago

feat(jail/plugins): Allow branch selection for plugin fetching Ticket: #39258

Revision d41512d0 (diff)
Added by Brandon Schneider over 1 year ago

feat(jail/plugins): Allow branch selection for plugin fetching Ticket: #39258

History

#1 Updated by Dru Lavigne over 1 year ago

  • Subject changed from Make plugins unavailable while in development. to Make plugins unavailable while in development
  • Category changed from Services to Middleware
  • Assignee changed from Brandon Schneider to William Grzybowski
  • Target version changed from Backlog to 11.2-BETA2
  • Severity changed from New to Med High

#2 Updated by William Grzybowski over 1 year ago

  • Assignee changed from William Grzybowski to Brandon Schneider

#3 Updated by Jurgen Segaert over 1 year ago

The easiest option would be to hold off adding the plugins to the INDEX file (https://github.com/freenas/iocage-ix-plugins/blob/master/INDEX) until they are fully tested (or conversely remove the ones that aren't ready yet). Just add the "manifest" files (new_plugin.json).

There's a developer option in iocage to install a plugin directly from the manifest/json files; this is intended for testing the install process, something like:

iocage fetch -P -n /mnt/iocage/.plugin_index/new_plugin.json ip4_addr="em0|192.168.0.100/24" 

From iocage fetch --help:

  -P, --plugin-file               This is a plugin file outside the INDEX, but exists in that location.
                                  Developer option, most
                                  will prefer to use --plugins.

This what I did for the unofficial MineOS plugin, https://redmine.ixsystems.com/issues/32961

#4 Updated by Martin Wilke over 1 year ago

Hi Jurgen,

Yes and No, adding and removing a plugin from the INDEX takes to much time and the chance of breaking the INDEX is high too. Development is one thing and the right way as u said is to run it locally, but lets say we update the iocage portstree, and it turn out we break a plugin then it would be easier to make the plugin disappear for the moment from the index, ideally with a flag option in the plugin it self.

//Edit

In long term when we receive more Contribution of plugins from the Community this flag would even make more sense, as example for maintain the plugin etc.

- Martin

#5 Updated by Disk Didler over 1 year ago

Is there any way to set the permissions of the files to be marked as hidden or only for X users on the host site?

Alternatively what about an index file of sorts like "index-live" or "index-disabled" which is a text file and any names in said file, are hidden automatically in the UI? (will require code to check said text file and apply filter)

Finally what about a naming convention like
pluginname-BROKEN
or
pluginname-TESTING
if you can rename them?

Sorry, just throwing ideas out there, I'm not sure of the limitations of the source host of the files.
I do feel sorry for you all though, there's forums, reddit and bug posts being logged about broken things which simply shouldn't be tested yet (and I suspect I myself probably have fallen for it too)

#6 Updated by Brandon Schneider over 1 year ago

  • Status changed from Unscreened to In Progress

In discussions with Kris/William/Martin about this.

#7 Updated by Brandon Schneider over 1 year ago

  • Related to Bug #39638: Change iocage plugin mechanism to use branches added

#9 Updated by Brandon Schneider over 1 year ago

PR #1: https://github.com/freenas/iocage/pull/7
PR #2: https://github.com/freenas/iocage/pull/6
PR #3: https://github.com/freenas/freenas/pull/1601

DESC: Allows using a different branch by default for development (users will not see master unless specifically asking for it or are using HardenedBSD)
RISK: Low
ACCEPTANCE: Run iocage fetch -P --name PLUGIN IPADDRESS_PROPS --branch 'master' and you will see your changes. Don't include master, and you won't.

#10 Updated by Dru Lavigne over 1 year ago

  • Target version changed from 11.2-BETA2 to 11.2-BETA3

#11 Updated by Dru Lavigne over 1 year ago

  • Status changed from In Progress to Ready for Testing
  • Needs Merging changed from Yes to No

#13 Updated by Dru Lavigne over 1 year ago

  • Subject changed from Make plugins unavailable while in development to Allow branch selection for iocage plugins

#14 Updated by Timothy Moore II over 1 year ago

  • Status changed from Ready for Testing to Passed Testing
  • Needs QA changed from Yes to No

Testing with FreeNAS system updated to FreeNAS-11.2-MASTER-201808260839:

Log in, go to Shell, and use iocage fetch -P --name mineos ip4_addr="{nic|ipaddress/subnet}"
to install the mineos plugin. Verify

Using Branch: 11.2-RELEASE
is accurate.

Wait for plugin to finish installing and delete it completely. Reinstall the plugin using this command:

iocage fetch -P --name mineos ip4_addr="{nic|ipaddress/subnet}" --branch 'master'

Output confirms the master branch version of the plugin is being installed:

   Plugin: mineos
     Official Plugin: False
     Using RELEASE: 11.2-RELEASE
     Using Branch: master
     Post-install Artifact: https://github.com/jseqaert/iocage-plugin-mineos.git
     These pkgs will be installed:
     ...

#15 Updated by Timothy Moore II over 1 year ago

  • Needs Doc changed from Yes to No

Docs PR: https://github.com/freenas/freenas-docs/pull/320 [angulargui branch]. This change applies to the Angular gui only - no master branch changes needed.

#16 Updated by Dru Lavigne over 1 year ago

  • Status changed from Passed Testing to Done

Also available in: Atom PDF