Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to libcnb 0.12.0 and Buildpack API 0.9 #150

Closed
wants to merge 4 commits into from

Commits on Apr 28, 2023

  1. Update to libcnb 0.12.0 and Buildpack API 0.9

    libcnb 0.12.0 includes an upgrade from Buildpack APi 0.8 to 0.9:
    https://github.com/heroku/libcnb.rs/releases/tag/v0.12.0
    
    In buildpack API 0.9 implicit usage of bash via `direct=false` mode has
    been removed:
    https://github.com/buildpacks/spec/releases/tag/buildpack%2Fv0.9
    https://github.com/buildpacks/rfcs/blob/main/text/0093-remove-shell-processes.md
    
    As such, this buildpack now needs to explicitly wrap the procfile commands in a
    `bash -c "exec <command>"` invocation, similar to what the Python CNB already
    does for Python Functions:
    https://github.com/heroku/buildpacks-python/blob/76795e93cac436724b0f854c22b8df058418e728/src/salesforce_functions.rs#L57-L76
    
    Closes #147.
    Closes #148.
    Closes #149.
    GUS-W-13119392.
    edmorley committed Apr 28, 2023
    Configuration menu
    Copy the full SHA
    65cb0e8 View commit details
    Browse the repository at this point in the history
  2. Add a complex procfile command integration test

    Which demonstrates the issues with prefixing the command with `exec`.
    edmorley committed Apr 28, 2023
    Configuration menu
    Copy the full SHA
    2605a12 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    73aaa57 View commit details
    Browse the repository at this point in the history
  4. Don't prefix the command with exec

    Since:
    - for single command procfile entires, using `bash -c <command>` already implicitly uses exec (making `exec` redundant)
    - for more complex compound command procfile entries exec should not be used otherwise later commands won't run (eg only `foo` would get run in `exec foo && bar`)
    edmorley committed Apr 28, 2023
    Configuration menu
    Copy the full SHA
    382d96e View commit details
    Browse the repository at this point in the history