|
| 1 | +# DockerSlim |
| 2 | + |
| 3 | +## Introduction |
| 4 | +The **DockerSlim** plugin by Devtron helps you to optimize your container deployments by reducing Docker image size. Now with these lighter Docker images, you can perform faster deployments and enhance overall system efficiency. |
| 5 | + |
| 6 | +{% hint style="warning" %} |
| 7 | +Support for Docker buildx images will be added soon. |
| 8 | +{% endhint %} |
| 9 | + |
| 10 | +### Prerequisites |
| 11 | +No prerequisites are required for integrating the **DockerSlim** plugin. |
| 12 | + |
| 13 | +--- |
| 14 | + |
| 15 | +## Steps |
| 16 | +1. Go to **Applications** → **Devtron Apps**. |
| 17 | +2. Click your application. |
| 18 | +3. Go to **App Configuration** → **Workflow Editor**. |
| 19 | +4. Click **New Workflow** and navigate to the **Build and Deploy from Source Code**. |
| 20 | +5. Fill the required fields in the **Create build pipeline** window and navigate to the **Post-build stage**. |
| 21 | + |
| 22 | +{% hint style="warning" %} |
| 23 | +If you have already configured workflow, edit the build pipeline, and navigate to **Post-build stage**. |
| 24 | +{% endhint %} |
| 25 | + |
| 26 | +6. Under 'TASKS', click the **+ Add task** button. |
| 27 | +7. Click the **DockerSlim** plugin. |
| 28 | +8. Enter the following [user inputs](#user-inputs) with appropriate values. |
| 29 | +--- |
| 30 | + |
| 31 | +## User Inputs |
| 32 | + |
| 33 | +### Task Name |
| 34 | +Enter the name of your task |
| 35 | + |
| 36 | +e.g., `Reduce Docker image size` |
| 37 | + |
| 38 | +### Description |
| 39 | +Add a brief explanation of the task and the reason for choosing the plugin. Include information for someone else to understand the purpose of the task. |
| 40 | + |
| 41 | +e.g., `The DockerSlim plugin is integrated for reducing the size of Docker image.` |
| 42 | + |
| 43 | +### Input Variables |
| 44 | + |
| 45 | +{% hint style="warning" %} |
| 46 | +At `IncludePathFile` input variable list down the file path of essential files from your Dockerfile. Files for which the path is not listed at `IncludePathFile` will may be excluded from the Docker image to reduce size. |
| 47 | +{% endhint %} |
| 48 | + |
| 49 | +| Variable | Format | Description | Sample Value | |
| 50 | +| ------------------------ | ------------ | ----------- | ------------ | |
| 51 | +| HTTPProbe | BOOL | Indicates whether the port is exposed in Dockerfile or not | false | |
| 52 | +| IncludePathFile | STRING | File path of required files | /etc/nginx/include.conf | |
| 53 | + |
| 54 | +### Trigger/Skip Condition |
| 55 | +Here you can set conditions to execute or skip the task. You can select `Set trigger conditions` for the execution of a task or `Set skip conditions` to skip the task. |
| 56 | + |
| 57 | +### Output Variables |
| 58 | +DockerSlim will not be generating an output variable. |
| 59 | + |
| 60 | +Click **Update Pipeline**. |
| 61 | + |
| 62 | + |
| 63 | + |
0 commit comments