From d77a7dfa65578e0712547f2bf51a80facbae0864 Mon Sep 17 00:00:00 2001
From: Duncan <drharris@gitlab.com>
Date: Tue, 15 Oct 2024 22:49:28 +0000
Subject: [PATCH] Adding back in "argument list too long"

---
 doc/ci/variables/index.md | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/doc/ci/variables/index.md b/doc/ci/variables/index.md
index 238a89d21ead..a5d8c6927139 100644
--- a/doc/ci/variables/index.md
+++ b/doc/ci/variables/index.md
@@ -1057,3 +1057,18 @@ WARNING:
 If you add `CI_DEBUG_TRACE` as a local variable to runners, debug logs generate and are visible
 to all users with access to job logs. The permission levels are not checked by the runner,
 so you should only use the variable in GitLab itself.
+
+### "argument list too long"
+
+This issue occurs when the combined length of all CI/CD variables defined for a job exceeds the limit imposed by the
+shell where the job executes. This includes the names and values of pre-defined and user defined variables. This limit
+is typically referred to as `ARG_MAX`, and is shell and operating system dependent. This issue also occurs when the
+content of a single [File-type](#use-file-type-cicd-variables) variable exceeds `ARG_MAX`.
+
+For more information, see [issue 392406](https://gitlab.com/gitlab-org/gitlab/-/issues/392406#note_1414219596).
+
+As a workaround you can either:
+
+- Use [File-type](#use-file-type-cicd-variables) CI/CD variables for large environment variables where possible.
+- If a single large variable is larger than `ARG_MAX`, try using [Secure Files](../secure_files/index.md), or
+  bring the file to the job through some other mechanism.
-- 
GitLab