ruby on rails 4 - How to install mpg123 on Heroku Server -
ruby on rails 4 - How to install mpg123 on Heroku Server -
i'm using tts gemfor spoken sound onscreen, , works fine on local dev station, throws 500 on heroku's server. tts gem depends on mpg123.
the heroku logs send next errors @ runtime:
2014-06-23t09:37:47.024478+00:00 app[web.1]: mpg123 executable not found. function work posix systems. 2014-06-23t09:37:47.024485+00:00 app[web.1]: install mpg123 `brew install mpg123` or `apt-get install mpg123` 2014-06-23t09:37:47.025829+00:00 app[web.1]: completed 500 internal server error in 196ms
first attempt: heroku run brew install mpg123
running `brew install mpg123` attached terminal... up, run.1741 bash: brew: command not found
second attempt: heroku run apt-get install mpg123
running `apt-get install mpg123` attached terminal... up, run.5879 w: not using locking read lock file /var/lib/dpkg/lock e: unable write /var/cache/apt/ e: bundle lists or status file not parsed or opened.
upon farther research, i'm understanding 'custom buildpack' needs implementation? if so, how 1 determine buildpack utilize , how install mpg123 using it? unless there easier or more appropriate way, i'm open well.
gleaning clues this post, took few stabs in dark adding next buildbacks, re-running attempts above, no avail:
heroku plugins:install https://github.com/heroku/heroku-buildpacks installing heroku-buildpacks... done heroku config:add buildpack_url=https://github.com/benjie/heroku-buildpack-apt heroku config:add buildpack_url=https://github.com/heroku/heroku-buildpack-ruby heroku config:add buildpack_url=https://github.com/atris/heroku-buildpack-c
for it's worth, rails 4 project running under heroku's cedar stack.
thanks!
the way heroku works, scheme dependencies mpg123 have installed via buildpacks. because heroku doesn't allow app write filesystem after it's been deployed (which why brew , apt commands won't work).
so if want this, you'll have create custom buildpack mpg123, since doesn't appear else has built 1 yet.
for illustration of custom buildpack, check out lame one: https://github.com/lepinsk/heroku-buildpack-lame
then, you'll want utilize multi-buildpack buildpack allow install both mpg123 buildpack , app buildpack (for example, ruby).
heroku ruby-on-rails-4 heroku-toolbelt
Comments
Post a Comment