From b424ba0defc2c68f6333f99449d922c585301349 Mon Sep 17 00:00:00 2001 From: bjarneo Date: Sat, 30 Nov 2024 10:42:07 +0100 Subject: [PATCH] docs: add the cleanup to the flow --- FLOW.md | 3 ++- README.md | 4 +++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/FLOW.md b/FLOW.md index 10fa245..9217325 100644 --- a/FLOW.md +++ b/FLOW.md @@ -27,7 +27,8 @@ flowchart TD RemoveContainer --> StartContainer[Start New Container] StartContainer --> VerifyContainer{Verify Container Status} - VerifyContainer --> |"Up"| Success([Deployment Success]) + VerifyContainer --> |"Up"| CleanupImages[Cleanup Old Images] + CleanupImages --> |"Keep Latest 5"| Success([Deployment Success]) VerifyContainer --> |"Down"| Failure([Deployment Failure]) end diff --git a/README.md b/README.md index 2e32ea2..1a6273a 100644 --- a/README.md +++ b/README.md @@ -11,6 +11,7 @@ https://github.com/user-attachments/assets/68111156-4445-43c1-9d63-071b2680abc3 - Docker installed locally and on the remote host - SSH access to the remote host - SSH key-based authentication +- Go 1.21 or higher (due to usage of slices.Reverse) ## Installation @@ -52,7 +53,7 @@ Alternatively, you can build from source: Requirements: -- Go 1.x or higher +- Go 1.21 or higher ```bash git clone @@ -268,6 +269,7 @@ When using Pipe as a GitHub Action, the following inputs are available: 6. Stops and removes existing container 7. Starts new container with specified configuration 8. Verifies container is running properly +9. Automatically cleans up old releases (keeps only the latest 5 images) Flow chart: FLOW.md