Coder Social home page Coder Social logo

heroku-buildpack-apt's Introduction

heroku-buildpack-apt Build Status

Add support for apt-based dependencies during both compile and runtime.

Added ability to also specify custom repositories through :repo: in Aptfile (see example below).

Usage

This buildpack is not meant to be used on its own, and instead should be in used in combination with Heroku's multiple buildpack support.

Include a list of apt package names to be installed in a file named Aptfile.

To find out what packages are available, see: https://packages.ubuntu.com

See the Heroku Stacks documention for which Ubuntu LTS version is used by each Heroku stack.

Example

Command-line

To use the latest stable version:

heroku buildpacks:add --index 1 heroku-community/apt

To use the edge version (i.e. the code in this repo):

heroku buildpacks:add --index 1 https://github.com/heroku/heroku-buildpack-apt

Aptfile

# you can list packages
libexample-dev

# or include links to specific .deb files
https://downloads.example.com/example.deb

# or add custom apt repos (only required if using packages outside of the standard Ubuntu APT repositories)
:repo:deb https://apt.example.com/ example-distro main

License

MIT

heroku-buildpack-apt's People

Contributors

colincasey avatar ddollar avatar dmerrick avatar dzuelke avatar edmorley avatar evadne avatar furious-luke avatar gjtorikian avatar imirkin avatar jkutner avatar kevinbrolly avatar nekopanic avatar ricardochimal avatar schneems avatar sjansen avatar sobrinho avatar thomasboyt avatar tokafish avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

heroku-buildpack-apt's Issues

Unable to locate package if Windows-style CR+LF newlines used in Aptfile

If I create a new heroku dyno with the buildpacks:
https://github.com/heroku/heroku-buildpack-apt
heroku/python

And then I push a commit with an empty requirements.txt and an Aptfile containing:

poppler-utils

I get different results depending on if the file was created in MacOS or Windows. If the file was created in MacOS, everything works as expected, poppler-utils is installed just fine. On a Windows machine, the release contains an error message: E: Unable to locate package poppler-utils.

I noticed that the Windows version of the Aptfile uses CR+LF for linebreaks, while the MacOS version uses LF for linebreaks - I'm assuming that's what's causing the problem, because I can't see any other difference at all.

hexdump of (non-working) Aptfile from Windows:

0000000 70 6f 70 70 6c 65 72 2d 75 74 69 6c 73 0d 0a   
000000f

hexdump of (working) Aptfile from MacOS:

0000000 70 6f 70 70 6c 65 72 2d 75 74 69 6c 73 0a      
000000e

exiftool?

I have found that some packages don't work, and I'm curious the general theory behind it, what's up with the heroku environment.

For instance, trying to list exiftool in the Aptfile, after install heroku run bash, and:

Can't locate Image/ExifTool.pm in @INC (you may need to install the Image::ExifTool module) (@INC contains: /app/.apt/usr/bin/lib /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/x86_64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /app/.apt/usr/bin/exiftool line 30.
BEGIN failed--compilation aborted at /app/.apt/usr/bin/exiftool line 30.

I hadn't even realized exiftool was written in Perl! But Perl is of course on the machine, as evidenced by the error message from Perl -- and confirmed by https://devcenter.heroku.com/articles/stack-packages

But I guess wherever apt-get installs exiftool Perl package is not a place the installed Perl can find it?

Even though @INC contains: /app/.apt/usr/bin/lib, and at /app/.apt/usr/bin/exiftool line 30, we are using the apt-installed exiftool command in the first place... weird.

I'm not sure what's going on with this interaction, if it indicates a flaw in the apt buildpack, or if there's anything that can be done as a workaround, or what!

Support for HTTPS repositories

With this buildpack now having support for adding repositories through the Aptfile, it's still impossible to use HTTPS-only repos as the build fails on lacking an HTTPS apt transport. Adding apt-transport-https to the Aptfile doesn't work properly because packages are installed after making the repo cache.

Please consider adding the apt-transport-https before adding custom repos or alternatively respect the order in the Aptfile.

Cache gets bloated by old package versions

The buildpack does not clean up older versions of the packages it installs which leads to the dyno size becoming bloated over time.

Lets say that you have the package example installed and between every deploy you do a new version of it gets released by the upstream. After 5 deploys, you will have 6 versions of the package in your cache the current version and the 5 previous ones.

If you have a handful of large packages installed then you'll eventually run close to or over heroku's soft size limit of 300MB.

Emacs installed by heroku-buildpack-apt does not work

When I put emacs-nox in my Aptfile, an emacs25 binary is installed but when I try to run it I get:

Warning: arch-dependent data dir '/usr/lib/emacs/25.2/x86_64-linux-gnu/': No such file or directory
Warning: arch-independent data dir '/usr/share/emacs/25.2/etc/': No such file or directory
Warning: Lisp directory '/usr/share/emacs/25.2/lisp': No such file or directory
Error: charsets directory not found:
/usr/share/emacs/25.2/etc/charsets
Emacs will not function correctly without the character map files.
Please check your installation!

Presumably this is because Emacs is not a relocatable package, hence the installation process used by heroku-buildpack-apt is not suitable for it.

How can I work around this problem?

Add support for installing keys (i.e. apt-key add)

I want to install the nginx-nr-agent with apt. This works fine with the buildpack, but prior to installing the package, I need to gain access to the repository by downloading and installing the key with apt-key add nginx_signing.key. This throws an error, because apt-key add can only be executed with root access.

I would love to see support for installing keys with this buildpack, and had envisioned something similar to the way we install repositories, where the link following :key: is the link to download the key.

:key:https://nginx.org/keys/nginx_signing.key   #download and install key
:repo:deb deb http://nginx.org/packages/ubuntu/ xenial nginx   #download and install repo
nginx-nr-agent   #install package

Dependencies not being installed, mtr

I'm attempting to install mtr. When I ps:exec and issue an mtr command, I get missing library errors. As I add the missing libraries to Aptfile, I get new missing library errors. The dependencies are deep so I could chase this all day if I have to do it manually. Is there a flag or something I can add to install the dependencies for me?

App not compatible with buildpack

The documentation for trouble shooting this is not very helpful.

I installed apt using:

  heroku buildpacks:add --index 1 https://github.com/heroku/heroku-buildpack-apt

then pushed my repo out and pushed failed with:

  App not compatible with buildpack: https://github.com/heroku/heroku-buildpack-apt

I'm on cedar-14 stack with heroku/ruby buildpack installed
I'm running rails 5.2 and ruby 2.4.3

Is this a bug with rails 5.2 compatibility? Thanks for any assistance.

Failed to detect app matching no buildpack

When trying to deploy this buildpack on cedar-16 in addition to the heroku/nodejs buildpack, I get an "Failed to detect app matching no buildpack" msg and the push is rejected. Furthermore, how do I add the "Aptfile" to include the list of packages, which I want to be installed?

--force-yes is deprecated

Getting this warning lately when deploying with this buildpack. Ex:

-----> Fetching .debs for libjpeg-progs
       Reading package lists...
       Building dependency tree...
       [… snip …]
       Download complete and in download only mode
W: --force-yes is deprecated, use one of the options starting with --allow instead.

apt-get/curl errors don't cause the buildpack to fail early

The buildpack pipes apt/curl commands to an indent helper, but unfortunately doesn't set the pipefail bash option, which means the exit code is ignored, so the buildpack doesn't fail early:

#!/usr/bin/env bash
# bin/compile <build-dir> <cache-dir>
# fail fast
set -e

See the set -o pipefail section on:
http://redsymbol.net/articles/unofficial-bash-strict-mode/

In addition, the curl usage doesn't pass -f, so won't return non-zero for non-HTTP-200 responses:

curl -s -L -z $PACKAGE_FILE -o $PACKAGE_FILE $PACKAGE 2>&1 | indent

Examples of both of these happening can be seen in the output in #45.

wkhtmltopdf: command not found

Based on your example, I tried:
Aptfile

https://downloads.wkhtmltopdf.org/0.12/0.12.5/wkhtmltox_0.12.5-1.bionic_amd64.deb

Result:

-----> Apt app detected
-----> Reusing cache
-----> Updating apt caches
       Hit:1 http://archive.ubuntu.com/ubuntu bionic InRelease
       Get:2 http://archive.ubuntu.com/ubuntu bionic-security InRelease [83.2 kB]
       Get:3 http://archive.ubuntu.com/ubuntu bionic-updates InRelease [88.7 kB]
       Get:4 http://apt.postgresql.org/pub/repos/apt bionic-pgdg InRelease [41.3 kB]
       Get:5 http://archive.ubuntu.com/ubuntu bionic-security/main amd64 Packages [232 kB]
       Get:6 http://archive.ubuntu.com/ubuntu bionic-updates/universe amd64 Packages [716 kB]
       Get:7 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 Packages [522 kB]
       Get:8 http://apt.postgresql.org/pub/repos/apt bionic-pgdg/main amd64 Packages [220 kB]
       Fetched 1,904 kB in 1s (2,266 kB/s)
       Reading package lists...
-----> Fetching https://downloads.wkhtmltopdf.org/0.12/0.12.5/wkhtmltox_0.12.5-1.bionic_amd64.deb
-----> Installing wkhtmltox_0.12.5-1.bionic_amd64.deb
-----> Writing profile script
-----> Rewrite package-config files
-----> Node.js app detected
....

