[DAEMON-311] Improve appcd plugin management

GitHub Issuen/a
TypeNew Feature
Resolution Date2020-04-14T21:25:39.000+0000
Affected Version/sn/a
Fix Version/sAppc Daemon 4.0.0
Componentsappcd, appcd-core
ReporterChris Barber
AssigneeChris Barber


Appc Daemon needs a better way to install and manage appcd plugins.


Currently, appcd plugins are installed via the appcd-default-plugins package. When the appcd-default-plugins package is installed (via appcd-core, via appcd), it will attempt to download and install the packages in an npm script. However, npm runs scripts as "nobody" which generally does not have access to the user's home directory on macOS and Linux and thus no plugins are installed. Plugins cannot be marked as traditional dependencies since we need to support multiple major versions installed side-by-side. Whenever the Appc Daemon is started, it will attempt to reconcile and install the default plugins. This solves the permission issue, but now requires you to start the daemon while online to download the plugins.


1. Migrate plugin install logic from appcd-default-plugins to appcd-core. 2. Add a appcd pm command that would allow users to install the default plugins, setup local dev plugins, install 3rd party plugins, uninstall plugins, and view installed plugins. Subcommands include list, install, uninstall, search, update, and view. 3. Add a file to appcd containing the prescribed default plugin list based on the list currently in appcd-default-plugins. a. We could elect to lockdown plugin versions instead of using semver ranges. b. We could check online to download an updated list so that we don't have to ship a new appcd whenever we want to update plugins. 4. Add a appcd setup command that leverages the plugin command's logic (from #1) to reconcile and install the default appcd plugins defined in the list (from \#2). Note that appcd setup is generic in nature and can be used to configure specific behavior such as telemetry opt-in and proxy settings. 5. After appcd is installed, an npm script would print a message instructing the user to run "appcd setup". Note that no appcd plugins would be installed at install time via an npm script. 6. Remove appcd-default-plugins. At runtime, instead of attempting to reconcile and install the default plugins, print the "Run: appcd setup" message.


  1. Chris Barber 2020-04-14 PR: https://github.com/appcelerator/appc-daemon/pull/468

JSON Source