Giter Club home page Giter Club logo

Comments (16)

axelson avatar axelson commented on August 23, 2024 1

@rockwood as far as I know this is still an issue. We're still working around it with the .slugignore file.

cat .slugignore
/app/_build/build_backup/build_backup

from heroku-buildpack-elixir.

HashNuke avatar HashNuke commented on August 23, 2024 1

Ah ok. If anyone can make a PR and if a bunch of folks can try out the PR, I can help merge it

from heroku-buildpack-elixir.

ericmj avatar ericmj commented on August 23, 2024

I haven't tested this but my guess is that the bug is here

cp -pR $(build_backup_path) ${build_path}/_build
.

We should add / to the end of the source path so that the contents are copied instead of the whole directory, i.e. cp -pR "$(build_backup_path)/" ${build_path}/_build If you would like to try this out I can set up a branch and give instructions on how to use it.

from heroku-buildpack-elixir.

axelson avatar axelson commented on August 23, 2024

Yeah that definitely sounds plausible. And we'd be willing to test out a branch of the buildpack.

from heroku-buildpack-elixir.

ericmj avatar ericmj commented on August 23, 2024

I have a branch ready f480baf.

If this is the first buildpack in your chain use the test branch by running:

heroku buildpacks:set -a MYAPP -i 1 https://github.com/HashNuke/heroku-buildpack-elixir.git\#emj/backup-path

from heroku-buildpack-elixir.

axelson avatar axelson commented on August 23, 2024

@ericmj okay I've tested that branch but I'm seeing the same behavior:

Jasons-MacBook-Pro-2% heroku buildpacks -r staging2
=== app-staging2 Buildpack URL
https://github.com/HashNuke/heroku-buildpack-elixir.git#emj/backup-path
Jasons-MacBook-Pro-2% heroku run 'ls /app/_build/build_backup' -r staging2
Running ls /app/_build/build_backup on ⬢ app-staging2... up, run.8622 (Hobby)
build_backup  staging  test

from heroku-buildpack-elixir.

ericmj avatar ericmj commented on August 23, 2024

@axelson Did you test it on a new app or cleaned the cache by setting always_rebuild=true in the buildpack config or by running heroku repo:purge_cache -a MYAPP after heroku plugins:install heroku-repo.

from heroku-buildpack-elixir.

axelson avatar axelson commented on August 23, 2024

I didn't run purge cache before, but after running heroku repo:purge_cache -a MYAPP I am still seeing the same behavior :(

Jasons-MacBook-Pro-2% heroku run 'ls /app/_build/build_backup' -r staging2
Running ls /app/_build/build_backup on ⬢ app-staging2... up, run.4008 (Hobby)
build_backup  staging  test

from heroku-buildpack-elixir.

ericmj avatar ericmj commented on August 23, 2024

Okay, I will look more into this then.

from heroku-buildpack-elixir.

rockwood avatar rockwood commented on August 23, 2024

@axelson Were you able to find a solution to this issue? We're also seeing the nested build_backup/ directories causing our slug size to grow on each deploy. The weird thing is that it's only happening on our staging instance.

from heroku-buildpack-elixir.

rockwood avatar rockwood commented on August 23, 2024

@axelson got it, that's working for me as well. Thanks!

from heroku-buildpack-elixir.

axelson avatar axelson commented on August 23, 2024

Great, glad I was able to help!

from heroku-buildpack-elixir.

HashNuke avatar HashNuke commented on August 23, 2024

@axelson @rockwood Do you folks have a recommended change to the buildpack to resolve this permanently for all users?

from heroku-buildpack-elixir.

axelson avatar axelson commented on August 23, 2024

@HashNuke It looks to me like there's an issue calculating the $(build_backup_path) but I haven't looked into it too deeply. If that path was correct and successfully deleted previous backups in function backup_app() then I think it would work great.

from heroku-buildpack-elixir.

phlppn avatar phlppn commented on August 23, 2024

I found the reason for this.

The Heroku-Bash cp command does not respect the trailing slash of the source folder, to tell cp to copy the content of the folder instead of the folder itself.

So instead of writing cp foo/ bar we have to use cp foo/* bar.

This has to be fixed in multiple lines in the project.

It was hard to debug, because my local cp works with /, and also the local manual of cp tells me that a / is enough.

This is also the reason for stuff like /.hex/.hex/...

from heroku-buildpack-elixir.

rafaeelaudibert avatar rafaeelaudibert commented on August 23, 2024

This should probably be closed by now, it looks like #152 fixed it

from heroku-buildpack-elixir.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.