# Running Gemini CLI in a Docker container

DevFeed: [Running Gemini CLI in a Docker container](<https://devfeed.tech/articles/running-gemini-cli-in-a-docker-container-27729.md>)

Original publisher: [Read original article](<https://gagor.pro/2025/10/running-gemini-cli-in-a-docker-container/>)

Author: Tom

Published: 2025-10-31T00:00:00Z

Content type: tutorial

Language: en

Sources: [Tomasz Gągor](<https://devfeed.tech/sources/tomasz-gagor.md>)

Topics: [Command-line interface](<https://devfeed.tech/topics/cli.md>), [Docker](<https://devfeed.tech/topics/docker.md>), [Docker Container](<https://devfeed.tech/topics/docker-container.md>), [Node.js](<https://devfeed.tech/topics/node-js.md>), [Bash](<https://devfeed.tech/topics/bash.md>), [Artificial Intelligence](<https://devfeed.tech/topics/ai.md>), [GitHub](<https://devfeed.tech/topics/github.md>)

Tags: [ai](<https://devfeed.tech/tags/ai.md>), [bash](<https://devfeed.tech/tags/bash.md>), [cli](<https://devfeed.tech/tags/cli.md>), [developer-tools](<https://devfeed.tech/tags/developer-tools.md>), [docker](<https://devfeed.tech/tags/docker.md>), [docker-container](<https://devfeed.tech/tags/docker-container.md>), [gemini-cli](<https://devfeed.tech/tags/gemini-cli.md>), [github](<https://devfeed.tech/tags/github.md>), [guide](<https://devfeed.tech/tags/guide.md>), [how-to](<https://devfeed.tech/tags/how-to.md>), [linux](<https://devfeed.tech/tags/linux.md>), [macos](<https://devfeed.tech/tags/macos.md>), [node-js](<https://devfeed.tech/tags/node-js.md>), [npm](<https://devfeed.tech/tags/npm.md>), [shell](<https://devfeed.tech/tags/shell.md>), [zsh](<https://devfeed.tech/tags/zsh.md>)

## AI overview

A practical guide to running Google's Gemini CLI in a Docker container instead of installing Node.js and its dependencies directly. It explains the author's custom Docker image, weekly updates, shell integration, configuration persistence, permissions, and interactive usage.

## Source excerpt

Learn how to run Google's Gemini CLI in a Docker container to avoid installing Node.js and its dependencies directly on your system. This guide provides a simple setup, a recommended shell function for seamless integration, and usage examples.