How to create a plug-in that loads on startup and communicates with a separate process?

Hi there! As part of my work, I need to create a Photoshop plug-in or extension that does three things:

  1. Loads on startup
  2. Communicates with an external database via a Python module
  3. Can be easily distributed to many users working in a private network

I have written a prototype that successfully uses Websockets to communicate with our database (it’s basically a variation of the websockets-io example from the UXP Photoshop Plugin Samples repository). However, I am not sure how to make the plug-in load on startup. Currently, I launch Photoshop → Plugins menu → Development → Get Developer Tools → Load my plugin. This will not work in production, as users will need to see the plugin menu on startup and be able to work with it right away.

I read that you can package the plugin and install it, which causes it to show up in the Plugins menu on startup. The big problem with this is that we might not be able to manually install the plugin on every user’s machine, and I doubt we could ask the users to do so.

Is there any other way to make the plugin show up on launch?

Conversely, is there a way to programmatically install the packaged plugin at a specified location on a user’s computer? The users’ current workflow is that they log into their workstations and launch Photoshop from a customized show launcher that we wrote, so it shouldn’t be too hard to add a plugin installation script into the show launcher.

Some quick thoughts:

  • To control when your plugin loads in Photoshop, see the loadEvent property of the Photoshop manifest.

  • For the above to be of any use, you must have the plugin installed via a .ccx bundle. If you want to invoke this as part of your launcher, you should see if this article is of any use to you.

Hi Kerri!

Thank you so much for the super fast reply, I really appreciate it! :slight_smile: I read the article you linked about installing plugins from the command line using UPIA and I tried to install my plugin using it, but I got the following error message: “Failed to install, status = -410!”. Ok, so I looked at this table of error codes but I couldn’t find -410. Would you happen to know what it means?

Note that you can’t use the CLI tool until CCD 5.7 is released (starts March 31).