Развертывание приложения на SailsJS к OpenShiftЗагрузка "bower_task.js" задачи ... ОШИБКА, об ошибках: EACCES, разрешение отказано .local
Развертывание ж/git push
remote: ├── [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected])
remote: ├── [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
remote: ├── [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected])
remote: ├── [email protected]
remote: ├── [email protected] ([email protected], [email protected], [email protected])
remote: ├── [email protected] ([email protected], [email protected], [email protected])
remote: ├── [email protected] ([email protected], [email protected])
remote: ├── [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected])
remote: └── [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
remote: npm info ok
remote: Preparing build for deployment
remote: Deployment id is bf24b845
remote: Activating deployment
remote: Loading "bower_task.js" tasks...ERROR
remote: >> Error: EACCES, permission denied '/var/lib/openshift/574f48527628e1bce8000273/.local'
remote: Warning: Task "bower:install" not found. Use --force to continue.
remote:
remote: Aborted due to warnings.
remote: -------------------------
remote: Git Post-Receive Result: failure
remote: Activation status: failure
remote: Activation failed for the following gears:
remote: 574f48527628e1bce8000273 (Error activating gear: CLIENT_ERROR: Failed to execute: 'control start' for /var/lib/openshift/574f48527628e1bce8000273/nodejs
remote: #<IO:0x0000000069e290>
remote: #<IO:0x0000000069e218>
remote:)
remote: Deployment completed with status: failure
remote: postreceive failed
To ssh://[email protected]/~/git/webrtc.git
df77e95..dc8b186 HEAD -> master
Любые идеи как это исправить?
ОБНОВЛЕНИЕ
Добавить крючки для действий. Отдается в this thread
cd .openshift/action_hooks
Я добавил код в существующий действия крюка pre_start_nodejs
#!/bin/bash
export NODE_ENV=production
if [ ! -d $OPENSHIFT_NODEJS_DIR/node_modules/bower ]
then
cd $OPENSHIFT_NODEJS_DIR
npm install bower
fi
cd $OPENSHIFT_HOMEDIR/app-root/repo
HOME=$OPENSHIFT_REPO_DIR bower install
cd $OPENSHIFT_HOMEDIR
if [ -f "${OPENSHIFT_REPO_DIR}"/Gruntfile.js ]; then
(cd "${OPENSHIFT_REPO_DIR}"; node_modules/grunt-cli/bin/grunt prod)
fi
Это помогло мне двигаться вперед, но я до сих пор застрял с Error: EACCES, permission denied
в .local
UPDATE 2
В package.json
, добавлено
"build": "HOME=$HOME/app-root/runtime bower install --config.interactive=false && grunt build",
но не помогло
UPDATE 3
1 - rhc ssh proyectname
2 - cd nodejs
3 - npm install bower
4 - cd ..
5 - export HOME=$HOME/app-root/runtime/repo
6 - cd app-root/repo
7 - bower install
не Решенный
Я из идей.
Я понимаю, что bower
не имеет доступа к .local
, но не знаю, как решить