virtualstaticvoid / heroku-buildpack-r

Heroku buildpack for R - Makes deploying R on Heroku easy
MIT License
304 stars 236 forks source link

Building with dokku #149

Open timburgess opened 3 years ago

timburgess commented 3 years ago

I'm using dokku to build the demo shiny repo - https://github.com/virtualstaticvoid/heroku-shiny-app.git

However the build fails. I've gone and set an env variable of BUILDPACK_DEBUG=1 and it produces the following output:

...
remote: +++ shiny_archive
remote: +++ echo heroku-buildpack-r-18-4.0.0-shiny.tar.gz
remote: ++ s3_url heroku-buildpack-r-18-4.0.0-shiny.tar.gz
remote: ++ echo https://heroku-buildpack-r.s3.amazonaws.com/latest/heroku-buildpack-r-18-4.0.0-shiny.tar.gz
remote: + fetch https://heroku-buildpack-r.s3.amazonaws.com/latest/heroku-buildpack-r-18-4.0.0-shiny.tar.gz shiny.tar.gz shiny_image
remote: + local url=https://heroku-buildpack-r.s3.amazonaws.com/latest/heroku-buildpack-r-18-4.0.0-shiny.tar.gz
remote: + local file=shiny.tar.gz
remote: + local __filevar=shiny_image
remote: + local filename=/cache/latest-18-27ac154h-shiny.tar.gz
remote: + '[' -f /cache/latest-18-27ac154h-shiny.tar.gz ']'
remote: + indent
remote: + echo 'Loading https://heroku-buildpack-r.s3.amazonaws.com/latest/heroku-buildpack-r-18-4.0.0-shiny.tar.gz from cache'
remote: + sed -u 's/^/       /'
       Loading https://heroku-buildpack-r.s3.amazonaws.com/latest/heroku-buildpack-r-18-4.0.0-shiny.tar.gz from cache
remote: + eval 'shiny_image='\''/cache/latest-18-27ac154h-shiny.tar.gz'\'''
remote: ++ shiny_image=/cache/latest-18-27ac154h-shiny.tar.gz
remote: + tar xf /cache/latest-18-27ac154h-shiny.tar.gz
remote: + mkdir -p bin
remote: + pushd bin
remote: + ln -s ../R/bin/R .
remote: + ln -s ../R/bin/Rscript .
remote: + popd
remote: + cp -f /tmp/buildpack3SQD5/bin/Rprofile.site R/lib/R/etc/Rprofile.site
remote: + cp -f /tmp/buildpack3SQD5/bin/helpers.R R/etc/helpers.R
remote: + cp -f /tmp/buildpack3SQD5/bin/copy_libs.rb R/etc/copy_libs.rb
remote: + '[' '!' -z ']'
remote: + mkdir -p .config/packrat R/packrat R/renv
remote: + '[' -f /cache/latest-18-27ac154h-sitelibrary.tar.gz ']'
remote: + '[' -f packrat/init.R ']'
remote: + '[' -f renv/activate.R ']'
remote: + HAVE_CHROOT=0
remote: + delete_download=0
remote: + '[' -f Aptfile ']'
remote: + '[' '!' -z ']'
remote: + '[' -f packrat/init.R ']'
remote: + '[' -f renv/activate.R ']'
remote: + topic 'Configuring build environment...'
remote: + echo '-----> Configuring build environment...'
-----> Configuring build environment...
remote: + pushd /app
remote: + grep -v '^.$'
remote: + find . -maxdepth 1 -type d
remote: + cut -c 2-
remote: 2021/02/24 03:24:41 exit status 1
remote: 2021/02/24 03:24:42 exit status 1
To shiny:shinydemo
 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'dokku@shiny:shinydemo'

Looking at /bin/compile, it seems to be failing around line 223 where it does popd > /dev/null

edmorley commented 3 years ago

It looks like this issue would be resolved by fixing #151.

edmorley commented 3 years ago

Oh perhaps not, if dokku doesn't build in /app - sorry ignore me :-)