Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
Bryan Taylor
@brylor
How horrible would it be to add more fields into components? I want to track poh on hours for drives, installed dates, etc... but I can't use a custom key
just make a migration and add the admin field?
✪ vi4m Marcin Kliks
@vi4m
Why is the custom field not enough in your case?
Bryan Taylor
@brylor
I'm not seeing how I would associate a specific drive's serial number to it's actual POH... unless I used custom field for serial and POH but I feel im breaking the model ?
gatvo
@gatvo
How can I add a management IP to an asset through the API?
✪ vi4m Marcin Kliks
@vi4m
@gatvo look at the ralph-cli sources, there's an example there
Bryan Taylor
@brylor
@gatvo I came up with this in ruby, its pretty crufty atm but it seems to work https://gist.github.com/brylor/599f3002c1579567ba806a6ed73bbd5b
be wary of trailing slashes with the API
✪ vi4m Marcin Kliks
@vi4m
looks good
Bryan Taylor
@brylor
thanks! :)
sigh, docker is such a bear sometimes
Bryan Taylor
@brylor
latest git pull, docker-compose up gets me:
npm http GET https://registry.npmjs.org/es6-iterator/-/es6-iterator-2.0.0.tgz
npm http 200 https://registry.npmjs.org/es6-iterator/-/es6-iterator-2.0.0.tgz

> node-sass@3.8.0 install /opt/ralph/node_modules/gulp-sass/node_modules/node-sass
> node scripts/install.js

Binary downloaded and installed at /opt/ralph/node_modules/gulp-sass/node_modules/node-sass/vendor/linux-x64-11/binding.node

> node-sass@3.8.0 postinstall /opt/ralph/node_modules/gulp-sass/node_modules/node-sass
> node scripts/build.js

"/opt/ralph/node_modules/gulp-sass/node_modules/node-sass/vendor/linux-x64-11/binding.node" exists.
 testing binary.