But when I try to use wkhtmltopdf command:

bash: wkhtmltopdf: command not found

Proposal: support comments in Aptfile

It would be nice to be able to write:

# This CI file defines packages to be installed while deploying using Heroku.
# It is used by the buildpack https://github.com/heroku/heroku-buildpack-apt.git
package1
# We need package2 because ...
package2

How to add a repo without checking key

Hello. I am trying to add to add "deb http://download.virtualbox.org/virtualbox/debian bionic contrib" repository, but I get error
-----> Apt app detected -----> Reusing cache -----> Updating apt caches Get:1 http://download.virtualbox.org/virtualbox/debian bionic InRelease [4,432 B] Err:1 http://download.virtualbox.org/virtualbox/debian bionic InRelease The following signatures couldn't be verified because the public key is not available: NO_PUBKEY A2F683C52980AECF Hit:2 http://archive.ubuntu.com/ubuntu bionic InRelease Hit:3 http://archive.ubuntu.com/ubuntu bionic-security InRelease Hit:4 http://apt.postgresql.org/pub/repos/apt bionic-pgdg InRelease Hit:5 http://archive.ubuntu.com/ubuntu bionic-updates InRelease Reading package lists... W: GPG error: http://download.virtualbox.org/virtualbox/debian bionic InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY A2F683C52980AECF E: The repository 'http://download.virtualbox.org/virtualbox/debian bionic InRelease' is not signed.

And my Aptfile looks like this:

:repo:deb http://download.virtualbox.org/virtualbox/debian bionic contrib

shellinabox
screen
htop
tree
nano
virtualbox

So, can i add apt repo without specifying a key?

Old/cached packages are still installed during the build

We have the following in our Aptfile:

libcairo2 libcairo-gobject2 libxt6 libsm6 libice6 libgtk-3-0 firefox vim

We've just noticed that, during the build, old versions (from previous builds) are still getting installed.

This doesn't impact the dyno size as the new version overwrites the old one, but still, it increases the time of the build, and with time (and more newer versions) it could increase it even more.

Notice the multiple firefox, glib-networking, etc:

remote: -----> Installing adwaita-icon-theme_3.28.0-1ubuntu1_all.deb
remote: -----> Installing at-spi2-core_2.28.0-1_amd64.deb
remote: -----> Installing dconf-gsettings-backend_0.26.0-2ubuntu3_amd64.deb
remote: -----> Installing dconf-service_0.26.0-2ubuntu3_amd64.deb
remote: -----> Installing firefox_73.0.1+build1-0ubuntu0.18.04.1_amd64.deb
remote: -----> Installing firefox_74.0+build3-0ubuntu0.18.04.1_amd64.deb
remote: -----> Installing firefox_78.0.1+build1-0ubuntu0.18.04.1_amd64.deb
remote: -----> Installing glib-networking_2.56.0-1_amd64.deb
remote: -----> Installing glib-networking_2.56.0-1ubuntu0.1_amd64.deb
remote: -----> Installing glib-networking-common_2.56.0-1_all.deb
remote: -----> Installing glib-networking-common_2.56.0-1ubuntu0.1_all.deb
remote: -----> Installing glib-networking-services_2.56.0-1_amd64.deb
remote: -----> Installing glib-networking-services_2.56.0-1ubuntu0.1_amd64.deb
remote: -----> Installing gsettings-desktop-schemas_3.28.0-1ubuntu1_all.deb
remote: -----> Installing gtk-update-icon-cache_3.22.30-1ubuntu4_amd64.deb
remote: -----> Installing humanity-icon-theme_0.6.15_all.deb
remote: -----> Installing libasound2_1.1.3-5ubuntu0.2_amd64.deb
remote: -----> Installing libasound2_1.1.3-5ubuntu0.5_amd64.deb
remote: -----> Installing libasound2-data_1.1.3-5ubuntu0.2_all.deb
remote: -----> Installing libasound2-data_1.1.3-5ubuntu0.5_all.deb
remote: -----> Installing libatk1.0-0_2.28.1-1_amd64.deb
remote: -----> Installing libatk1.0-data_2.28.1-1_all.deb
remote: -----> Installing libatk-bridge2.0-0_2.26.2-1_amd64.deb
remote: -----> Installing libatspi2.0-0_2.28.0-1_amd64.deb
remote: -----> Installing libcairo2_1.15.10-2ubuntu0.1_amd64.deb
remote: -----> Installing libcairo-gobject2_1.15.10-2ubuntu0.1_amd64.deb
remote: -----> Installing libcanberra0_0.30-5ubuntu1_amd64.deb
remote: -----> Installing libcolord2_1.3.3-2build1_amd64.deb
remote: -----> Installing libdbus-glib-1-2_0.110-2_amd64.deb
remote: -----> Installing libdbusmenu-glib4_16.04.1+18.04.20171206-0ubuntu2_amd64.deb
remote: -----> Installing libdbusmenu-gtk3-4_16.04.1+18.04.20171206-0ubuntu2_amd64.deb
remote: -----> Installing libdconf1_0.26.0-2ubuntu3_amd64.deb
remote: -----> Installing libepoxy0_1.4.3-1_amd64.deb
remote: -----> Installing libgpm2_1.20.7-5_amd64.deb
remote: -----> Installing libgtk-3-0_3.22.30-1ubuntu4_amd64.deb
remote: -----> Installing libgtk-3-bin_3.22.30-1ubuntu4_amd64.deb
remote: -----> Installing libgtk-3-common_3.22.30-1ubuntu4_all.deb
remote: -----> Installing libice6_2%3a1.0.9-2_amd64.deb
remote: -----> Installing libjson-glib-1.0-0_1.4.2-3_amd64.deb
remote: -----> Installing libjson-glib-1.0-0_1.4.2-3ubuntu0.18.04.1_amd64.deb
remote: -----> Installing libjson-glib-1.0-common_1.4.2-3_all.deb
remote: -----> Installing libjson-glib-1.0-common_1.4.2-3ubuntu0.18.04.1_all.deb
remote: -----> Installing libogg0_1.3.2-1_amd64.deb
remote: -----> Installing libproxy1v5_0.4.15-1_amd64.deb
remote: -----> Installing libpython3.6_3.6.9-1~18.04_amd64.deb
remote: -----> Installing libpython3.6_3.6.9-1~18.04ubuntu1_amd64.deb
remote: -----> Installing librest-0.7-0_0.8.0-2_amd64.deb
remote: -----> Installing libsm6_2%3a1.2.2-1_amd64.deb
remote: -----> Installing libsoup2.4-1_2.62.1-1ubuntu0.4_amd64.deb
remote: -----> Installing libsoup-gnome2.4-1_2.62.1-1ubuntu0.4_amd64.deb
remote: -----> Installing libstartup-notification0_0.12-5_amd64.deb
remote: -----> Installing libtdb1_1.3.15-2_amd64.deb
remote: -----> Installing libvorbis0a_1.3.5-4.2_amd64.deb
remote: -----> Installing libvorbisfile3_1.3.5-4.2_amd64.deb
remote: -----> Installing libwayland-client0_1.16.0-1ubuntu1.1~18.04.3_amd64.deb
remote: -----> Installing libwayland-cursor0_1.16.0-1ubuntu1.1~18.04.3_amd64.deb
remote: -----> Installing libwayland-egl1_1.16.0-1ubuntu1.1~18.04.3_amd64.deb
remote: -----> Installing libx11-xcb1_2%3a1.6.4-3ubuntu0.2_amd64.deb
remote: -----> Installing libxcb-util1_0.4.0-0ubuntu3_amd64.deb
remote: -----> Installing libxcomposite1_1%3a0.4.4-2_amd64.deb
remote: -----> Installing libxcursor1_1%3a1.1.15-1_amd64.deb
remote: -----> Installing libxdamage1_1%3a1.1.4-3_amd64.deb
remote: -----> Installing libxfixes3_1%3a5.0.3-1_amd64.deb
remote: -----> Installing libxi6_2%3a1.7.9-1_amd64.deb
remote: -----> Installing libxinerama1_2%3a1.1.3-1_amd64.deb
remote: -----> Installing libxkbcommon0_0.8.2-1~ubuntu18.04.1_amd64.deb
remote: -----> Installing libxrandr2_2%3a1.5.1-1_amd64.deb
remote: -----> Installing libxt6_1%3a1.1.5-1_amd64.deb
remote: -----> Installing libxtst6_2%3a1.2.3-1_amd64.deb
remote: -----> Installing sound-theme-freedesktop_0.8-2ubuntu1_all.deb
remote: -----> Installing ubuntu-mono_16.10+18.04.20181005-0ubuntu1_all.deb
remote: -----> Installing vim_2%3a8.0.1453-1ubuntu1.1_amd64.deb
remote: -----> Installing vim_2%3a8.0.1453-1ubuntu1.3_amd64.deb
remote: -----> Installing vim-common_2%3a8.0.1453-1ubuntu1.1_all.deb
remote: -----> Installing vim-common_2%3a8.0.1453-1ubuntu1.3_all.deb
remote: -----> Installing vim-runtime_2%3a8.0.1453-1ubuntu1.1_all.deb
remote: -----> Installing vim-runtime_2%3a8.0.1453-1ubuntu1.3_all.deb
remote: -----> Installing xkb-data_2.23.1-1ubuntu1.18.04.1_all.deb
remote: -----> Installing xul-ext-ubufox_3.4-0ubuntu1.17.10.1_all.deb
remote: -----> Installing xxd_2%3a8.0.1453-1ubuntu1.1_amd64.deb
remote: -----> Installing xxd_2%3a8.0.1453-1ubuntu1.3_amd64.deb
> firefox -V

