I'm using Amazon Linux. I'm running an automated script through Jenkins with this command
Xvfb :10 -ac
However, if this command has already been run before, I get the error ...
(EE) Fatal server error: (EE) Server is already active for display 10 If this server is no longer running, remove /tmp/.X10-lock and start again. (EE)
How can I modify the above command to only run if there it was not already invoked before with the given variable?