Binary is fine; exiting.
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR!     /opt/ralph/npm-debug.log
npm ERR! not ok code 0
ERROR: Service 'web' failed to build: The command '/bin/sh -c $SCRIPTS_PATH/provision_js.sh' returned a non-zero code: 1
Bryan Taylor
@brylor
wth I revert to my old commit and i get the same err
gatvo
@gatvo
@vi4m @brylor Thanks so much! ralph-cli looks promising
Bryan Taylor
@brylor
damn, spun up a bran new centos, fresh docker, got the same thing
✪ vi4m Marcin Kliks
@vi4m
which docker-compose.yml are you using?
Bryan Taylor
@brylor
The one from the contrib directory, only thing I changed was host port https://gist.github.com/brylor/b68f46f9f58ab1899ae7bb2a87130a2b
I can't really get to /opt/ralph/npm-debug.log not sure how to run the failed container from the build
lets see if i can make a volume of /opt/ralph onto the host and pull it that way...
Bryan Taylor
@brylor
Bryan Taylor
@brylor
I think something is unpublished ...
gatvo
@gatvo
blob
is it possible to specify the width for a particular asset model? I'm thinking of half-racks
Bryan Taylor
@brylor
you can make a blade enclosure with slots
✪ vi4m Marcin Kliks
@vi4m
@brylor you can install deb package inside the docker, to skip this npm bug
just apt-get install ralph-core as our guidline says
or just wait for @ar4s till the next day, he maintains this docker-compose configuration
to me looks like some sort of npm repo bug, they're sorta unstable these times
Arkadiusz Adamski
@ar4s
@brylor I will check that today :smile:
Bryan Taylor
@brylor
No luck with the npm problem? :(
Hahaha I think I fixed it! added -g to npm install in docker/provision_js.sh
and the next one :(
/root/init_js.sh: line 5: /opt/ralph/node_modules/.bin/gulp: No such file or directory
ERROR: Service 'web' failed to build: The command '/bin/sh -c $SCRIPTS_PATH/init_js.sh' returned a non-zero code: 1
ah cause gulp was prob installed globally
Bryan Taylor
@brylor
idk whats going on, have no idea about node
Bryan Taylor
@brylor
from the nodejs chan: "@brylor you're using an ANCIENT node and npm
if you installed node with apt, don't do that. install from source or with http://nvm.sh
you need to be on node 4 or 6, and npm 2 or 3.
Bryan Taylor
@brylor
11:24
ok ty
@brylor shakes fist at apt "
✪ vi4m Marcin Kliks
@vi4m
ekhm.
good to know.
Bryan Taylor
@brylor
I've commited the docker image at the failed build stage, so I'm able to work with it... ill keep you updated
✪ vi4m Marcin Kliks
@vi4m
ok
Bryan Taylor
@brylor
I managed to update the Docker scripts to install node via nvm, the error is gone and it appears I have fixed the node prob of course now:
 web_1    | [2016-08-18 11:19:08 +0000] [1] [INFO] Listening at: http://0.0.0.0:8000 (1)
web_1    | [2016-08-18 11:19:08 +0000] [1] [INFO] Using worker: sync
web_1    | [2016-08-18 11:19:08 +0000] [9] [INFO] Booting worker with pid: 9
web_1    | [2016-08-18 11:19:08 +0000] [9] [ERROR] Exception in worker process
web_1    | Traceback (most recent call last):
web_1    |   File "/usr/local/lib/python3.4/dist-packages/gunicorn/arbiter.py", line 557, in spawn_worker
web_1    |     worker.init_process()
web_1    |   File "/usr/local/lib/python3.4/dist-packages/gunicorn/workers/base.py", line 126, in init_process
web_1    |     self.load_wsgi()
web_1    |   File "/usr/local/lib/python3.4/dist-packages/gunicorn/workers/base.py", line 136, in load_wsgi
web_1    |     self.wsgi = self.app.wsgi()
web_1    |   File "/usr/local/lib/python3.4/dist-packages/gunicorn/app/base.py", line 67, in wsgi
web_1    |     self.callable = self.load()
web_1    |   File "/usr/local/lib/python3.4/dist-packages/gunicorn/app/wsgiapp.py", line 65, in load
web_1    |     return self.load_wsgiapp()
web_1    |   File "/usr/local/lib/python3.4/dist-packages/gunicorn/app/wsgiapp.py", line 52, in load_wsgiapp
web_1    |     return util.import_app(self.app_uri)
web_1    |   File "/usr/local/lib/python3.4/dist-packages/gunicorn/util.py", line 357, in import_app
web_1    |     __import__(module)
web_1    | ImportError: No module named 'ralph.wsgi'
web_1    | [2016-08-18 11:19:08 +0000] [9] [INFO] Worker exiting (pid: 9)
web_1    | [2016-08-18 11:19:08 +0000] [1] [INFO] Shutting down: Master
I have to cd src...
Bryan Taylor
@brylor
Ok this is what I have so far: brylor/ralph@e6822c3
But I still get the above ralph.wsgi error because docker compose has command: gunicorn -w 4 -b 0.0.0.0:8000 -t 300 ralph.wsgi ... but that is executed in /opt/ralph, it should be /opt/ralph/src but I can't make the paths/environments happy ...
btw my github accounts are messed up :(
Bryan Taylor
@brylor
actually: brylor/ralph@f16660b
Bryan Taylor
@brylor
still trying to get docker working this is where i'm at:
[root@yp-personal ralph-docker]# docker-compose  up
Starting ralphdocker_redis_1
Creating ralphdocker_data_1
Starting ralphdocker_inkpy_1
Recreating ralphdocker_db_1
Creating ralphdocker_web_1

ERROR: for web  Cannot start service web: oci runtime error: no such file or directory
ERROR: Encountered errors while bringing up the project.

[root@yp-personal ralph-docker]# grep working_dir docker-compose.yml
  working_dir: /opt/ralph/src

[root@yp-personal ralph-docker]# docker run -ti ralphdocker_web ls /opt/ralph/src
ralph  ralph.egg-info
this is crazy no sense
Bryan Taylor
@brylor
Got docker working :) I'm a few commits back though allegro/ralph#2748
Arkadiusz Adamski
@ar4s
@brylor thanks for investigation but we don't need nvm to install other version of nodejs.. Please test this solution #2751 and give me a feedback
Bryan Taylor
@brylor
yeah, i tried :D.... cool thanks! I'll check it