Mozilla Firefox 78.0.1
> which firefox

/app/.apt/usr/bin/firefox
> ls /app/.apt/usr/bin/

broadwayd
firefox
gtk-builder-tool
gtk-launch
gtk-query-settings
gtk-update-icon-cache
helpztags
vim.basic
vimtutor
xxd

It could be related with #61 / #62

Something's broken with custom repos

The following Aptfile used to work a few weeks ago:

:repo:deb [trusted=yes arch=amd64] https://packages.microsoft.com/ubuntu/16.04/prod xenial main
dotnet-sdk-5.0

Now it generates the following error during build:

-----> Fetching ο»Ώ:repo:deb
       curl: (3) URL using bad/illegal format or missing URL
 !     Push rejected, failed to compile Apt app.

This happens both with edge and standard versions

Installing Cmake error

My buildpack settings look like this -

Buildpack added. Next release on myapp will use:
  1. https://github.com/heroku/heroku-buildpack-apt
  2. heroku/ruby

And my AptFile looks like this -

cmake
http://www.cmake.org/files/v3.2/cmake-3.2.3-Linux-x86_64.tar.gz

Running git push heroku master I am seeing below error.
How can i fix this -

Total 2255 (delta 1419), reused 2249 (delta 1417)
remote: Compressing source files... done.
remote: Building source:
remote: 
remote: -----> Failed to detect set buildpack https://github.com/heroku/heroku-buildpack-apt
remote: More info: https://devcenter.heroku.com/articles/buildpacks#detection-failure
remote: 
remote:  !     Push failed
remote: Verifying deploy...

Cannot find pgbouncer executable

I tried to use this buildpack to install pgbouncer.
When I deployed, pgbouncer was not in the PATH, and I couldn't find anything in the file system related to pgbouncer.

The build logs looked fine:

remote: -----> Apt app detected
remote: -----> Detected Aptfile or Stack changes, flushing cache
remote: -----> Adding custom repositories
remote: -----> Updating apt caches
remote:        Get:1 http://apt.postgresql.org/pub/repos/apt bionic-pgdg InRelease [84.4 kB]
remote:        Get:2 http://archive.ubuntu.com/ubuntu bionic InRelease [242 kB]
remote:        Get:3 http://apt.postgresql.org/pub/repos/apt bionic-pgdg/main amd64 Packages [302 kB]
remote:        Get:4 http://archive.ubuntu.com/ubuntu bionic-security InRelease [88.7 kB]
remote:        Get:5 http://archive.ubuntu.com/ubuntu bionic-updates InRelease [88.7 kB]
remote:        Get:6 http://archive.ubuntu.com/ubuntu bionic/main amd64 Packages [1,344 kB]
remote:        Get:7 http://archive.ubuntu.com/ubuntu bionic/universe amd64 Packages [11.3 MB]
remote:        Get:8 http://archive.ubuntu.com/ubuntu bionic-security/universe amd64 Packages [844 kB]
remote:        Get:9 http://archive.ubuntu.com/ubuntu bionic-security/main amd64 Packages [908 kB]
remote:        Get:10 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 Packages [1,205 kB]
remote:        Get:11 http://archive.ubuntu.com/ubuntu bionic-updates/universe amd64 Packages [1,376 kB]
remote:        Fetched 17.8 MB in 3s (5,675 kB/s)
remote:        Reading package lists...
remote: -----> Fetching .debs for pgbouncer
remote:        Reading package lists...
remote:        Building dependency tree...
remote:        The following additional packages will be installed:
remote:          libc-ares2
remote:        Suggested packages:
remote:          python3-psycopg2
remote:        The following NEW packages will be installed:
remote:          libc-ares2 pgbouncer
remote:        0 upgraded, 2 newly installed, 0 to remove and 36 not upgraded.
remote:        Need to get 240 kB of archives.
remote:        After this operation, 603 kB of additional disk space will be used.
remote:        Get:1 http://apt.postgresql.org/pub/repos/apt bionic-pgdg/main amd64 pgbouncer amd64 1.13.0-1.pgdg18.04+1 [203 kB]
remote:        Get:2 http://archive.ubuntu.com/ubuntu bionic/main amd64 libc-ares2 amd64 1.14.0-1 [37.1 kB]
remote:        Fetched 240 kB in 1s (455 kB/s)
remote:        Download complete and in download only mode
remote: -----> Installing libc-ares2_1.14.0-1_amd64.deb
remote: -----> Installing pgbouncer_1.13.0-1.pgdg18.04+1_amd64.deb
remote: -----> Writing profile script
remote: -----> Rewrite package-config files

however, / $ find / -name "pgbouncer.*" returned no results

have I configured something wrong?

My Aptfile was simply

pgbouncer

Unable to install Enchant C library

I am copying my question posted on Stackoverflow since I may get a better answer here


My heroku app makes use of the enchant library. When I go to deploy, I get this log from heroku logs:

2022-01-14T16:12:34.373982+00:00 heroku[web.1]: Starting process with command `python main.py`
2022-01-14T16:12:36.222280+00:00 app[web.1]: Traceback (most recent call last):
2022-01-14T16:12:36.222301+00:00 app[web.1]: File "/app/main.py", line 3, in <module>
2022-01-14T16:12:36.222404+00:00 app[web.1]: import commands as c
2022-01-14T16:12:36.222406+00:00 app[web.1]: File "/app/commands.py", line 2, in <module>
2022-01-14T16:12:36.222484+00:00 app[web.1]: import enchant
2022-01-14T16:12:36.222485+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.9/site-packages/enchant/__init__.py", line 81, in <module>
2022-01-14T16:12:36.222593+00:00 app[web.1]: from enchant import _enchant as _e
2022-01-14T16:12:36.222594+00:00 app[web.1]: File "/app/.heroku/python/lib/python3.9/site-packages/enchant/_enchant.py", line 157, in <module>
2022-01-14T16:12:36.222682+00:00 app[web.1]: raise ImportError(msg)
2022-01-14T16:12:36.222708+00:00 app[web.1]: ImportError: The 'enchant' C library was not found and maybe needs to be installed.
2022-01-14T16:12:36.222708+00:00 app[web.1]: See  https://pyenchant.github.io/pyenchant/install.html
2022-01-14T16:12:36.222709+00:00 app[web.1]: for details
2022-01-14T16:12:36.222711+00:00 app[web.1]:
2022-01-14T16:12:36.396316+00:00 heroku[web.1]: Process exited with status 1

So doing a little research I find that the enchant library makes use of the underlying Enchant C library which is an apt-based dependency. So the proper way to handle this problem in heroku is to use heroku-buildpack-apt. I use the Ubuntu Packages Search to find the proper name for the Enchant C library. In particular, I try "enchant-2", "libenchant-2-2", "python3-enchant" by adding them to the Aptfile. When I push the changes to heroku, I get logs assuring me that it is using the heroku-community/apt buildpack and is installing the enchant library that I specified in the Aptfile. However, the same above error always occurs.

It seems that this issue has popped up a couple times on the internet but has gone unresolved with most people just opting to not use the enchant library entirely which I may concede to doing as well.

Anyone know how to solve this problem?

.so file being placed in `/tmp/build_XXX` directory

Can someone help me out here? Why would a .so file be placed inside of a tmp directory?

Unable to load application: LoadError: /tmp/build_29fd2902/vendor/bundle/ruby/2.7.0/gems/extpp-0.0.9/ext/extpp/libruby-extpp.so:
cannot open shared object file: No such file or directory - 
/app/vendor/bundle/ruby/2.7.0/gems/red-arrow-4.0.0/lib/arrow.so

When I run heroku run bash, the file indeed doesn't exist there - it exists in /app/vendor instead.

My question is this: why is only that one .so file being placed there? Why would arrow.so be configured to link to a file that doesn't exist? What could cause something like this? I'm at a loss, so if anyone out there with a better understanding of how this buildpack works could point me in the right direction I'd really appreciate it.

Here's the full output from ldd on arrow.so showing the broken link to libruby-extpp.so in the wrong directory:

