play2-openshift-quickstart icon indicating copy to clipboard operation
play2-openshift-quickstart copied to clipboard

cannot access `/var/lib/openshift/5312c93b5004461e7400005c/app-root/runtime/repo/target/start': No such file or directory

Open strobe opened this issue 10 years ago • 3 comments

I followed on instructions and got this error at the last step:

  remote: Stopping DIY cartridge
  remote: Building git ref 'master', commit fe019f9
  remote: Preparing build for deployment
  remote: Deployment id is 3a0a6d6f
  remote: Activating deployment
  remote: Starting DIY cartridge
  remote: chmod: cannot access `/var/lib/openshift/5312c93b5004461e7400005c/app-root/runtime/repo/target/start': No such file or directory
  remote: -------------------------
  remote: Git Post-Receive Result: success
  remote: Activation status: success
  remote: Deployment completed with status: success

on the app page I got Service Temporarily Unavailable

strobe avatar Mar 02 '14 06:03 strobe

additional log

rhc app tail -a play2demo
Warning: This command is deprecated. Please use 'rhc tail' instead.

==> diy/logs/play.log <==
/var/lib/openshift/5312c93b5004461e7400005c/app-root/runtime/repo/target/start "-DapplyEvolutions.default=true" -Dhttp.port=8080 -Dhttp.address=127.5.248.129 -Dconfig.resource=openshift.conf
bash: /var/lib/openshift/5312c93b5004461e7400005c/app-root/runtime/repo/target/start: No such file or directory
/var/lib/openshift/5312c93b5004461e7400005c/app-root/runtime/repo/target/start "-DapplyEvolutions.default=true" -Dhttp.port=8080 -Dhttp.address=127.5.248.129 -Dconfig.resource=openshift.conf
bash: /var/lib/openshift/5312c93b5004461e7400005c/app-root/runtime/repo/target/start: No such file or directory

==> diy/logs/server.log <==
[2014-03-02 01:02:54] INFO  WEBrick 1.3.1
[2014-03-02 01:02:54] INFO  ruby 1.8.7 (2011-06-30) [x86_64-linux]
[2014-03-02 01:02:54] INFO  WEBrick::HTTPServer#start: pid=485231 port=8080
[2014-03-02 01:08:15] INFO  going to shutdown ...
[2014-03-02 01:08:15] INFO  WEBrick::HTTPServer#start done.

strobe avatar Mar 02 '14 06:03 strobe

in this case I started paly2demo application by this modification of .openshift/action_hooks/start script:

#!/bin/bash
# The logic to start up your application should be put in this
# script. The application will work only if it binds to
# $OPENSHIFT_INTERNAL_IP:8080

# loads $PLAY_PARAMS
. ${OPENSHIFT_REPO_DIR}.openshift/action_hooks/load_config

if [[ ! $? -eq 0 ]]; then
        exit $?
fi

LOG_FILE="${OPENSHIFT_DIY_LOG_DIR}play.log"

chmod +x ${OPENSHIFT_REPO_DIR}target/universal/stage/bin/${OPENSHIFT_APP_NAME}

APP_COMMAND="${OPENSHIFT_REPO_DIR}target/universal/stage/bin/${OPENSHIFT_APP_NAME} $PLAY_PARAMS "\
"-Dhttp.port=${OPENSHIFT_DIY_PORT} "\
"-Dhttp.address=${OPENSHIFT_DIY_IP} "\
"-Dconfig.resource=openshift.conf"

echo $APP_COMMAND &>> $LOG_FILE
nohup bash -c "${APP_COMMAND} &>> ${LOG_FILE} 2>&1" &> /dev/null &

but I don't sure that is right way because I don't know enough about openshift and cartridges

strobe avatar Mar 02 '14 07:03 strobe

encountered same problem

calidion avatar Mar 16 '14 03:03 calidion