Im running two forge servers, L5 is on server 1 (with beanstalkd) and Lumen on server 2.
Server 2 is used purely as an API and at some point it needs to inform Server 1 that a certain action has been fired, so that Server 1 could process the command, since Server 1 has all the commands.
Is it possible to fire an Event from Lumen (server2) but listen/process it on Server 1 ?
Or using a Queue:push from Lumen is the best solution for this?
Whether what I'm going to suggest is the best way, I don't know. There may be better ways to accomplish this.
Use Curl! You could file a Curl request to a server with all the required information. The Server could verify the sender of the request either using some kind of token, or IP if the server won't be changing. A token may be more secure however.
Yea cause it makes sense to use Lumen as the API endpoint which could queue jobs for L5 app to process.
I managed to add a job to L5 server (beanstalkd) however the constructor of the job class is called only on the Lumen server and so L5 calls the handle method with no data