~ $ ldd /app/vendor/bundle/ruby/2.7.0/gems/red-arrow-4.0.0/lib/arrow.so 
	linux-vdso.so.1 (0x00007fffbcd6f000)
	libruby.so.2.7 => not found
	libarrow.so.500 => /app/.apt/usr/lib/x86_64-linux-gnu/libarrow.so.500 (0x00007f8fd7389000)
	libarrow-glib.so.500 => /app/.apt/usr/lib/x86_64-linux-gnu/libarrow-glib.so.500 (0x00007f8fd7243000)
	libgobject-2.0.so.0 => /app/.apt/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0 (0x00007f8fd71e3000)
	/tmp/build_29fd2902/vendor/bundle/ruby/2.7.0/gems/extpp-0.0.9/ext/extpp/libruby-extpp.so => not found
	libstdc++.so.6 => /lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f8fd6fff000)
	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f8fd6e0d000)
	libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f8fd6df2000)
	libbrotlienc.so.1 => /lib/x86_64-linux-gnu/libbrotlienc.so.1 (0x00007f8fd6d69000)
	libbrotlidec.so.1 => /lib/x86_64-linux-gnu/libbrotlidec.so.1 (0x00007f8fd6d5b000)
	libutf8proc.so.2 => /app/.apt/usr/lib/x86_64-linux-gnu/libutf8proc.so.2 (0x00007f8fd6d0c000)
	libre2.so.5 => /app/.apt/usr/lib/x86_64-linux-gnu/libre2.so.5 (0x00007f8fd6c9b000)
	libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f8fd6c95000)
	libcrypto.so.1.1 => /lib/x86_64-linux-gnu/libcrypto.so.1.1 (0x00007f8fd69bf000)
	libbz2.so.1.0 => /lib/x86_64-linux-gnu/libbz2.so.1.0 (0x00007f8fd69ac000)
	liblz4.so.1 => /lib/x86_64-linux-gnu/liblz4.so.1 (0x00007f8fd698b000)
	libsnappy.so.1 => /app/.apt/usr/lib/x86_64-linux-gnu/libsnappy.so.1 (0x00007f8fd697e000)
	libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007f8fd6962000)
	libzstd.so.1 => /lib/x86_64-linux-gnu/libzstd.so.1 (0x00007f8fd68b9000)
	libcurl.so.4 => /lib/x86_64-linux-gnu/libcurl.so.4 (0x00007f8fd6828000)
	libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f8fd66d9000)
	libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f8fd66b6000)
	/lib64/ld-linux-x86-64.so.2 (0x00007f8fd8a68000)
	libglib-2.0.so.0 => /app/.apt/usr/lib/x86_64-linux-gnu/libglib-2.0.so.0 (0x00007f8fd658b000)
	libgio-2.0.so.0 => /app/.apt/usr/lib/x86_64-linux-gnu/libgio-2.0.so.0 (0x00007f8fd63aa000)
	libffi.so.7 => /lib/x86_64-linux-gnu/libffi.so.7 (0x00007f8fd639e000)
	libbrotlicommon.so.1 => /lib/x86_64-linux-gnu/libbrotlicommon.so.1 (0x00007f8fd637b000)
	libnghttp2.so.14 => /lib/x86_64-linux-gnu/libnghttp2.so.14 (0x00007f8fd6352000)
	libidn2.so.0 => /lib/x86_64-linux-gnu/libidn2.so.0 (0x00007f8fd632f000)
	librtmp.so.1 => /lib/x86_64-linux-gnu/librtmp.so.1 (0x00007f8fd630f000)
	libssh.so.4 => /lib/x86_64-linux-gnu/libssh.so.4 (0x00007f8fd62a1000)
	libpsl.so.5 => /lib/x86_64-linux-gnu/libpsl.so.5 (0x00007f8fd628e000)
	libssl.so.1.1 => /lib/x86_64-linux-gnu/libssl.so.1.1 (0x00007f8fd61fb000)
	libgssapi_krb5.so.2 => /lib/x86_64-linux-gnu/libgssapi_krb5.so.2 (0x00007f8fd61ae000)
	libldap_r-2.4.so.2 => /lib/x86_64-linux-gnu/libldap_r-2.4.so.2 (0x00007f8fd6156000)
	liblber-2.4.so.2 => /lib/x86_64-linux-gnu/liblber-2.4.so.2 (0x00007f8fd6145000)
	libpcre.so.3 => /lib/x86_64-linux-gnu/libpcre.so.3 (0x00007f8fd60d2000)
	libgmodule-2.0.so.0 => /app/.apt/usr/lib/x86_64-linux-gnu/libgmodule-2.0.so.0 (0x00007f8fd60cc000)
	libmount.so.1 => /lib/x86_64-linux-gnu/libmount.so.1 (0x00007f8fd606c000)
	libselinux.so.1 => /lib/x86_64-linux-gnu/libselinux.so.1 (0x00007f8fd603f000)
	libresolv.so.2 => /lib/x86_64-linux-gnu/libresolv.so.2 (0x00007f8fd6023000)
	libunistring.so.2 => /lib/x86_64-linux-gnu/libunistring.so.2 (0x00007f8fd5ea1000)
	libgnutls.so.30 => /lib/x86_64-linux-gnu/libgnutls.so.30 (0x00007f8fd5ccb000)
	libhogweed.so.5 => /lib/x86_64-linux-gnu/libhogweed.so.5 (0x00007f8fd5c94000)
	libnettle.so.7 => /lib/x86_64-linux-gnu/libnettle.so.7 (0x00007f8fd5c5a000)
	libgmp.so.10 => /lib/x86_64-linux-gnu/libgmp.so.10 (0x00007f8fd5bd4000)
	libkrb5.so.3 => /lib/x86_64-linux-gnu/libkrb5.so.3 (0x00007f8fd5af7000)
	libk5crypto.so.3 => /lib/x86_64-linux-gnu/libk5crypto.so.3 (0x00007f8fd5ac6000)
	libcom_err.so.2 => /lib/x86_64-linux-gnu/libcom_err.so.2 (0x00007f8fd5abf000)
	libkrb5support.so.0 => /lib/x86_64-linux-gnu/libkrb5support.so.0 (0x00007f8fd5ab0000)
	libsasl2.so.2 => /lib/x86_64-linux-gnu/libsasl2.so.2 (0x00007f8fd5a91000)
	libgssapi.so.3 => /lib/x86_64-linux-gnu/libgssapi.so.3 (0x00007f8fd5a4c000)
	libblkid.so.1 => /lib/x86_64-linux-gnu/libblkid.so.1 (0x00007f8fd59f5000)
	libpcre2-8.so.0 => /lib/x86_64-linux-gnu/libpcre2-8.so.0 (0x00007f8fd5965000)
	libp11-kit.so.0 => /lib/x86_64-linux-gnu/libp11-kit.so.0 (0x00007f8fd582f000)
	libtasn1.so.6 => /lib/x86_64-linux-gnu/libtasn1.so.6 (0x00007f8fd5817000)
	libkeyutils.so.1 => /lib/x86_64-linux-gnu/libkeyutils.so.1 (0x00007f8fd5810000)
	libheimntlm.so.0 => /lib/x86_64-linux-gnu/libheimntlm.so.0 (0x00007f8fd5804000)
	libkrb5.so.26 => /lib/x86_64-linux-gnu/libkrb5.so.26 (0x00007f8fd5771000)
	libasn1.so.8 => /lib/x86_64-linux-gnu/libasn1.so.8 (0x00007f8fd56ca000)
	libhcrypto.so.4 => /lib/x86_64-linux-gnu/libhcrypto.so.4 (0x00007f8fd5690000)
	libroken.so.18 => /lib/x86_64-linux-gnu/libroken.so.18 (0x00007f8fd5677000)
	libwind.so.0 => /lib/x86_64-linux-gnu/libwind.so.0 (0x00007f8fd564d000)
	libheimbase.so.1 => /lib/x86_64-linux-gnu/libheimbase.so.1 (0x00007f8fd563b000)
	libhx509.so.5 => /lib/x86_64-linux-gnu/libhx509.so.5 (0x00007f8fd55ed000)
	libsqlite3.so.0 => /lib/x86_64-linux-gnu/libsqlite3.so.0 (0x00007f8fd54c2000)
	libcrypt.so.1 => /lib/x86_64-linux-gnu/libcrypt.so.1 (0x00007f8fd5487000)

Buildpack is unexpectedly using sources lists from /etc/apt/sources.list.d/

In the build output of a legacy cedar-14 app that's using this buildpack, there are references to the ESM ubuntu sources (added in heroku/base-images/pull/140) - which is not expected and results in warnings/errors.

The stack-images repository intentionally configured the ESM APT sources via a separate file under /etc/apt/sources.list.d/:
https://github.com/heroku/stack-images/blob/0cc634aacc80dc492a5a72b7f15f38ecdfa5129e/cedar-14/bin/cedar-14.sh#L94-L97

...so that the file isn't used by this buildpack, which only copies the main sources list:

cat "/etc/apt/sources.list" > "$APT_SOURCES" # no cp here

The only cause I can think of is that the -o dir::etc::sourcelist=... option passed here isn't taking effect:

APT_OPTIONS="$APT_OPTIONS -o dir::etc::sourcelist=$APT_SOURCES"

...perhaps because it doesn't use quotes and/or the same capitalisation as shown here?
https://unix.stackexchange.com/a/420946

Example output:

