diff --git a/bash_completion/cekit b/bash_completion/cekit
index e1465c3..ec29995 100755
--- a/bash_completion/cekit
+++ b/bash_completion/cekit
@@ -7,6 +7,7 @@ _cekit_global_options()
     options+='--overrides '
     options+='--target '
     options+='--descriptor '
+    options+='--work-dir '
     echo "$options"
 }
 
@@ -53,6 +54,10 @@ _cekit_complete()
 	_filedir -d
 	return
 
+    elif [[ '--work-dir' == $prev ]]; then
+	_filedir -d
+	return
+
     elif [[ 'build generate' =~ .*$prev.* ]]; then
 	local options
 	options+=$(_cekit_global_options)
diff --git a/cekit/cli.py b/cekit/cli.py
index 55f9dd6..922d488 100644
--- a/cekit/cli.py
+++ b/cekit/cli.py
@@ -54,6 +54,11 @@ class Cekit(object):
                             action='store_true',
                             help='Set default options for Red Hat internal infrasructure.')
 
+        parser.add_argument('--work-dir',
+                            dest='work_dir',
+                            help="Location of cekit working directory, it's "
+                            "used to store dist-git repos.")
+
         test_group = parser.add_argument_group('test',
                                                "Arguments valid for the 'test' target")
 
@@ -165,6 +170,8 @@ class Cekit(object):
 
             if self.args.redhat:
                 tools.cfg['common']['redhat'] = True
+            if self.args.work_dir:
+                tools.cfg['common']['work_dir'] = self.args.work_dir
 
             # We need to construct Generator first, because we need overrides
             # merged in
diff --git a/docs/build.rst b/docs/build.rst
index 78d1f6d..1a466e6 100644
--- a/docs/build.rst
+++ b/docs/build.rst
@@ -20,6 +20,7 @@ You can execute an container image build by running:
 
 * ``--tag`` -- an image tag used to build image (can be specified multiple times)
 * ``--redhat`` -- build image using Red Hat defaults. See :ref:`Configuration section for Red Hat specific options<redhat_config>` for additional details.
