I use a WildFly application server in a Java environment on OpenShift. In my pom.xml
file I have specified to run bower install
(with the exec-maven-plugin
).
Running bower install
with exec-maven-plugin
requires the presence of Bower on the operating system but by default my OpenShift instance hasn't Node.js & Bower installed.
Is it possible to install Bower per Action Hook?
I have tried the following with a "pre-build action hook":
/.openshift/action_hooks/pre_build
#!/bin/bash
npm install -g bower
I have also executed the following:
git update-index --chmod=+x .openshift/action_hooks/pre_build
But it looks like that my Action Hook is not executed:
Not stopping cartridge wildfly because hot deploy is enabled
Repairing links for 1 deployments
Syncing git content to other proxy gears
Building git ref 'master', commit f330f6d
No such file or directory - /var/lib/openshift/54e8f8984382ecc9a1000047/app-root/runtime/repo/.openshift/action_hooks/pre_build
Looks like, it IS executed. If the bash scripting file under the hooks directory would itself be missing, it would not complain.
Apparently something happens in the file that returns a "no such file ..." error.
Try to play around with some echo statements in the script to see that it's executed and to find out what's happening further.