remote: -----> Apt app detected
remote: -----> Detected Aptfile changes, flushing cache
remote: -----> Adding custom repositories
remote: -----> Updating apt caches
remote:        Hit http://apt.postgresql.org trusty-pgdg InRelease
remote:        Hit http://apt.postgresql.org trusty-pgdg/main amd64 Packages
remote:        Ign http://archive.ubuntu.com trusty InRelease
remote:        Hit http://archive.ubuntu.com trusty-security InRelease
remote:        Hit http://archive.ubuntu.com trusty-updates InRelease
remote:        Hit http://archive.ubuntu.com trusty Release.gpg
remote:        Hit http://archive.ubuntu.com trusty-security/main amd64 Packages
remote:        Hit http://archive.ubuntu.com trusty-security/universe amd64 Packages
remote:        Hit http://archive.ubuntu.com trusty-updates/main amd64 Packages
remote:        Hit http://archive.ubuntu.com trusty-updates/universe amd64 Packages
remote:        Hit http://archive.ubuntu.com trusty Release
remote:        Hit http://archive.ubuntu.com trusty/main amd64 Packages
remote:        Hit http://archive.ubuntu.com trusty/universe amd64 Packages
remote:        Hit https://esm.ubuntu.com trusty-security InRelease
remote:        Hit https://esm.ubuntu.com trusty-updates InRelease
remote:        Hit https://esm.ubuntu.com trusty-security/main amd64 Packages
remote:        Hit https://esm.ubuntu.com trusty-updates/main amd64 Packages
remote:        Reading package lists...
remote: -----> Fetching .debs for libchromaprint-dev
remote:        Reading package lists...
remote:        Building dependency tree...
remote:        The following extra packages will be installed:
remote:          libavcodec54 libavutil52 libchromaprint0 libgsm1 libmp3lame0 libopenjpeg2
remote:          libopus0 liborc-0.4-0 libschroedinger-1.0-0 libspeex1 libtheora0 libva1
remote:          libx264-142 libxvidcore4
remote:        Suggested packages:
remote:          libchromaprint-tools python-acoustid opus-tools speex
remote:        The following NEW packages will be installed:
remote:          libavcodec54 libavutil52 libchromaprint-dev libchromaprint0 libgsm1
remote:          libmp3lame0 libopenjpeg2 libopus0 liborc-0.4-0 libschroedinger-1.0-0
remote:          libspeex1 libtheora0 libva1 libx264-142 libxvidcore4
remote:        0 upgraded, 15 newly installed, 0 to remove and 3 not upgraded.
remote:        Need to get 4,390 kB of archives.
remote:        After this operation, 13.4 MB of additional disk space will be used.
remote:        Get:1 http://archive.ubuntu.com/ubuntu/ trusty/universe libgsm1 amd64 1.0.13-4 [27.1 kB]
remote:        Get:2 http://archive.ubuntu.com/ubuntu/ trusty/universe libopenjpeg2 amd64 1.3+dfsg-4.7ubuntu1 [64.3 kB]
remote:        Get:3 https://esm.ubuntu.com/ubuntu/ trusty-security/main libavutil52 amd64 6:9.20-0ubuntu0.14.04.1+esm1 [67.9 kB]
remote:        Err https://esm.ubuntu.com/ubuntu/ trusty-security/main libavutil52 amd64 6:9.20-0ubuntu0.14.04.1+esm1
remote:          HttpError401
remote:        Err https://esm.ubuntu.com/ubuntu/ trusty-security/main libmp3lame0 amd64 3.99.5+repack1-3ubuntu1+esm2
remote:          HttpError401
remote:        Err https://esm.ubuntu.com/ubuntu/ trusty-security/main libavcodec54 amd64 6:9.20-0ubuntu0.14.04.1+esm1
remote:          HttpError401
remote:        Get:4 http://archive.ubuntu.com/ubuntu/ trusty/main libopus0 amd64 1.1-0ubuntu1 [153 kB]
remote:        Get:5 http://archive.ubuntu.com/ubuntu/ trusty/main liborc-0.4-0 amd64 1:0.4.18-1ubuntu1 [136 kB]
remote:        Get:6 http://archive.ubuntu.com/ubuntu/ trusty/universe libschroedinger-1.0-0 amd64 1.0.11-2ubuntu1 [268 kB]
remote:        Get:7 http://archive.ubuntu.com/ubuntu/ trusty/main libspeex1 amd64 1.2~rc1.1-1ubuntu1 [50.7 kB]
remote:        Get:8 http://archive.ubuntu.com/ubuntu/ trusty/main libtheora0 amd64 1.1.1+dfsg.1-3.2 [163 kB]
remote:        Get:9 http://archive.ubuntu.com/ubuntu/ trusty/universe libva1 amd64 1.3.0-2 [38.6 kB]
remote:        Get:10 http://archive.ubuntu.com/ubuntu/ trusty/universe libx264-142 amd64 2:0.142.2389+git956c8d8-2 [575 kB]
remote:        Get:11 http://archive.ubuntu.com/ubuntu/ trusty/universe libxvidcore4 amd64 2:1.3.2-9ubuntu1 [298 kB]
remote:        Get:12 http://archive.ubuntu.com/ubuntu/ trusty/universe libchromaprint0 amd64 1.1-1 [33.1 kB]
remote:        Get:13 http://archive.ubuntu.com/ubuntu/ trusty/universe libchromaprint-dev amd64 1.1-1 [5,482 B]
remote: E       Fetched 1,813 kB in 3s (527 kB/s)
remote: : Failed to fetch https://esm.ubuntu.com/ubuntu/pool/main/liba/libav/libavutil52_9.20-0ubuntu0.14.04.1+esm1_amd64.deb  HttpError401
remote:
remote: E: Failed to fetch https://esm.ubuntu.com/ubuntu/pool/main/l/lame/libmp3lame0_3.99.5+repack1-3ubuntu1+esm2_amd64.deb  HttpError401
remote:
remote: E: Failed to fetch https://esm.ubuntu.com/ubuntu/pool/main/liba/libav/libavcodec54_9.20-0ubuntu0.14.04.1+esm1_amd64.deb  HttpError401
remote:
remote: E: Some files failed to download

...when using an Aptfile containing:

libchromaprint-dev

Dependencies are not installed

Hi!

I'm using this buildpack on Dokku and it seems that it goes through the install process but when the app gets deployed and I try to run the packages installed by this buildpack, the app cannot find them :(

Any clues?
Thanks!

GDAL/gdalsrsinfo problems.

When I try to use gdalsrsinfo from heroku bash I get the asnwer:

gdalsrsinfo: error while loading shared libraries: libblas.so.3: cannot open shared object file: No such file or directory

Tried to fix the situation but without success.

My build pack set is:

1. https://github.com/heroku/heroku-buildpack-apt 2. heroku/ruby

I'm using:
Stack: heroku-18

Does this support adding a ppa using gpg?

What I'd like to do is install souffle on my node. Following the souffle docs, one would do this:

sudo wget https://souffle-lang.github.io/ppa/souffle-key.public -O /usr/share/keyrings/souffle-archive-keyring.gpg
echo "deb [signed-by=/usr/share/keyrings/souffle-archive-keyring.gpg] https://souffle-lang.github.io/ppa/ubuntu/ stable main" | sudo tee /etc/apt/sources.list.d/souffle.list
sudo apt update
sudo apt install souffle

I haven't been able to find any examples of Aptfiles that seem to reflect this situation. Advice? Thanks in advance...

Packages are extracted but not configured

The compile script uses dpkg -x to extract the packages, but this results in post-installation steps not being run. I suspect this is the cause of some of the LD_LIBRARY_PATH issues that have been opened.

In a recent investigation, we determined that a problem for our application was that some libraries were being installed but no symlink in /app/.apt/usr/lib created for them because these symlinks are created only when dpkg --configure is run.

Unfortunately, this opens some new questions. Since configuration of a package might run post-installation steps, the paths need to be the same as they would be for a regular installation. The only way I can think to do that would be to run in a chroot. However, we wouldn't want to debootstrap a full base system into the slug. We would probably want things like the alternatives system to exist.

There may be no easy way to resolve this, but I thought it best to open an issue to share the knowledge gained by struggling with our application.

Is there a way to add repositories?

I have the following dependencies:

sudo add-apt-repository ppa:fkrull/deadsnakes -y
sudo add-apt-repository ppa:mc3man/trusty-media -y
sudo add-apt-repository ppa:chris-lea/libsodium -y

but I'm not sure I can add a repository with this buildpack. Can someone point me in the right direction?

Packages not installing

Just started seeing errors this morning when spinning up our review apps.
We suspect it's related to #51, but have not yet had the time to investigate thoroughly. Will try have a deeper look later.

# Aptfile
:repo:deb [ arch=amd64 ] https://repo.mongodb.org/apt/ubuntu trusty/mongodb-org/4.0 multiverse
mongodb-org-tools

Deploying apt & python app

Hello.
I'm trying to deploy a python app that uses PyAudio but I need the portaudio library so I'm using this buildpack to install it.
The packages installation goes smoothly, but the issue now is that the python app is not recognized and therefore doesn't get deployed (I think??)

What I had before using the buildpack (missing portaudio) :