+* ``--work-dir`` -- sets Cekit works directory where dist_git repositories are cloned into See :ref:`Configuration section for work_dir<workdir_config>`
 * ``--build-engine`` -- a builder engine to use ``osbs``, ``buildah`` or ``docker`` [#f1]_
 * ``--build-pull`` -- ask a builder engine to check and fetch latest base image
 * ``--build-osbs-stage`` -- use ``rhpkg-stage`` tool instead of ``rhpkg``
diff --git a/docs/configuration.rst b/docs/configuration.rst
index dc1a6ca..645cc78 100644
--- a/docs/configuration.rst
+++ b/docs/configuration.rst
@@ -18,12 +18,20 @@ Below you can find description of available sections together with options descr
 ``common``
 ------------
 
+.. _workdir_config:
+
 ``work_dir``
 ^^^^^^^^^^^^
 
 Contains location of Cekit working directory, which is used to store some persistent data like
 dist_git repositories.
 
+.. code:: yaml
+
+    [common]
+    work_dir=/tmp
+
+
 ``ssl_verify``
 ^^^^^^^^^^^^^^
 

Make it possible to specify where dist-git repositories should be cloned
It is important so we do not reuse the same directories when running in parallel.
diff --git a/tests/test_unit_args.py b/tests/test_unit_args.py
index fdb2042..6c5a555 100644
--- a/tests/test_unit_args.py
+++ b/tests/test_unit_args.py
@@ -81,6 +81,15 @@ def test_args_config_default(mocker):
     assert Cekit().parse().args.config == '~/.cekit/config'
 
 
+def test_args_workd_dir(mocker):
+    mocker.patch.object(sys, 'argv', ['cekit',
+                                      'generate',
+                                      '--work-dir',
+                                      'foo'])
+
+    assert Cekit().parse().args.work_dir == 'foo'
+
+
 def test_args_config(mocker):
     mocker.patch.object(sys, 'argv', ['cekit',
                                       '--config',

pip install -e .
parse_log_pytest
requirements.txt
behave docker lxml mock pytest pytest-cov pytest-mock pykwalify
apt-get update apt-get install -y gcc
3.9
requirements.txt
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
behave==1.2.6
-e git+https://github.com/cekit/cekit.git@7067fb770515c44b28d661fddb5d0f25f706baf3#egg=cekit
certifi==2025.1.31
charset-normalizer==3.4.1
colorlog==6.9.0
coverage==7.8.0
docker==7.1.0
docopt==0.6.2
exceptiongroup==1.2.2
idna==3.10
iniconfig==2.1.0
Jinja2==3.1.6
lxml==5.3.1
MarkupSafe==3.0.2
mock==5.2.0
packaging==24.2
parse==1.20.2
parse_type==0.6.4
pluggy==1.5.0
pykwalify==1.8.0
pytest==8.3.5
pytest-cov==6.0.0
pytest-mock==3.14.0
python-dateutil==2.9.0.post0
PyYAML==6.0.2
requests==2.32.3
ruamel.yaml==0.18.10
ruamel.yaml.clib==0.2.12
six==1.17.0
tomli==2.2.1
urllib3==2.3.0

name: cekit
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - ca-certificates=2025.2.25=h06a4308_0
  - ld_impl_linux-64=2.40=h12ee557_0
  - libffi=3.4.4=h6a678d5_1
  - libgcc-ng=11.2.0=h1234567_1
  - libgomp=11.2.0=h1234567_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - ncurses=6.4=h6a678d5_0
  - openssl=3.0.16=h5eee18b_0
  - pip=25.0=py39h06a4308_0
  - python=3.9.21=he870216_1
  - readline=8.2=h5eee18b_0
  - setuptools=75.8.0=py39h06a4308_0
  - sqlite=3.45.3=h5eee18b_0
  - tk=8.6.14=h39e8969_0
  - tzdata=2025a=h04d1e81_0
  - wheel=0.45.1=py39h06a4308_0
  - xz=5.6.4=h5eee18b_1
  - zlib=1.2.13=h5eee18b_1
  - pip:
      - behave==1.2.6
      - certifi==2025.1.31
      - charset-normalizer==3.4.1
      - colorlog==6.9.0
      - coverage==7.8.0
      - docker==7.1.0
      - docopt==0.6.2
      - exceptiongroup==1.2.2
      - idna==3.10
      - iniconfig==2.1.0
      - jinja2==3.1.6
      - lxml==5.3.1
      - markupsafe==3.0.2
      - mock==5.2.0
      - packaging==24.2
      - parse==1.20.2
      - parse-type==0.6.4
      - pluggy==1.5.0
      - pykwalify==1.8.0
      - pytest==8.3.5
      - pytest-cov==6.0.0
      - pytest-mock==3.14.0
      - python-dateutil==2.9.0.post0
      - pyyaml==6.0.2
      - requests==2.32.3
      - ruamel-yaml==0.18.10
      - ruamel-yaml-clib==0.2.12
      - six==1.17.0
      - tomli==2.2.1
      - urllib3==2.3.0
prefix: /opt/conda/envs/cekit

tests/test_unit_args.py::test_args_workd_dir
tests/test_unit_args.py::test_args_command[generate] tests/test_unit_args.py::test_args_command[build] tests/test_unit_args.py::test_args_command[test] tests/test_unit_args.py::test_args_not_valid_command tests/test_unit_args.py::test_args_tags[tags0-build_tags0-expected0] tests/test_unit_args.py::test_args_tags[tags1-build_tags1-expected1] tests/test_unit_args.py::test_args_tags[tags2-build_tags2-expected2] tests/test_unit_args.py::test_args_tags[tags3-build_tags3-expected3] tests/test_unit_args.py::test_args_build_pull tests/test_unit_args.py::test_args_build_engine[osbs] tests/test_unit_args.py::test_args_build_engine[docker] tests/test_unit_args.py::test_args_build_engine[buildah] tests/test_unit_args.py::test_args_osbs_stage tests/test_unit_args.py::test_args_osbs_stage_false tests/test_unit_args.py::test_args_invalid_build_engine tests/test_unit_args.py::test_args_osbs_user tests/test_unit_args.py::test_args_config_default tests/test_unit_args.py::test_args_config tests/test_unit_args.py::test_args_target tests/test_unit_args.py::test_args_redhat tests/test_unit_args.py::test_args_redhat_default tests/test_unit_args.py::test_args_osbs_nowait tests/test_unit_args.py::test_args_osbs_no_nowait
cekit/cli.py docs/build.rst bash_completion/cekit docs/configuration.rst
cekit/cli.py docs/build.rst bash_completion/cekit docs/configuration.rst