Skip to content

Commit

Permalink
Merge pull request #340 from foundriesio/fix-app-removing
Browse files Browse the repository at this point in the history
appengine: Remove app only from runtime part
  • Loading branch information
mike-sul authored Jul 16, 2024
2 parents 64a64f1 + ecbd4fe commit e25e901
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/composeapp/appengine.cc
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,12 @@ AppEngine::Result AppEngine::fetch(const App& app) {

void AppEngine::remove(const App& app) {
try {
// Remove app from the store. Skip blob pruning because unused blobs will be pruned in the `prune` call
// after all non-target apps are removed.
exec(boost::format{"%s --store %s --compose %s rm %s --prune=false --quiet"} % composectl_cmd_ % storeRoot() %
installRoot() % app.name,
"failed to remove app");
// Make sure app is stopped before trying to uninstall it
// "App removal" in this context refers to deleting app images from the Docker store
// and removing the app compose project (app uninstall).
// Unused app blobs will be removed from the blob store via the prune() method,
// provided they are not utilized by any other app(s).
// Note: Ensure the app is stopped before attempting to uninstall it.

exec(boost::format{"%s --store %s --compose %s stop %s"} % composectl_cmd_ % storeRoot() % installRoot() % app.name,
"failed to stop app");
// Uninstall app, it only removes the app compose/project directory, docker store pruning is in the `prune` call
Expand Down

0 comments on commit e25e901

Please sign in to comment.