remote: Building source:
remote: 
remote: -----> Building on the Heroku-18 stack
remote: -----> Python app detected
remote: -----> Installing python-3.6.12
remote: -----> Installing pip 20.1.1, setuptools 47.1.1 and wheel 0.34.2
remote: -----> Installing SQLite3
remote: -----> Installing requirements with pip
remote:        Collecting click==7.1.2
remote:          Downloading click-7.1.2-py2.py3-none-any.whl (82 kB)
remote:        Collecting Flask==1.1.2
remote:          Downloading Flask-1.1.2-py2.py3-none-any.whl (94 kB)
remote:        Collecting gunicorn==20.0.4
remote:          Downloading gunicorn-20.0.4-py2.py3-none-any.whl (77 kB)
[...]
remote:          gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -I/app/.heroku/python/include/python3.6m -c src/_portaudiomodule.c -o build/temp.linux-x86_64-3.6/src/_portaudiomodule.o
remote:          src/_portaudiomodule.c:29:10: fatal error: portaudio.h: No such file or directory
remote:           #include "portaudio.h"
remote:                    ^~~~~~~~~~~~~
remote:          compilation terminated.
remote:          error: command 'gcc' failed with exit status 1
remote:            ----------------------------------------
remote:        ERROR: Command errored out with exit status 1: /app/.heroku/python/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-7a0w08u0/PyAudio/setup.py'"'"'; __file__='"'"'/tmp/pip-install-7a0w08u0/PyAudio/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-4y30wetn/install-record.txt --single-version-externally-managed --compile --install-headers /app/.heroku/python/include/python3.6m/PyAudio Check the logs for full command output.
remote:  !     Push rejected, failed to compile Python app.
remote: 
remote:  !     Push failed
remote: Verifying deploy...
remote: 
remote: !	Push rejected to fathomless-oasis-61053.
remote: 
To https://git.heroku.com/fathomless-oasis-61053.git
 ! [remote rejected] master -> master (pre-receive hook declined)

With the buildpack :

remote: Compressing source files... done.
remote: Building source:
remote: 
remote: -----> Building on the Heroku-18 stack
remote: -----> Apt app detected
remote: -----> Detected Aptfile or Stack changes, flushing cache
remote: -----> Adding custom repositories
remote: -----> Updating apt caches
remote:        Hit:1 http://archive.ubuntu.com/ubuntu bionic InRelease
remote:        Hit:2 http://archive.ubuntu.com/ubuntu bionic-security InRelease
remote:        Hit:3 http://archive.ubuntu.com/ubuntu bionic-updates InRelease
remote:        Hit:4 http://apt.postgresql.org/pub/repos/apt bionic-pgdg InRelease
remote:        Reading package lists...
remote: -----> Fetching .debs for python-all-dev
remote:        Reading package lists...
remote:        Building dependency tree...
remote:        The following additional packages will be installed:
remote:          libpython-all-dev python-all
remote:        The following NEW packages will be installed:
remote:          libpython-all-dev python-all python-all-dev
remote:        0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
remote:        Need to get 3,268 B of archives.
remote:        After this operation, 18.4 kB of additional disk space will be used.
remote:        Get:1 http://archive.ubuntu.com/ubuntu bionic/main amd64 libpython-all-dev amd64 2.7.15~rc1-1 [1,092 B]
remote:        Get:2 http://archive.ubuntu.com/ubuntu bionic/main amd64 python-all amd64 2.7.15~rc1-1 [1,076 B]
remote:        Get:3 http://archive.ubuntu.com/ubuntu bionic/main amd64 python-all-dev amd64 2.7.15~rc1-1 [1,100 B]
remote:        Fetched 3,268 B in 0s (14.8 kB/s)
remote:        Download complete and in download only mode
remote: -----> Fetching .debs for portaudio19-dev
remote:        Reading package lists...
remote:        Building dependency tree...
remote:        The following additional packages will be installed:
remote:          libasound2 libasound2-data libasound2-dev libjack-dev libjack0 libportaudio2
remote:          libportaudiocpp0 uuid-dev
remote:        Suggested packages:
remote:          libasound2-plugins alsa-utils libasound2-doc jackd1 portaudio19-doc
remote:        The following NEW packages will be installed:
remote:          libasound2 libasound2-data libasound2-dev libjack-dev libjack0 libportaudio2
remote:          libportaudiocpp0 portaudio19-dev uuid-dev
remote:        0 upgraded, 9 newly installed, 0 to remove and 0 not upgraded.
remote:        Need to get 1,037 kB of archives.
remote:        After this operation, 6,353 kB of additional disk space will be used.
remote:        Get:1 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libasound2-data all 1.1.3-5ubuntu0.5 [38.7 kB]
remote:        Get:2 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libasound2 amd64 1.1.3-5ubuntu0.5 [360 kB]
remote:        Get:3 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 libasound2-dev amd64 1.1.3-5ubuntu0.5 [123 kB]
remote:        Get:4 http://archive.ubuntu.com/ubuntu bionic/universe amd64 libjack0 amd64 1:0.125.0-3 [94.4 kB]
remote:        Get:5 http://archive.ubuntu.com/ubuntu bionic-security/main amd64 uuid-dev amd64 2.31.1-0.4ubuntu3.7 [33.2 kB]
remote:        Get:6 http://archive.ubuntu.com/ubuntu bionic/universe amd64 libjack-dev amd64 1:0.125.0-3 [204 kB]
remote:        Get:7 http://archive.ubuntu.com/ubuntu bionic/universe amd64 libportaudio2 amd64 19.6.0-1 [64.6 kB]
remote:        Get:8 http://archive.ubuntu.com/ubuntu bionic/universe amd64 libportaudiocpp0 amd64 19.6.0-1 [15.1 kB]
remote:        Get:9 http://archive.ubuntu.com/ubuntu bionic/universe amd64 portaudio19-dev amd64 19.6.0-1 [104 kB]
remote:        Fetched 1,037 kB in 1s (1,653 kB/s)
remote:        Download complete and in download only mode
remote: -----> Installing libasound2_1.1.3-5ubuntu0.5_amd64.deb
remote: -----> Installing libasound2-data_1.1.3-5ubuntu0.5_all.deb
remote: -----> Installing libasound2-dev_1.1.3-5ubuntu0.5_amd64.deb
remote: -----> Installing libjack0_1%3a0.125.0-3_amd64.deb
remote: -----> Installing libjack-dev_1%3a0.125.0-3_amd64.deb
remote: -----> Installing libportaudio2_19.6.0-1_amd64.deb
remote: -----> Installing libportaudiocpp0_19.6.0-1_amd64.deb
remote: -----> Installing libpython-all-dev_2.7.15~rc1-1_amd64.deb
remote: -----> Installing portaudio19-dev_19.6.0-1_amd64.deb
remote: -----> Installing python-all_2.7.15~rc1-1_amd64.deb
remote: -----> Installing python-all-dev_2.7.15~rc1-1_amd64.deb
remote: -----> Installing uuid-dev_2.31.1-0.4ubuntu3.7_amd64.deb
remote: -----> Writing profile script
remote: -----> Rewrite package-config files
remote: -----> Discovering process types
remote:        Procfile declares types -> web
remote: 
remote: -----> Compressing...
remote:        Done: 37.9M
remote: -----> Launching...
remote:        Released v5
remote:        https://fathomless-oasis-61053.herokuapp.com/ deployed to Heroku
remote: 
remote: Verifying deploy... done.
To https://git.heroku.com/fathomless-oasis-61053.git
   b74a379..e63780b  master -> master

Is there anyway to make the app be recognized as a python app as well as install the apt libraries ? Or is what I'm trying to do just impossible?
Thank you

buildpack broken need help - E: Unable to locate package unixodbc

Please fix/assist so i can run my app.

-----> Building on the Heroku-20 stack
-----> Using buildpacks:
       1. https://github.com/heroku/heroku-buildpack-apt
       2. https://github.com/heroku/heroku-buildpack-python.git
       3. https://github.com/matt-bertoncello/python-pyodbc-buildpack.git
       4. heroku/python
-----> Apt app detected
-----> Detected Aptfile or Stack changes, flushing cache
-----> Updating apt caches
       Get:1 http://apt.postgresql.org/pub/repos/apt focal-pgdg InRelease [86.6 kB]
       Get:2 http://archive.ubuntu.com/ubuntu focal InRelease [265 kB]
       Get:3 http://apt.postgresql.org/pub/repos/apt focal-pgdg/main amd64 Packages [365 kB]
       Get:4 http://archive.ubuntu.com/ubuntu focal-security InRelease [114 kB]
       Get:5 http://archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]
       Get:6 http://archive.ubuntu.com/ubuntu focal/main amd64 Packages [1,275 kB]
       Get:7 http://archive.ubuntu.com/ubuntu focal/universe amd64 Packages [11.3 MB]
       Get:8 http://archive.ubuntu.com/ubuntu focal-security/universe amd64 Packages [863 kB]
       Get:9 http://archive.ubuntu.com/ubuntu focal-security/main amd64 Packages [1,721 kB]
       Get:10 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 Packages [1,149 kB]
       Get:11 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages [2,136 kB]
       Fetched 19.4 MB in 2s (9,007 kB/s)
       Reading package lists...
-----> Fetching .debs for unixodbc
       Reading package lists...
       Building dependency tree...
E: Unable to locate package unixodbc
 !     Push rejected, failed to compile Apt app.
 !     Push failed

Version in Aptfile

Is there a way to specify the version of a dependency in an Aptfile?
If so, will you add an example of that in the README, please?
If not, will you add a syntax for it… something like a Gemfile?

Thanks!

