Releases: heroku/libcnb.rs
Releases · heroku/libcnb.rs
v0.23.0
v0.22.0
Added
libcnb
:- A new API for working with layers has been added. See the
BuildContext::cached_layer
andBuildContext::uncached_layer
docs for examples of how to use this API. (#814)
- A new API for working with layers has been added. See the
Changed
libcnb
:
Fixed
libcnb-data
:- The working directory for launch processes specifying a
WorkingDirectory::Directory
value is now respected. (#831)
- The working directory for launch processes specifying a
v0.21.0
v0.20.0
Added
libcnb
:- Made
Target
(the type ofDetectContext::target
andBuildContext::target
) public. (#815)
- Made
Changed
v0.19.0
v0.18.0
Changed
- Now targets Buildpack API 0.10. Buildpacks need to upgrade the
api
key to0.10
in theirbuildpack.toml
. (#773) - Improved the consistency of cross-compilation assistance provided across all supported
target_triple
and host OS/architecture combinations. #769 - Added cross-compilation assistance for
aarch64-unknown-linux-musl
(on macOS and ARM64 Linux) andx86_64-unknown-linux-musl
(on ARM64 Linux). #769 - Raised Minimum Supported Rust Version (MSRV) to
1.76
. (#774) libcnb
:- Changed
Layer
interface from&self
to&mut self
. (#669)
- Changed
Added
libherokubuildpack
:MappedWrite::unwrap
for getting the wrappedWrite
back out. (#765)
Removed
- Types, errors, macros and functions related to stacks. The concept of stacks has been removed from the CNB spec. Use
Target
instead. (#773)
v0.17.0
Added
libcnb
:- An optional
trace
feature has been added that emits OpenTelemetry tracing
data to a File Export. (#723)
- An optional
v0.16.0
Changed
- Raised Minimum Supported Rust Version (MSRV) to
1.74
. (#747) - Improved the consistency of all user-facing libcnb.rs error message wordings. (#722)
- The assistance error message shown when the necessary cross-compilation tools are not found now also includes the
rustup target add
step. (#729) - Updated the documentation for
TestRunner::build
andTestContext::start_container
to mention when Docker resource teardown occurs. (#743)
Fixed
libcnb-test
:- Fixed incorrect error messages being shown for buildpack compilation/packaging failures. (#720)
- The Docker volumes created by Pack for the build and launch layer caches are now cleaned up after each test. (#741)
- The Docker image cleanup process no longer makes duplicate attempts to remove images when using
TestContext::rebuild
. (#741) - Test failures due to the Docker daemon not being installed or started no longer cause a non-unwinding panic abort with noisy traceback. (#741)
- Containers created by
TestContext::start_container
are now correctly cleaned up if the container failed to start. (#742)
v0.15.0
Added
libcnb
:LayerTypes
now implementsCopy
andClone
. (#670).
libcnb-data
:ExecDProgramOutputKey
,ProcessType
,LayerName
,BuildpackId
andStackId
now implementOrd
andPartialOrd
. (#658)- Added
generic::GenericMetadata
as a generic metadata type. Also makes it the default forBuildpackDescriptor
,SingleBuildpackDescriptor
,CompositeBuildpackDescriptor
andLayerContentMetadata
. (#664)
libcnb-test
:- Added the
BuildpackReference::WorkspaceBuildpack
enum variant. This allows for the testing of any libcnb.rs or composite buildpack in the Cargo workspace, instead of only the buildpack of the current crate. Note: The testing of composite buildpacks requirespack
CLI version>=0.30
. (#666)
- Added the
Changed
libcnb-data
:- Renamed the
buildpackage
module topackage_descriptor
, and theBuildpackage*
types within it toPackageDescriptor*
. (#656) - Renamed multiple types to match the new composite vs component buildpack upstream terminology. Renamed
SingleBuildpackDescriptor
toComponentBuildpackDescriptor
,MetaBuildpackDescriptor
toCompositeBuildpackDescriptor
andBuildpackDescriptor::{Single,Meta}
toBuildpackDescriptor::{Component,Composite}
. (#682)
- Renamed the
libcnb-cargo
:libcnb-test
:- Renamed
BuildpackReference::Crate
toBuildpackReference::CurrentCrate
. (#666)
- Renamed
v0.14.0
Added
libcnb-package
: Added cross-compilation assistance for Linuxaarch64-unknown-linux-musl
. (#577)libcnb-cargo
: Added--package-dir
command line option to control where packaged buildpacks are written. (#583)libcnb-test
:
Changed
libcnb-cargo
: Moved the default location for packaged buildpacks from Cargo'starget/
directory topackaged/
in the Cargo workspace root. This simplifies the path and stops modification of thetarget/
directory which previously might have caching implications when other tools didn't expect non-Cargo output in that directory. Users that implicitly rely on the output directory need to adapt. The output ofcargo libcnb package
will refer to the new locations. (#583)libcnb-package
:libcnb-test
:ContainerContext::address_for_port
will now panic for all failure modes rather than just some, and so now returnsSocketAddr
directly instead ofOption<SocketAddr>
. This reduces test boilerplate due to the caller no longer needing to.unwrap()
and improves debugging UX when containers crash after startup. (#605 and #636)- Docker commands are now run using the Docker CLI instead of Bollard and the Docker daemon API. (#620)
ContainerConfig::entrypoint
now accepts a String rather than a vector of strings. Any arguments to the entrypoint should be moved toContainerConfig::command
. (#620)- Removed
TestRunner::new
since its only purpose was for advanced configuration that's no longer applicable. UseTestRunner::default
instead. (#620) - Removed
stdout_raw
andstderr_raw
fromLogOutput
. (#607) - Improved wording of panic error messages. (#619 and #620)
libherokubuildpack
: Changed theflate2
decompression backend fromminiz_oxide
tozlib
. (#593)
Fixed
libcnb-test
:TestContext::run_shell_command
andContainerContext::shell_exec
now validate the exit code of the spawned commands and panic if they are non-zero. (#620)ContainerContext::expose_port
now only exposes the port to localhost. (#610)- If a test with an expected result of
PackResult::Failure
unexpectedly succeeds, the built app image is now correctly cleaned up. (#625)