All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
- (Breaking change) Renamed module from github.com/PlanktoScope/forklift to github.com/forklift-run/forklift .
- (cli) Improve some stdout messages
No changes since v0.8.0-beta.1.
- (cli) Improved warning messages printed when an optional background update of a local mirror of a Git repo fails (e.g. due to lack of internet access) to better reassure the user that it might not be a problem.
- (cli) If
plt switchis run without internet access, now instead of quitting immediately with an error (due to being unable to fetch changes from remotes) the subcommand will print a warning and continue until either the operation fails (because it couldn't determine that the current commit of the current pallet is in the cache's local mirror of the remote origin) or succeeds (because the commit is in the local mirror, or because--forcewas set).
- (cli) Added a default-true
--set-upgrade-queryboolean flag to theplt clone,plt switch, andplt upgradesubcommands which can be set to false to prevent the[pallet_path]@[version_query]query from being saved into the file which tracks the last-used query.
- (Breaking change; cli) The
--no-cache-imgflag has been replaced with--cache-img=false; and the--no-cache-reqflag has been replaced with--cache-req=falseto avoid causing double-negatives and to make flag naming slightly more logical.
- (cli) In cases where trying to run
plt upgradewithout the--forceflag (in order to upgrade from a commit which was only ancestral to the origin repo's references) incorrectly failed, now that operation should work.
- (cli) Symlinks to nonexistent targets no longer fail to be merged in as part of file imports from pallets.
- (spec) Added an optional
permissionsfield to file exports in the packaging spec. If specified, this field enables overriding the source file's Unix permissions with an explicitly-provided permissions value for creating a regular file at the target path. The permissions should be specified as an octal value (e.g.0644). - (spec) Now the bundle manifest file's
exportssection lists information about the Docker Compose apps created by the bundle's package deployments. - (spec) Now the bundle manifest file's
downloadssection lists OCI images to be cached for Docker Compose apps; this is enabled by a breaking change in the layout of that section, described below. - (cli) Now
stage show-bunprints information about required pallets in the "Includes" section.
- (Breaking change; cli) The verbs
rmandremovehave been deleted from all commands (e.g.forklift pallet rm), because the two-character verbrmdoesn't line up nicely with the three-character verbadd;delordeleteshould be used instead (e.g.forklift pallet del). - (Breaking change; spec) Now the bundle manifest file's
downloadssection lists different download types (e.g. HTTP file download vs. OCI image download) separately, instead of merging them all into one list. - (Breaking change; spec) Now the bundle manifest file's
exportssection lists different exports types (e.g. exported file vs. Docker compose app) separately, instead of merging them all into one list.
- (cli) Now empty lists are omitted from bundle manifest files.
- (cli) Git progress log messages are now printed to stderr instead of stdout.
- (Breaking change; cli) Log messages are now (supposed to be) printed to stderr instead of stdout; stdout is only meant to be used for outputting values meant to be piped or captured in a subshell.
- (cli) Added a
inspector resolve-git-repocommand to resolve version queries on git repositories.
- (cli) The
[dev] plt show-plt-versionand[dev] plt show-repo-versioncommands no longer require the required pallets/repos to be cached before the respective commands work.
- (cli) Added
[dev] plt show-plt-versionand[dev] plt show-repo-versioncommands to print the version/pseudoversion string for the required version of the specified pallet/repo. - (cli) Added a
stage show-next-indexcommand to print the index of the next staged pallet bundle (if it exists). - (cli) Added a
--platformflag (andFORKLIFT_PLATFORMenv var) to override the auto-detected platform (e.g.linux/amd64orlinux/arm64) used for downloading container images for file exports and for pre-downloading container images needed for the nextforklift stage apply.
- (cli) Added support for
add-featureandremove-featuretypes to file import group modifiers.add-featurewill add all files determined by evaluation of a named feature flag exposed by the import group's referenced pallet, whileremove-featurewill remove those files. Pallet feature flags are constructed with the same file schema as file import groups, but are located in the pallet's/featuresdirectory and have a.feature.ymlfile extension instead. - (cli) Added a
[dev] plt ls-featcommand to list feature flags exposed by the local/development pallet. - (cli) Added a
[dev] plt show-featcommand to show the specified feature exposed by the local/development pallet, including any deprecation notices of deprecated features referenced directly or indirectly by this feature. - (cli) Added a
[dev] plt ls-plt-featcommand to list feature flags exposed by the specified pallet required by the local/development pallet. - (cli) Added a
[dev] plt show-plt-featcommand to show the specified feature exposed by the specified pallet required by the local/development pallet, including any deprecation notices of deprecated features referenced directly or indirectly by this feature. - (cli) Added a
[dev] plt ls-plt-filecommand to list files in the specified pallet required by the local/development pallet, including files imported by that required pallet from its own required pallets. - (cli) Added a
[dev] plt locate-plt-filecommand to print the actual filesystem path of the specified file in the specified pallet required by the local/development pallet. - (cli) Added a
[dev] plt show-plt-filecommand to print the contents of the specified file in the specified pallet required by the local/development pallet. - (cli) Added a
cache rm-dlcommand to delete the cache of downloaded files for export. - (cli) The bundle manifest's
includessection's description of required pallets now reports when required pallets were overridden. - (cli) The bundle manifest's
includessection's description of required pallets now recursively shows information about transitively-required pallets (but does not show information about file import groups in those transitively-required pallets). - (cli) The bundle manifest's
includessection's description of required pallets now shows the results (as target file path -> source file path mappings) of evaluating each file import group attached to their respective required pallets. - (cli) The bundle manifest now has an
importssection which describes the provenance of each imported file, as a list of how the file has been transitively imported across pallets (with pallets farther down the list being depeer in the transitive import chain).
- (Breaking change; cli) Removed some aliases for
[dev] plt add-pltand[dev] plt add-repowhich should not have been added, because they were constructed as a combination of an abbrebiation and an unabbreviated word. - (Breaking change; cli) Now, by default
[dev] plt ls-fileand[dev] plt ls-plt-filedon't list files in hidden directories (i.e. directories whose names start with.) at the root of the pallet. To list all files including those in hidden directories, you should now specify**as the file path glob (e.g. by running[dev] plt ls-file '**'or[dev] plt ls-plt-file required_pallet_path '**'). - (cli) Git repository mirrors of pallets and package repos in the cache are now stored in a single
mirrorssubdirectory of the Forklift workspace, rather than being split/duplicated across thepalletsandrepositoriessubdirectories. - (cli) Suppressed some noisy Git cloning output in
[dev] plt cache-plt,[dev] plt cache-all, and other related commands. - (cli)
[dev] plt show-impnow shows any deprecated notices of deprecated features referenced directly or indirectly by the specified import group.
- (cli) Now repos with packages constructed through pallet layering (for repos which are also layered pallets) can actually be used by other pallets as sources of packages. This is done by merging the pallet as part of the work of downloading it into the cache as a repo.
- (cli) Transitive imports of files across pallets (e.g. importing a file from a pallet which actually imports that file from another pallet) is no longer completely broken (it should work, but there may still be undiscovered bugs because the code paths have not been thoroughly tested).
- (cli)
[dev] plt cache-plt,[dev] plt cache-all, and other related commands now recursively cache all transitively-required pallets of the local/development pallet, instead of only caching directly-required pallets. - (cli)
plt switchandplt upgradenow fetch changes (i.e. branch/tag refs and commit objects) from all remotes before checking whether the current commit of the local pallet exists on some remote, in order to prevent that check from spuriously failing when the remotes have new commits not yet in the local pallet.
- (cli) Added a
[dev] plt add-pltcommand to add a pallet requirement to the local/development pallet. - (cli) Added a
[dev] plt rm-pltcommand to remove a pallet requirement from the local/development pallet. - (cli) Added a
[dev] plt ls-pltcommand to list all pallets required by the local/development pallet. - (cli) Added a
[dev] plt show-pltcommand to show the specified pallet required by the local/development pallet. - (cli) Added a
[dev] plt cache-pltcommand to cache all pallets required by the local/development pallet. - (cli) Added a
[dev] plt ls-impcommand to list all file import groups declared by the local/development pallet. - (cli) Added a
[dev] plt show-impcommand to show the specified file import group declared by the local/development pallet. - (cli) Added a
[dev] plt locate-repocommand to print the actual filesystem path of the specified available package repository. The actual filesystem path may be for a subdirectory in the repositories cache, or a subdirectory in an override repository (in the case ofdev pltwith the--reposflag). - (cli) Added a
[dev] plt locate-pkgcommand to print the actual filesystem path of the specified available package. The actual filesystem path may be for a subdirectory in the repositories cache, or a subdirectory in an override repository (in the case ofdev pltwith the--reposflag), or a subdirectory in the local/development pallet (in the case of a local package defined by the pallet), or a subdirectory in a required pallet (in the case of a local package imported from another pallet). - (cli) Added a
[dev] plt ls-filecommand to list files in the local/development pallet, including files imported by the pallet from required pallets. - (cli) Added a
[dev] plt locate-filecommand to print the actual filesystem path of the specified file in the pallet. The actual filesystem path may be for a file in the pallets cache, or a file in an override pallet (in the case ofdev pltwith the--pltsflag), or a file in the local/development pallet (in the case of a local file defined by the pallet), or a file in a required pallet (in the case of a file imported from another pallet). - (cli) Added a
[dev] plt show-filecommand to print the contents of the specified file in the local/development pallet. - (cli) Added a
[dev] plt edit-filecommand to edit the specified file in the local/development pallet, using the editor set by the$EDITORenvironment variable. If the file was previously only in an underlay, a temporary copy is provided to the editor; if changes are saved when the editor quits, the changed file will be saved as an override file into the local/development pallet. - (cli) Added a
[dev] plt rm-filecommand to delete the specified file/directory in the local/development pallet. If a file/directory still exists after the deletion because of files imported from other pallets, they are listed in a warning message. - (cli) Added a
[dev] plt ls-dlcommand to list all HTTP files and OCI images downloaded by the local/development pallet. - (cli) Added an optional
--pltsflag todev pltfor overriding version-locked required pallets with pallets from other directories, like the existing--reposflag.
- (Breaking change; cli) Now enabled feature flags in each package deployment are considered in alphabetically-sorted order (rather than the exact order used for listing feature flags in the package deployment declaration file) when sequencing file export operations implied by the enabled feature flags.
- (cli) Now the
[dev] plt cache-allcommand, and all commands which can cache staging requirements, will cache pallets required by the local/development pallet. - (cli) Now all
[dev] pltcommands are evaluated on the merged pallet (i.e. with file imports) if the pallet imports files from other pallets. - (cli) Now the
[dev] plt show-pkgandcache show-pkgcommands also print information about file exports. - (cli) Now the commands for viewing a pallet/repo (e.g.
[dev] plt show) truncate the printout of the pallet/repo's readme file to the first ten lines of the file, to prevent long readme files from clogging up the command output. - (cli) Now the
[dev] plt rm-repocommand only deletes the version lock file for the specified repository, instead of deleting the entire subdirectory for the repository. - (cli) Now a pallet can include deployments for local packages even if it's missing a
forklift-repository.ymlfile in the pallet root - in such cases, the repository declaration is automatically inferred from theforklift-pallet.ymlfile for the purposes of using the pallet. However, aforklift-repository.ymlfile is still needed to make the pallet usable as a Forklift package repository by other pallets. - (cli) Now git clone/fetch-related messages are properly indented in command output to stdout.
- (cli) Now Docker image pull & Compose app change messages are properly indented in command output to stdout.
- (spec) Fixed an incorrect example for the
targetfield of the file export object in the packaging spec. - (spec) Fixed a formatting error in the description of the
urlfield of the file export object - (cli) Fixed a regression where the
[dev] plt ls-pkgcommand failed with acache is nilerror on pallets which are not also package repositories. - (cli) Fixed the behavior of
[dev] plt ls-pkgto include local packages (i.e. those declared in the pallet) in the displayed list of packages.
- (cli) Added tracking of the last pallet path@version query used with the
plt cloneandplt switchsubcommands, so that those subcommands can be called again with a partial query (i.e.@version_queryorpallet_path@or@) to reuse the last provided value(s) for omitted parts of the query. - (cli) Added a
--forceflag to theplt switchsubcommand. - (cli) Added a
plt upgradesubcommand as a upgrade-specific version ofplt switch(with additional checks and log messages). - (cli) Added a
plt check-upgradesubcommand to show whether an upgrade is available and, if so, what change to the local pallet would be made byplt upgrade. - (cli) Added a
plt show-upgrade-querysubcommand to show the pallet path@version query which will be used forplt upgradeand forplt clone/switchsubcommands with partial queries. - (cli) Added a
plt set-upgrade-querysubcommand to modify the pallet path@version query which will be used forplt upgradeand forplt clone/switchsubcommands with partial queries. - (cli) Now
plt cloneandplt switchadd aforklift-cache-mirrorremote to the list of remotes of the local pallet, which points to the Forklift pallet cache's mirror of theoriginremote of the local pallet. - (cli) Now
plt showwill print git refs from the Forklift pallet cache's mirror of theoriginremote of the local pallet, if theoriginremote cannot be queried (e.g. due to lack of internet connection).
- (Breaking change; cli) Now
plt switchwill quit early with an error message if you use it to try to replace a local pallet which 1) is not a Git repo, 2) has uncommitted changes, or 3) is on a commit which does not exist in the remote, unless you enable the--forceflag. This is intended to prevent unintentional deletion of user customizations.
- (cli) Previously, the atomic commit mechanism for the stage store state file did not correctly error out if a swap file already existed. This check should now work.
- (cli) Added a
[dev] plt ls-imgsubcommand to list all images deployed by the pallet. - (cli) Subcommands with an
rmverb (short forremove) now havedelverb alias (short fordelete). This enables familiarity with apk (Alpine Package Keeper) commands, and also enablesadd/delas a 3-character verb pair instead ofadd/rmas a verb pair with inconsistent verb length.
(no changes; this release just promotes v0.7.2-alpha.6 to v0.7.2)
- (cli) Hard links should now be handled correctly when they need to be exported from downloaded archives or OCI images.
- (cli) Staging a pallet now includes the download of any missing files, OCI container images, and repos required for staging.
- (cli) Symlinks are now handled correctly when they need to be exported from downloaded archives or OCI images.
- (cli) Allowed the entire filetree in downloaded archives and OCI images to be used as a source for export, by specifying '/' or '.' as the source path.
- (spec) Clarified that, for the
sourcefield of file export resources withsource-typehttp-archiveandoci-image, a value of/or.will be interpreted as specifying that all files in the archive or OCI image will be exported.
- (spec, cli) Added a
oci-imagefile source type (for file export resources) which is downloaded and cached with[dev] plt cache-dland[dev] plt cache-allsubcommands; files can be extracted from the root filesystems of the downloaded OCI container image tarballs and exported as part of the pallet's bundle when the pallet is staged. The bundle's manifest now lists the names of downloaded OCI container images. - (cli) Added
--stageand--applyflags to theplt cloneandplt pullsubcommands to immediately stage/apply the pallet after cloning/pulling. Note thatplt clone --force --stageis equivalent toplt switch, andplt clone --force --applyis equivalent toplt switch --apply.
- (cli) Added a
[dev] plt rm-reposubcommand which removes requirements for the specified repo paths, as an inverse of the[dev] plt add-reposubcommand. - (cli) Added a
[dev] plt add-deplsubcommand which adds a package deployment at the specified deployment name, for the specified package path (and optionally for the specified feature flags and enabled/disabled setting). - (cli) Added a
[dev] plt rm-deplsubcommand which deletes the package deployment declaration(s) at the specified deployment name(s), as the inverse of the[dev] plt add-deplsubcommand. - (cli) Added a
[dev] plt set-depl-pkgsubcommand which modifies a package deployment at the specified deployment name, to change the deployment's package. - (cli) Added a
[dev] plt add-depl-feat(or[dev] plt enable-depl-feat) subcommand which modifies a package deployment at the specified deployment name, to enable the specified feature flags (for feature flags which are not already enabled). - (cli) Added a
[dev] plt rm-depl-feat(or[dev] plt disable-depl-feat) subcommand which modifies a package deployment at the specified deployment name, to disable the specified feature flags (for feature flags which are not already disabled), as the inverse of the[dev] plt add-depl-featsubcommand. - (cli) Added a
[dev] plt set-depl-disabled(or[dev] plt disable-depl) subcommand which modifies a package deployment at the specified deployment name, to disable the deployment. - (cli) Added a
[dev] plt unset-depl(or[dev] plt enable-depl) subcommand which modifies a package deployment at the specified deployment name, to enable the deployment.
- (cli) File permissions are now preserved in the exports of
http-archivesource files extracted from.tar/.tar.gzarchives.
- (spec, cli) Added
source-typeandurlfields to the file export resource, and addedhttpandhttp-archivefile source types; for simplicity/backwards-compatibility, by defaultsource-typeis assumed to belocal(for local files) andurlis ignored.urlis used forhttpandhttp-archivefile source types (see next changelog item). - (cli)
httpandhttp-archivefile sources (for file export resources) are downloaded and cached with[dev] plt cache-dland[dev] plt cache-allsubcommands, and downloaded files (whether downloaded directly from an HTTP(S) URL or extracted from a.tar.gz/.tararchive downloaded from an HTTP(S) URL) are now exported as part of the pallet's bundle when the pallet is staged. The bundle's manifest now lists the URLs of downloaded files/archives.
- (cli) Added checking for validity of source paths of file exports in
[dev] plt checkandstage checksubcommands.
- (cli) The
dev plt add-reposubcommand now has additional aliases with clearer names:require-repoandrequire-repositories. - (cli) Added a
plt add-reposubcommand which is just likedev plt add-repo(including its newrequire-repoandrequire-repositoriesaliases). - (cli) By default, now the
[dev] plt add-reposubcommand will also cache all repos required by the pallet after adding/updating a repo requirement (or multiple repo requirements). This added behavior can be disabled with a new--no-cache-reqflag. - (cli) By default, now the
plt cloneandplt pullsubcommands will also cache all required repos after cloning/pulling the pallet. This added behavior can be disabled with a new--no-cache-reqflag. - (cli) Added a
stage unset-nextsubcommand which will update the stage store so that no staged pallet bundle will be applied next. - (cli) Now the
stage set-nextsubcommand will accept an index of 0, which will update the stage store so that no staged pallet bundle will be applied next. - (cli) Added a
stage set-next-resultsubcommand which can be used on non-Docker systems (whereforklift stage applydoesn't work) to record whether the next staged pallet bundle to be applied has been successfully applied or has failed to be applied (or to reset its state from "failed" to "pending", representing that we don't know whether it has been applied successfully or unsuccessfully). This is intended to be used by systems which need to use the files exported by the next staged pallet bundle but might encounter unrecoverable errors.
- (Breaking change; spec) The file exports specification has changed so that only a single target path (instead of a list of target paths) can be specified per file export object; accordingly, the field has been renamed from
targetstotarget. Additionally, if thesourcepath is left empty, it is interpreted to have the same value as thetargetpath. - (Breaking change; cli) The
--parallelflag for various subcommands has now been consolidated and moved to the top level (e.g.forklift --parallel plt cache-imginstead offorklift plt cache-img --parallel). Additionally, now the flag is enabled by default (because sequential downloading of images and bringup of Docker containers is so much slower than parallel downloading/bringup); to avoid parallel execution, use--parallel=false(e.g.forklift --parallel=false plt cache-img). - (Breaking change; cli)
plt cloneno longer deletes the.gitdirectory after cloning a pallet, because the new pallet staging functionality makes it feasible to keep a long-running local pallet which can change independently of what is actually applied on a computer.
- (cli) Subcommands under
stageno longer require the workspace to be set via--workspaceorFORKLIFT_WORKSPACE(which defaults to$HOME, which may be unset in systemd system services) if the path to the stage store is explicitly set via--stage-storeorFORKLIFT_STAGE_STORE.
- (cli) Added a
--no-cache-imgflag to allplt switch,[dev] plt stage, andstage set-nextto enable non-root execution in setup scripts where the Docker socket can only be accessed with root permissions.
- (cli) Added missing a
--parallelflag toplt stage. - (cli) Fixed incorrect usage descriptions for the
--parallelflag for[dev] plt plan,[dev] plt apply, andstage plan.
- (spec) Added a file export resource type as a resource which packages can provide as part of their deployments and/or feature flags.
- (cli) Added checking of conflicts between file export resources with
plt check/stage check. - (cli) When information about a package is shown (e.g. with
cache show-pkgor[dev] plt show-pkg), the source and target paths of file exports are also shown. - (cli) When information about a package deployment is shown (e.g. with
stage show-bun-deplor[dev] plt show-depl), the target paths of file exports are also shown. - (cli) When information about a staged pallet bundle is shown (e.g. with
stage show-bun), the target paths of file exports are also shown for each package deployment. - (cli) Information about the target paths of file exports for each package deployment in a staged pallet bundle is now recorded in the staged pallet bundle's manifest file, in a new
exportssection. - (cli) Added a
stage locate-bunsubcommand to show the absolute file path of the specified staged pallet bundle. - (cli) Added a global
--stage-storestring flag which, when not empty, overrides the path of the store of staged pallet bundles to an arbitrary path. When the string is empty (the default behavior), the CLI uses the sstore in the workspace specified by the global--workspaceflag (i.e. path-of-workspace/.local/share/forklift/stages).
- (cli) Added a
[dev] plt stagesubcommand to bundle and stage the pallet as the next one to be applied. - (cli) Added a
stage ls-bunsubcommand to list staged pallet bundles. - (cli) Added a
stage show-bunsubcommand to show info about a staged pallet bundle. - (cli) Added a
stage show-bun-deplsubcommand to show info about package deployment of a staged pallet bundle. - (cli) Added a
stage locate-bun-depl-pkgsubcommand to show the absolute file path of the package for a package deployment of a staged pallet bundle. - (cli) Added a
stage add-bun-namesubcommand to assign a name to a staged pallet bundle. - (cli) Added a
stage ls-bun-namessubcommand to list all assigned names for staged pallet bundles. - (cli) Added a
stage rm-bun-namesubcommand to unassign a name for a staged pallet bundle. - (cli) Added a
stage cache-imgsubcommand to cache all Docker container images required by the next staged pallet bundle to be applied, and all container images required by the last successfully-applied bundle (if it is different) as a fallback in case the next staged bundle fails to be applied. - (cli) Added
stage checkandstage plansubcommands which provide equivalent functionality as[dev] plt checkand[dev] plt plan, but for the next staged pallet bundle to be applied. - (cli) Added a
stage applysubcommand which tries to apply the next staged pallet bundle and then, if that bundle could not be successfully applied, falls back to applying the last successfully-applied bundle in subsequent invocations. - (cli) Added a
stage set-nextsubcommand which changes which staged pallet bundle will be applied next (and resetsstage apply's tracking of whether the next staged pallet bundle to be applied has encountered a failure in the past) - (cli) Added a
stage showsubcommand which shows a summary of the staged pallets and what will happen when on the next invocation of thestage applysubcommand. - (cli) Added a
stage show-histsubcommand which lists all staged pallet bundles which have been successfully applied in the past. - (cli) Added a
stage rm-bunsubcommand to delete a staged pallet bundle. - (cli) Added a
stage prune-bunsubcommand to delete all staged pallet bundle not referred to by names or by the history of successfully-applied bundles.
- (cli) The
[dev] plt applyandplt switchsubcommands now automatically bundle and stage the pallet before applying it. - (Breaking change: cli) By default, the
plt switchsubcommand no longer applies the pallet after staging it; instead,stage applymust be run afterwards to apply the staged pallet. The previous behavior (immediate application of the pallet) is now available throughplt switch --apply.
- (cli) Added a
cache add-pltsubcommand to download a pallet to the local cache, given the pallet's path and a version query. If the pallet is already in the local cache, the subcommand will complete successfully even if there is no internet connection. - (cli) Added a
cache show-pltsubcommand to show information about a specified pallet in the local cache. - (cli) Added a
cache ls-pltsubcommand to list all pallets in the local cache. - (cli) Added a
cache rm-pltsubcommand to delete all pallets in the local cache. - (cli) Added a
cache add-reposubcommand to download a repo to the local cache, given the repo's path and a version query. If the pallet is already in the local cache, the subcommand will complete successfully even if there is no internet connection. - (cli) Added a
[dev] plt cache-allsubcommand which just does everything in[dev] plt cache-repoand[dev] plt cache-imgin a single command. - (release) Restored builds of macOS and Windows binaries (warning: these have not been tested to work!).
- (cli) The
plt cloneandplt switchsubcommands now update the local pallet cache, and they initialize the local pallet from the local pallet cache. This way, version queries can still be resolved (for re-cloning or switching pallets) even without internet access, as long as the local pallet cache is up-to-date. - (cli) The
plt cloneandplt switchsubcommands now create local branches tracking all remote branches, and providing a branch name as the version query causes the corresponding local branch to be checked out (instead of checking out the remote branch). This makes it easier to add local commits and push/pull between the local repository and the remote repository when a branch is checked out on the local repository. - (cli) The
[dev] plt add-reposubcommand now updates the local pallet cache, and it runs version queries on the local pallet cache. This way, version queries can still be resolved (for re-cloning or switching pallets) even without internet access, as long as the local pallet cache is up-to-date.
- (Breaking change: cli) Local mirrors of remote Git repos are no longer deleted and re-cloned when Git fetch operations fail on them as part of resolving version queries; such local mirrors will instead need to be manually deleted. This removal of the previous behavior is needed to prevent local mirrors from being deleted when internet access is unavailable.
- (cli) When performing operations on a pallet without any external repo requirements, forklift no longer complains if you haven't cached any repos.
- (spec) Added a "fileset" resource type for files (which can include directories).
- (cli) Added support to for a pallet to deploy packages defined in that same pallet, by referring to the package as an absolute path (rooted at the root of the pallet), if the pallet declares itself as a Forklift repo with the same path.
- (cli) Added a
plt switchsubcommand which is the equivalent of runningplt clone --forceand then runningplt cache-repoand then runningplt apply. This allows a common task (switching the version of a pallet and applying it immediately) to be run with a single command, for a simpler user experience.
- (cli) Added a
[dev] plt locate-depl-pkgsubcommand which prints the absolute filesystem path of the package deployed by the specified deployment (useful for making shell scripts in directories available for use, e.g. in systemd services). - (cli) Added a
cache rm-reposubcommand which only deletes cached repositories. - (cli) Added a
cache rm-imgsubcommand which only deletes unused Docker container images. - (cli) Added a
--include-disabledflag to theplt cache-imganddev plt cache-imgsubcommands to also cache images used by disabled package deployments. - (cli) Added a
--parallelflag to theplt applyanddev plt applysubcommands to enable parallel bringup of Docker Compose apps without any dependency relationships between them. - (cli) Added a
--parallelflag to theplt cache-imganddev plt cache-imgsubcommands to enable parallel caching of Docker container images. Speedup will depend on the host machine, but on a high-performance laptop it led to a ~40% speedup. - (spec) Added a
nonblockingfield to service resource requirement objects in the package specification to allow a resource requirement to be ignored for the purposes of planning the order in which package deployments are to be added or modified.
- (Breaking change: cli) Renamed the
cache rmcommand tocache rm-all - (Breaking change: cli) By default, now the
plt cache-imganddev plt cache-imgcommands don't cache images used only by disabled package deployments. - (Breaking change: cli, workspace) The default value of the
--workspaceflag has changed from$HOME/.forkliftto$HOME. - (Breaking change: workspace) The forklift repository cache has been moved from
(workspace path)/.cacheto(workspace path)/.cache/forklift, so that (with the default workspace location) the forklift repository cache now matches the correct default location according to the XDG Base Directory Specification. For simplicity, the cache has a fixed location with respect to the workspace, instead of being wherever is specified by the$XDG_CACHE_HOMEenvironment variable. - (Breaking change: workspace) The main forklift pallet has been moved from
(workspace path)/.forklift/cacheto(workspace path)/.local/share/forklift/pallet, so that (with the default workspace location) the main forklift pallet cache now matches the correct default location according to the XDG Base Directory Specification. For simplicity, the main pallet has a fixed location with respect to the workspace, instead of being wherever is specified by the$XDG_DATA_HOMEenvironment variable.
- (cli)
plt clonecan now resolve a branch name as the version query, because it now treats the branch name as the name of a remote branch from the "origin" remote (since that is the only source of branches immediately after cloning).
- The
forklift-package.ymlfiles now have an optionalcompose-filesfield in feature flags to define Compose files which should be merged into the Compose app for every package deployment which enables that feature. - The
forklift-pallet.ymlfile can now optionally specify a README file and a pallet path. When specified, those fields are displayed by theplt showanddev plt showcommands. - The
.deploy.ymlfiles now have adisabledboolean flag which specifies whether that deployment definition should be ignored (so that it is excluded fromplt plan,plt check, andplt applycommands). - The
show-pkgsubcommand now shows a list of Compose files associated with each package feature flag. - The
show-deplsubcommand now shows a list of the Compose files used to define the Compose app for the deployment. - The
show-deplsubcommand now shows more details about the Compose app specified by the deployment. - The
forklift-repository.ymlandforklift-pallet.ymlnow have aforklift-versionfield which indicates that the repository/pallet was written assuming the semantics of a given version of Forklift, and which sets the minimum version of Forklift required to use the repository/pallet. The Forklift version of a pallet cannot be less than the Forklift version of any repo required by the pallet. The Forklift tool also checks version compatibility - an older version of the Forklift tool is incompatible with repositories/pallets with newer Forklift versions, and the Forklift tool is also sets the minimum Forklift version of any repository/pallet it is compatible with (so for example v0.4.0 of the Forklift tool is incompatible with any repositories/pallets with Forklift version below v0.4.0, due to other breaking changes made for Forklift v0.4.0).
- (Breaking change: spec) The
definition-filesfield inforklift-package.ymlfiles has been renamed tocompose-files, for unambiguity and future-proofing (so that we can add other definition types, such as for regular files rather than Docker apps). - (Breaking change: spec) The
forklift-version-lock.ymlfile now requires atypefield which specifies whether the version lock is to be interpreted as a tagged version or as a pseudoversion. Thecommitandtimestampfields are now required for all types, instead of being used to determine whether the version lock is for a tagged version or a pseudoversion. - (Breaking change: spec) The
DefinesAppmethod has been removed fromPkgDeplSpec, since now a Compose App may be defined purely by feature flags.
- Now the
dev plt add-repocommand correctly specifies version-locking information when locking a repo at a tagged version.
- Removed builds for Darwin and Windows targets, because v0.3.0 couldn't be released due to the CI workflow running out of disk space.
- Now Git repositories providing Forklift packages can be hosted anywhere with a URL, not just on GitHub.
- (Breaking change: spec) Now only a single Forklift repository is permitted per Git repository, and the root of the Forklift repository must be the root of the Git repository. This means that the path of the Forklift repository is just the path of the Git repository corresponding to that Forklift repository, and thus the repository definition file must be located at the root of the Git repository.
- (Breaking change: spec, cli) Renamed "Forklift pallet"/"pallet" to "Forklift repository"/"repository". All commands now use
repoinstead ofplt. This partially reverts a change made in 0.2.0. - (Breaking change: spec, cli) Renamed "environment"/"env" to "pallet"/"plt". All commands now use
pltinstead ofenv. - (Breaking change: spec) Changed the name of repository definition files from
forklift-pallet.ymltoforklift-repository.yml. This partially reverts a change made in 0.2.0. - (Breaking change: spec) Changed the name of the repository specification section in the repository definition file from
pallettorepository. This reverts a change made in 0.2.0. - (Breaking change: spec) Changed the name of the repository requirements directory in environments from
requirements/palletstorequirements/repositories. This partially reverts a change made in 0.2.0. - (Breaking change: workspace) Changed the name of the repository cache directory in the workspace from
cachetocache/repositories. This partially reverts a change made in 0.2.0. - (Breaking change: workspace) Changed the name of the pallet directory in the workspace from
envtopallet. - (Breaking change: cli) Renamed the
deplsubcommand tohost. - (Breaking change: cli) Renamed the
envsubcommand toplt, and thedev envsubcommand todev plt.
- Updated the Makefile for the
make releasetarget to provide theGITHUB_TOKENenvironment variable to thegoreleaser-crossDocker container used for that Makefile target.
- Updated the Makefile for the
make releasetarget to also use thegoreleaser-crossDocker image which is used for themake buildtarget.
- Added
depl ls-concommand which either lists the containers for the specified package deployment or (if no package deployment name is specified) lists all containers.
- (Breaking change: spec, cli) Forklift now manages Docker Compose applications instead of Docker Stacks, due to Docker Swarm Mode's lack of support for devices (important for talking to hardware) and privileged containers (very useful for gradually migrating non-containerized applications into containers). Note that this causes the compiled binaries to approximately double in size, from ~20-25 MB (on linux_amd64) to ~50-60 MB, because of all the unnecessary dependencies pulled in by the
github.comdocker/compose/v2package; similarly, the compressed archives for the binaries double in size, from ~8 MB to ~17 MB. Hopefully we can return to more reasonable uncompressed binary sizes in the future. - (Breaking change: spec, cli) Renamed "Pallet repository" to "Forklift pallet"/"pallet". All commands now use
pltinstead ofrepo. - (Breaking change: spec) Changed the name of pallet definition files from
pallet-repository.ymltoforklift-pallet.yml. - (Breaking change: spec) Changed the name of the pallet specification section in the pallet definition file from
repositorytopallet. - (Breaking change: spec) Changed the name of package definition files from
pallet-package.ymltoforklift-package.yml. - (Breaking change: spec) Changed the way the Docker Compose application is specified in the
deploymentsection of a Pallet package definition, from adefinition-filefield for a single string to adefinition-filesfield for a list of strings. - (Breaking change: spec) Changed the name of the pallet requirements directory in environments from
repositoriestorequirements/pallets. - (Breaking change: spec) Changed the name of pallet version lock files in environments from
forklift-repo.ymltoforklift-version-lock.yml. - (Breaking change: workspace) Changed the name of the pallet cache directory in the workspace from
cachetocache/pallets.
- (Breaking change: cli) Removed one-letter abbreviations in all aliases.
env plan,dev env plan,env apply, anddev env applynow return an error (and report the problems) if there are resource conflicts or missing resource dependencies (the same problems which would be reported byenv checkanddev env check).cache show-repo,env show-repo, anddev env show-reponow print the Pallet repository's readme file, hard-wrapped to a max line length of 100 characters.
env plan,dev env plan,env apply, anddev env applynow account for the resource dependency relationships among package deployments when planning the sequence of changes to make to the Docker host, so that a Docker stack which requires a network provided by another Docker stack won't be deployed before that other Docker stack (since such a deployment would fail).- The
dev env add-reposubcommand now makes any directories it needs to make in order to write repository requirement definition files to the appropriate locations. - File path separators should no longer be obviously incorrect on Windows systems (though they may still be incorrect, since Forklift is not tested on Windows).
- Fixed regression from v0.1.8 where the
dev env add-repowould not properly print out the resolved versions of repo version queries.
env checkanddev env checknow checks resource constraints against all provided resources and resource requirements among all package deployments in the environment, and reports any identified resource constraint violations.dev envnow allows specifying one or more directories containing Pallet repositories to replace any corresponding cached repositories, using the--repoflag (which can be specified repeatedly).env plananddev env plannow show the changes which will be made byenv applyanddev env apply, respectively.- The (draft) implementation of the (draft) specification for the Pallets package management system is now available in the
/pkg/palletsdirectory of this repository. Note that the specification and implementation will be changed to simplify terminology, so the API will definitely change. - Pallet package deployment specifications can now be defined in subdirectories under the
deploymentsdirectory of a Forklift environment, instead of having to be defined only in thedeploymentsdirectory.
- A major internal refactoring was done. No breaking changes are expected, but breakage is still possible.
cache ls-imgcan now search for locally-downloaded Docker container images matching a provided repository and tag.cache ls-imgnow shows the first tag of each Docker container image together with the image repository name, if the tag exists
- Previously,
env applyanddev env applywould always explicitly attempt to pull the image needed for each Docker Stack service, leading them to fail with an error if the computer had no internet connection. Now, they will only explicitly attempt to pull the image if it is not found among the locally-downloaded Docker container images.
env cache-imganddev env cache-imgcommands are now provided to download all Docker container images ahead-of-time before applying the specified environment.cache ls-imgandcache show-imgcommands are now provided to show information about the Docker container images available in the Docker environment.cache rmnow also removes all unused Docker container images which had been locally downloaded.
- (Breaking change: cli) Renamed the
env deployanddev env deploycommands toenv applyanddev env apply, respectively. This is meant to make the mental model for forklift slightly more familiar to people who have used Terraform. - (Breaking change: cli) Renamed the
env cacheanddev env cachecommands toenv cache-repoanddev env cache-repo, respectively. This disambiguates the commands for caching Pallets-related data and for caching Docker container images, while allowing them to be run separately (useful on Docker environments where root permissions are required to talk to the Docker daemon).
- When the
env applyanddev env applycommands pull images as part of the process of deploying Docker stacks, they now pull images before creating the stack services with proper image tags, since the Docker API client pulling images without any tags.
- Previously, the
dev env addcommand did not correctly update the local cache's mirrors of remote Git repositories. Now it should (probably) update them correctly.
- A
dev env addsubcommand to add one or more Pallet repositories to the development environment, and/or to update their configured versions in the development environment
- (Breaking change: spec) Renamed the
versionfield offorklift-repo.ymlfiles tobase-version.
- An
env infosubcommand to display info about the local environment as a Git repository - A
dev envcommand with subcommands to display info about a development environment (at a user-set path), with the same subcommand structure as theenvcommand
- Changed the "info" verb in subcommands to "show".
- Standardized abbreviations and expansions of verbs for subcommands (e.g. "d"/"deploy", "ls"/"list", or "s"/"show").
- Standardized abbreviations and expansions of nouns for subcommands (e.g. "d"/"depl"/"deployment"/"deployments" or "r"/"repo"/"repository"/"repositories"). Now the longest alias of a noun-verb subcommand always makes grammatical sense (e.g. "list-repositories" instead of "list-repository", "show-repository" instead of "information-repository"), and the shortest alias of a subcommand always has a one-to-three-letter verb and a one-to-three-letter noun, and the main name of a subcommand is of intermediate length (e.g. "ls-repo", "show-pkg", "show-depl").
- Release channels are no longer tracked for each Pallet repository within a Forklift environment, for simplicity.
- (Breaking change: spec) The
forklift-repo-lock.ymlfile has been renamed toforklift-repo.yml, for simplicity.
- The
depl rmsubcommand now waits until all deleted networks actually disappear before it finishes. This is to help prevent theenv deployanddev env deploysubcommands from being run while the state of the Docker Swarm is still changing as a result of a previousdepl rmsubcommand.
- Set correct file permission flags when making the forklift workspace if it doesn't already exist.
- Handling of stacks which need to be removed as part of the
forklift env deploycommand
- Order of deleting resources (services, networks, secrets, configs) in the
forklift depl rmcommand, so that it does not error out when one of the stacks to be deleted provides a resource (e.g. a network) used by other stacks as an external resource.
- Basic commands for cloning and tracking a Pallet environment from a remote Git repository
- A basic command for downloading (into a local cache of Pallet repositories/packages) all Pallet repositories specified by the local Pallet environment
- A basic command with minimal functionality for deploying the local Pallet environment into the local Docker Swarm; this does not fully implement the Pallet specification (notably, all package features are always enabled)
- Basic commands for displaying information about the local Pallet environment and the local cache
- A basic command for deleting the local Pallet environment
- A basic command for deleting the local cache of Pallet repositories/packages
- A basic command for checking what Docker stacks are running in the local Docker Swarm
- A basic command with minimal functionality for deleting all stacks from the local Docker Swarm; this is not fully correct in deleting resources created by Pallet packages (for example, it can't properly delete a network created by one package which is used as an external network by other packages)