fail to run GCC at runtime after successfully installed build-essential package

I'm trying to find a way to execute a gcc task at runtime on a Heroku-16 stack.
To do that I created an Aptfile with only one row:

build-essential

but, after the packacage is succesfully installed at build time:

remote: -----> Installing build-essential_12.1ubuntu2_amd64.deb

when i call gcc at runtime, it fails with:

gcc: Command not found

Stack changes don't clear the buildpack cache

The buildpack only checks to see if the user-provided Aptfile has changed, when deciding whether to bust the cache:

if [ -f $APT_CACHE_DIR/Aptfile ] && cmp -s $BUILD_DIR/Aptfile $APT_CACHE_DIR/Aptfile ; then
# Old Aptfile is the same as new
topic "Reusing cache"
else
# Aptfile changed or does not exist
topic "Detected Aptfile changes, flushing cache"

This means that if users upgrade the stack, it will try to re-use the old cache/sources list, which will likely fail.

Compiling fails with custom apt repo

I've been using heroku/python + heroku-buildpack-apt for years with the following Aptfile to build maxminds C extension:

:repo:deb http://ppa.launchpad.net/maxmind/ppa/ubuntu xenial main
libmaxminddb0 libmaxminddb-dev mmdb-bin

but deploys started failing about a week ago.

Build log shows very limited information:

remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> Building on the Heroku-20 stack
remote: -----> Apt app detected
remote: -----> Detected Aptfile or Stack changes, flushing cache
remote: -----> Adding custom repositories
remote: -----> Updating apt caches
remote:        Get:1 http://ppa.launchpad.net/maxmind/ppa/ubuntu focal InRelease [18.1 kB]
remote:        Hit:2 http://archive.ubuntu.com/ubuntu focal InRelease
remote:        Get:3 http://archive.ubuntu.com/ubuntu focal-security InRelease [109 kB]
remote:        Err:1 http://ppa.launchpad.net/maxmind/ppa/ubuntu focal InRelease
remote:          The following signatures couldn't be verified because the public key is not available: NO_PUBKEY DE1997DCDE742AFA
remote:        Hit:4 http://apt.postgresql.org/pub/repos/apt focal-pgdg InRelease
remote:        Get:5 http://archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]
remote:        Get:6 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages [974 kB]
remote:        Get:7 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 Packages [910 kB]
remote:        Reading package lists...
remote: W: GPG error: http://ppa.launchpad.net/maxmind/ppa/ubuntu focal InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY
remote: E: The repository 'http://ppa.launchpad.net/maxmind/ppa/ubuntu focal InRelease' is not signed.
remote:  !     Push rejected, failed to compile Apt app.
remote:
remote:  !     Push failed

It started out on the Heroku-18 stack but upgrading to Heroku-20 didn't change anything. I also tried changing the repository list to focal main which made no difference.

The GPG warning + "repository is not signed" error hasn't previously stopped builds from compiling.

Pushing a commit with an empty Aptfile results in a successful deploy.

Any idea why this started to fail now?

How to specify gdal version ?

I would like to specify a gdal version in Aptfile but entering "gdal-bin=2.1.3" returns the following error when deployed to Heroku :
Version '2.1.3' for 'gdal-bin' was not found
Any clue ?
Thank you

Aptfile packages "installed" but not installed?

When I run the build the console shows the package(s) being installed (e.g. nano) but when I docker exec into the container there is no sign of them either with which nano or in the /bin/* directory....

Aptfile file:

nano

.buildpacks file:

https://github.com/heroku/heroku-buildpack-apt.git
https://github.com/heroku/heroku-buildpack-php.git#v180

Build Log:

-----> Cleaning up...
-----> Building new from herokuish...
-----> Adding BUILD_ENV to build environment...
-----> Warning: Multiple default buildpacks reported the ability to handle this app. The first buildpack in the list below will be used.
       Detected buildpacks: multi php
-----> Multipack app detected
=====> Downloading Buildpack: https://github.com/heroku/heroku-buildpack-apt.git
=====> Detected Framework: Apt
-----> Reusing cache
-----> Updating apt caches
       Hit:1 http://apt.postgresql.org/pub/repos/apt bionic-pgdg InRelease
       Hit:2 http://archive.ubuntu.com/ubuntu bionic InRelease
       Get:3 http://archive.ubuntu.com/ubuntu bionic-security InRelease [88.7 kB]
       Get:4 http://archive.ubuntu.com/ubuntu bionic-updates InRelease [88.7 kB]
       Fetched 177 kB in 0s (429 kB/s)
       Reading package lists...
-----> Fetching .debs for nano
       Reading package lists...
       Building dependency tree...
       Suggested packages:
       spell
       The following NEW packages will be installed:
       nano
       0 upgraded, 1 newly installed, 0 to remove and 28 not upgraded.
       Need to get 0 B/231 kB of archives.
       After this operation, 778 kB of additional disk space will be used.
       Download complete and in download only mode
-----> Installing nano_2.9.3-2_amd64.deb
-----> Writing profile script
-----> Rewrite package-config files
=====> Downloading Buildpack: https://github.com/heroku/heroku-buildpack-php.git
=====> Detected Framework: PHP
remote: -----> Bootstrapping...
remote: -----> Installing platform packages...
remote:        - php (7.4.10)
remote:        - ext-gd (bundled with php)
remote:        - ext-mbstring (bundled with php)
remote:        - apache (2.4.46)
remote:        - nginx (1.18.0)
remote: -----> Installing dependencies...
remote:        Composer version 1.10.13 2020-09-09 11:46:34
remote:        Loading composer repositories with package information
remote:        Installing dependencies from lock file
remote:        Package operations: 59 installs, 0 updates, 0 removals
remote:          - Installing cweagans/composer-patches (1.6.7): Loading from cache
remote:          - Installing symfony/polyfill-php80 (v1.18.1): Loading from cache
remote:          - Installing symfony/process (v5.1.5): Loading from cache
remote:          - Installing symfony/finder (v5.1.5): Loading from cache
remote:          - Installing symfony/polyfill-ctype (v1.18.1): Loading from cache
remote:          - Installing symfony/filesystem (v5.1.5): Loading from cache
remote:          - Installing symfony/polyfill-mbstring (v1.18.1): Loading from cache
remote:          - Installing symfony/polyfill-intl-normalizer (v1.18.1): Loading from cache
remote:          - Installing symfony/polyfill-intl-grapheme (v1.18.1): Loading from cache
remote:          - Installing symfony/string (v5.1.5): Loading from cache
remote:          - Installing psr/container (1.0.0): Loading from cache
remote:          - Installing symfony/service-contracts (v2.2.0): Loading from cache
remote:          - Installing symfony/polyfill-php73 (v1.18.1): Loading from cache
remote:          - Installing symfony/console (v5.1.5): Loading from cache
remote:          - Installing seld/phar-utils (1.1.1): Loading from cache
remote:          - Installing seld/jsonlint (1.8.2): Loading from cache
remote:          - Installing psr/log (1.1.3): Loading from cache
remote:          - Installing justinrainbow/json-schema (5.2.10): Loading from cache
remote:          - Installing composer/xdebug-handler (1.4.3): Loading from cache
remote:          - Installing composer/spdx-licenses (1.5.4): Loading from cache
remote:          - Installing composer/semver (1.7.0): Loading from cache
remote:          - Installing composer/ca-bundle (1.2.8): Loading from cache
remote:          - Installing composer/composer (1.10.13): Loading from cache
remote:          - Installing gettext/languages (2.6.0): Loading from cache
remote:          - Installing gettext/gettext (v4.8.2): Loading from cache
remote:          - Installing mck89/peast (v1.10.4): Loading from cache
remote:          - Installing mustache/mustache (v2.13.0): Loading from cache
remote:          - Installing nb/oxymel (v0.1.0): Loading from cache
remote:          - Installing rmccue/requests (v1.7.0): Loading from cache
remote:          - Installing wp-cli/mustangostang-spyc (0.6.3): Loading from cache
remote:          - Installing wp-cli/php-cli-tools (v0.11.11): Loading from cache
remote:          - Installing wp-cli/wp-cli (v2.4.1): Loading from cache
remote:          - Installing wp-cli/widget-command (v2.1.1): Loading from cache
remote:          - Installing wp-cli/super-admin-command (v2.0.4): Loading from cache
remote:          - Installing wp-cli/shell-command (v2.0.5): Loading from cache
remote:          - Installing wp-cli/server-command (v2.0.5): Loading from cache
remote:          - Installing wp-cli/search-replace-command (v2.0.7): Loading from cache
remote:          - Installing wp-cli/scaffold-command (v2.0.8): Loading from cache
remote:          - Installing wp-cli/role-command (v2.0.4): Loading from cache
remote:          - Installing wp-cli/rewrite-command (v2.0.5): Loading from cache
remote:          - Installing wp-cli/package-command (v2.0.6): Loading from cache
remote:          - Installing wp-cli/media-command (v2.0.9): Loading from cache
remote:          - Installing wp-cli/maintenance-mode-command (v2.0.3): Loading from cache
remote:          - Installing wp-cli/language-command (v2.0.7): Loading from cache
remote:          - Installing wp-cli/import-command (v2.0.3): Loading from cache
remote:          - Installing wp-cli/i18n-command (v2.2.5): Loading from cache
remote:          - Installing wp-cli/extension-command (v2.0.10): Loading from cache
remote:          - Installing wp-cli/export-command (v2.0.4): Loading from cache
remote:          - Installing wp-cli/eval-command (v2.0.7): Loading from cache
remote:          - Installing wp-cli/entity-command (v2.0.7): Loading from cache
remote:          - Installing wp-cli/embed-command (v2.0.6): Loading from cache
remote:          - Installing wp-cli/db-command (v2.0.6): Loading from cache
remote:          - Installing wp-cli/cron-command (v2.0.5): Loading from cache
remote:          - Installing wp-cli/core-command (v2.0.11): Loading from cache
remote:          - Installing wp-cli/wp-config-transformer (v1.2.7): Loading from cache
remote:          - Installing wp-cli/config-command (v2.0.6): Loading from cache
remote:          - Installing wp-cli/checksum-command (v2.0.4): Loading from cache
remote:          - Installing wp-cli/cache-command (v2.0.4): Loading from cache
remote:          - Installing wp-cli/wp-cli-bundle (v2.4.0): Loading from cache
remote:        Generating optimized autoload files
remote:        Deprecation Notice: Class WP_CLI located in ./vendor/wp-cli/wp-cli/php/class-wp-cli.php does not comply with psr-0 autoloading standard. It will not autoload anymore in Composer v2.0. in phar:///tmp/build/.heroku/php/bin/composer/src/Composer/Autoload/ClassMapGenerator.php:201
remote:        Deprecation Notice: Class WP_CLI_Command located in ./vendor/wp-cli/wp-cli/php/class-wp-cli-command.php does not comply with psr-0 autoloading standard. It will not autoload anymore in Composer v2.0. in phar:///tmp/build/.heroku/php/bin/composer/src/Composer/Autoload/ClassMapGenerator.php:201
remote: -----> Preparing runtime environment...
remote: -----> Checking for additional extensions to install...
       Using release configuration from last framework (PHP).
-----> Discovering process types
       Procfile declares types -> web
-----> Releasing new...
-----> Deploying new...
-----> App Procfile file found
       DOKKU_SCALE declares scale -> web=1
=====> Processing deployment checks
       No CHECKS file found. Simple container checks will be performed.
       For more efficient zero downtime deployments, create a CHECKS file. See http://dokku.viewdocs.io/dokku/deployment/zero-downtime-deploys/ for examples
-----> Attempting pre-flight checks (web.1)
       Waiting for 10 seconds ...
       Default container check successful!
-----> Running post-deploy
-----> Overriding default nginx.conf with detected nginx.conf.sigil
-----> Configuring new.seabirdtracking.org...(using app-supplied template)
-----> Creating https nginx.conf
       Enabling HSTS
       Reloading nginx
-----> Renaming containers
       Found previous container(s) (fcd308bd3b74) named new.web.1

Any idea what's going on?

how does versioning work? get the latest version of vips?

We are interested in the vips package. But we discovered we actually need the latest minor version of vips, 8.10.x. 8.9.x has problems for us, we need the latest.

When we just add vips to Aptfile, we get an 8.9 version. (We are running on heroku-20 using ubuntu 20, not sure if that matters for what version of thing you will get from Aptfile).

In an attempt to force the particular more recent version of vips we want, we add to Aptfile a specfic url:

http://ftp.us.debian.org/debian/pool/main/v/vips/libvips-tools_8.10.5-1_amd64.deb 

But then we get errors like: LoadError: Could not open library 'vips.so.42': vips.so.42: cannot open shared object file: No such file or directory.

Not sure what's going on with that.

I realize I don't have a handle on the basic theory/model here, not being super familiar with sysadmin'ing linux packages from the start (hey that's why we're on heroku!). What determines what version gets installed when I just add vips to Aptfile? Ought I be able to force an 8.10 version, is it expected there should be a way to do that? And if so, through what manner?

xpath fails after installation

Problem is that Perl libs are in a non-standard location. Fix is to add

export PERL5LIB=/app/.apt/usr/share/perl5:/app/.apt/usr/lib/x86_64-linux-gnu/perl5/5.22

to .profile.d/000_apt.sh

error while loading shared libraries: libblas.so.3 in apt/user folder

Hello there,
my buildpack sequence is:

my Aptfile looks like this:

  • flex
  • bison
  • libatlas3-base
  • libatlas-dev
  • libatlas3gf-base
  • libatlas-base-dev
  • nmap

When I try to use nmap I am getting this error:

nmap: error while loading shared libraries: libblas.so.3: cannot open shared object file: No such file or directory

I then ps:exec into the application and did find the files here:

./.apt/usr/lib/x86_64-linux-gnu/blas/libblas.so.3
./.apt/usr/lib/x86_64-linux-gnu/atlas/libblas.so.3

So there seems to be an issue with the LD_LIBRARY_PATH in the python package, but when I checked here:

https://github.com/robomotic/heroku-buildpack-python/blob/master/bin/compile

I can see the variables set up correctly:

export LIBRARY_PATH=/app/.heroku/vendor/lib:/app/.heroku/python/lib:$LIBRARY_PATH
export LD_LIBRARY_PATH=/app/.heroku/vendor/lib:/app/.heroku/python/lib:$LD_LIBRARY_PATH

~ $ echo $LIBRARY_PATH
/app/.heroku/vendor/lib:/app/.heroku/python/lib:/app/.apt/usr/lib/x86_64-linux-gnu:/app/.apt/usr/lib/i386-linux-gnu:/app/.apt/usr/lib:

~ $ echo $LD_LIBRARY_PATH
/app/.heroku/vendor/lib:/app/.heroku/python/lib:/app/.apt/usr/lib/x86_64-linux-gnu:/app/.apt/usr/lib/i386-linux-gnu:/app/.apt/usr/lib:

Any help debugging this is appreciated.

Cheers.

Any way to purge apt-get packages?

It seems that some dependencies are placed in wrong locations.

I want to use openvpn from Heroku, and it needs liblzo2-2. liblzo2-2 had been installed on this particular server since some time ago and apt-get recognizes that it doesn't need to install it. I need to purge both openvpn and liblzo2-2 so the dependencies are installed in the right places.

Is there a way to purge the packages before we run install?

Getting libhunspell-dev

When deploying an app that requires the python "hunspell" module, I need to install "libhunspell-dev" first. However, even if I include "libhunspell-dev", pip is unable to locate the "hunspell.h" header file and fails to install the hunspell module.
I wondered if this issue could be related to the implementation of this buildpack.

Thank you.

Missing $LD_LIBRARY_PATH entry?

My Aptfile contains only libaio1. The package is installed without problems, but when the app at runtime is trying to refer to it, the error is throws that libaio.so.1 can't be found.

I think that is because $LD_LIBRARY_PATH is missing its location:

flynn@9b481505-8ca2-44fc-87e2-a8f9e8fba8e3:~$ echo $LD_LIBRARY_PATH
OTHER_ENTRIES:/app/.apt/usr/lib/x86_64-linux-gnu:/app/.apt/usr/lib/i386-linux-gnu:/app/.apt/usr/lib:

But that file ends up in

flynn@9b481505-8ca2-44fc-87e2-a8f9e8fba8e3:~$ ls .apt/lib/x86_64-linux-gnu/
libaio.so.1  libaio.so.1.0.1

As you can see there is no /usr bit in there.

I have another buildpack of my own that follows after the apt one. I basically hacked that missing value in and that's how I managed to resolve the app's issue (https://github.com/featurist/oracle-client-buildpack/blob/master/profile/oracle-driver-buildpack-runtime-env.sh#L1):

Heroku activity log warnings / possible to add keys & sources?

We have used this buildpack successfully for some time. Installations works - but there are some nonfatal warning and error messages in the Heroku activity log -- which creates two questions:

1- Would it be possible to use this buildpack to issue add keys and sources to sources.list to avoid warnings like those below? I can do this from terminal on a local machine easily, and this buildpack seems to be the appropriate place to do the same automatically on heroku builds. There is an error listed that the repository is not signed, but when manually inspecting the URL (http://repo.mongodb.org/apt/ubuntu/dists/bionic/mongodb-org/4.0/) it seems that the gpg key is in the repo.

2-Is there some configuration I can use in my Aptfile to fix the warning about --force-yes? Am not sure if this results from code in this buildpack, or something else.

The working Aptfile is:

:repo:deb http://repo.mongodb.org/apt/ubuntu bionic/mongodb-org/4.0 multiverse
mongo-tools

Note: for some reason, this failed when we used the [ arch=amd64,arm64 ] prefix to the repo URI.

The current warnings are:

...
W: GPG error: http://repo.mongodb.org/apt/ubuntu bionic/mongodb-org/4.0 Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 68818C72E52529D4
E: The repository 'http://repo.mongodb.org/apt/ubuntu bionic/mongodb-org/4.0 Release' is not signed.
...
W: --force-yes is deprecated, use one of the options starting with --allow instead.
-----> Installing libpcap0.8_1.8.1-6ubuntu1_amd64.deb
-----> Installing mongo-tools_3.6.3-0ubuntu1_amd64.deb

So the installation works, but it is not finding expected keys.

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.