{"id":6759,"date":"2019-01-25T23:36:38","date_gmt":"2019-01-26T04:36:38","guid":{"rendered":"https:\/\/www.jitendrazaa.com\/blog\/?p=6759"},"modified":"2019-03-21T17:30:28","modified_gmt":"2019-03-21T21:30:28","slug":"docker-cheat-sheet","status":"publish","type":"post","link":"https:\/\/www.jitendrazaa.com\/blog\/salesforce\/docker-cheat-sheet\/","title":{"rendered":"Docker Cheat sheet"},"content":{"rendered":"\n<p>Refer <a href=\"https:\/\/www.docker.com\/sites\/default\/files\/Docker_CheatSheet_08.09.2016_0.pdf\">this url to get official cheat sheet<\/a> for docker commands. Below are some of frequently used commands by me<\/p>\n\n\n\n<p><strong>Find all docker images installed on system<\/strong><\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\ndocker images\n<\/pre><\/div>\n\n\n<p><strong>Find container id of currently running dockers<\/strong><\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\ndocker ps\n<\/pre><\/div>\n\n\n<p><strong>Stop or kill running container<\/strong><\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\ndocker kill &lt;container id from above command&gt;\n<\/pre><\/div>\n\n\n<!--more-->\n\n\n\n<p><strong>Install new image in Docker<\/strong><\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\ndocker pull &lt;image name&gt;\n<\/pre><\/div>\n\n\n<p><strong>Remove Docker Images<\/strong><\/p>\n\n\n\n<p>First run below command to see Image names and Image Id<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\ndocker images\n<\/pre><\/div>\n\n\n<p>get docker image Id from above command and then run below command to delete image<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\ndocker image rm &amp;lt;image Id&gt; \nor\ndocker image rm &amp;lt;image id&gt; -f\n<\/pre><\/div>\n\n\n<h2 class=\"wp-block-heading\">Remove unused Volumes<\/h2>\n\n\n\n<p>If you have huge space used by Docker, it may be because so many zombie volumes, run below command to remove unused volumes<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\ndocker volume prune\n<\/pre><\/div>\n\n\n<h2 class=\"wp-block-heading\">Jenkins docker commands<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/jenkinsci\/docker\/blob\/master\/README.md\">This<\/a> is the official jenkins image for docker. To install docker, as per <a href=\"https:\/\/hub.docker.com\/r\/jenkins\/jenkins\">this<\/a> website, run below command<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\ndocker pull jenkins\/jenkins:lts\n\n# then below command to run Jenkins image in docker\n\ndocker run -p 8080:8080 -p 50000:50000 jenkins\/jenkins:lts\n\n#Above image will run jenkins on http:\/\/localhost:8080\n<\/pre><\/div>\n\n\n<h2 class=\"wp-block-heading\">Pgadmin docker commands<\/h2>\n\n\n\n<p><a href=\"https:\/\/hub.docker.com\/r\/dpage\/pgadmin4\/\">Pgadmin<\/a> is widely <strong>postgresql<\/strong> client<\/p>\n\n\n\n<p><strong>Install PostgreSQL<\/strong><\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\ndocker pull dpage\/pgadmin4\n<\/pre><\/div>\n\n\n<p><strong>Start PostgreSQL with default username and password<\/strong><\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\ndocker run -p 80:80 \\\n        -e &quot;PGADMIN_DEFAULT_EMAIL=user@domain.com&quot; \\\n        -e &quot;PGADMIN_DEFAULT_PASSWORD=SuperSecret&quot; \\\n        -d dpage\/pgadmin4\n<\/pre><\/div>\n\n\n<h2 class=\"wp-block-heading\">Phpmyadmin docker commands<\/h2>\n\n\n\n<p><a href=\"https:\/\/hub.docker.com\/r\/phpmyadmin\/phpmyadmin\/\">phpmyadmin<\/a> is popular mySQL client to access local or cloud based MySQL Servers<\/p>\n\n\n\n<p><strong>Install or pull phpmyadmin docker<\/strong><\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\ndocker pull phpmyadmin\/phpmyadmin\n<\/pre><\/div>\n\n\n<p><strong>Run phpmyadmin docker<\/strong><\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\ndocker run --name myadmin -d -e PMA_ARBITRARY=1 -p 8080:80 phpmyadmin\/phpmyadmin PMA_PORT=3203\n<\/pre><\/div>","protected":false},"excerpt":{"rendered":"<p>Frequently used docker commands and cheatsheet<\/p>\n","protected":false},"author":1,"featured_media":6760,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"advanced_seo_description":"","jetpack_seo_html_title":"","jetpack_seo_noindex":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"jz_research_post":"","_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_post_was_ever_published":false},"categories":[9],"tags":[458,439,148,460,459],"class_list":["post-6759","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-salesforce","tag-container","tag-docker","tag-mysql","tag-pgadmin","tag-phpmyadmin"],"jetpack_featured_media_url":"https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2019\/01\/Docker-cheat-sheet.png?fit=1326%2C611&ssl=1","jetpack_sharing_enabled":true,"jetpack-related-posts":[{"id":6429,"url":"https:\/\/www.jitendrazaa.com\/blog\/salesforce\/heroku\/access-heroku-postgresql-database-locally-using-docker\/","url_meta":{"origin":6759,"position":0},"title":"Access Heroku PostgreSQL Database Locally using Docker","author":"Jitendra","date":"March 11, 2018","format":false,"excerpt":"How to use Heroku Postgres Database from any third party application or local server","rel":"","context":"In &quot;Heroku&quot;","block_context":{"text":"Heroku","link":"https:\/\/www.jitendrazaa.com\/blog\/category\/salesforce\/heroku\/"},"img":{"alt_text":"Heroku Postgres from local PHP Server","src":"https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2018\/03\/Heroku-Postgres-from-local-PHP-Server.gif?fit=594%2C674&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2018\/03\/Heroku-Postgres-from-local-PHP-Server.gif?fit=594%2C674&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2018\/03\/Heroku-Postgres-from-local-PHP-Server.gif?fit=594%2C674&ssl=1&resize=525%2C300 1.5x"},"classes":[]},{"id":31368,"url":"https:\/\/www.jitendrazaa.com\/blog\/others\/tips\/openclaw-troubleshooting-guide-7-common-errors-and-how-to\/","url_meta":{"origin":6759,"position":1},"title":"OpenClaw Troubleshooting Guide: 7 Common Errors and How to Fix Them | February 2026","author":"Jitendra Zaa","date":"February 3, 2026","format":false,"excerpt":"Fix OpenClaw errors fast: Brave API rate limits, SearXNG Docker issues, LLM command hallucinations, and agent workflow issues with step-by-step solutions.","rel":"","context":"In &quot;AI&quot;","block_context":{"text":"AI","link":"https:\/\/www.jitendrazaa.com\/blog\/category\/ai\/"},"img":{"alt_text":"OpenClaw Troubleshooting Guide - 7 Common Errors and How to Fix Them - Featured Image","src":"https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/02\/OpenClaw-Troubleshooting-Guide-featured.png?fit=1200%2C675&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/02\/OpenClaw-Troubleshooting-Guide-featured.png?fit=1200%2C675&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/02\/OpenClaw-Troubleshooting-Guide-featured.png?fit=1200%2C675&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/02\/OpenClaw-Troubleshooting-Guide-featured.png?fit=1200%2C675&ssl=1&resize=700%2C400 2x, https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/02\/OpenClaw-Troubleshooting-Guide-featured.png?fit=1200%2C675&ssl=1&resize=1050%2C600 3x"},"classes":[]},{"id":31254,"url":"https:\/\/www.jitendrazaa.com\/blog\/ai\/clawdbot-complete-guide-open-source-ai-assistant-2026\/","url_meta":{"origin":6759,"position":2},"title":"OpenClaw (Formerly Moltbot\/ClawdBot): Your AI Assistant, the Lobster Way","author":"Jitendra Zaa","date":"January 26, 2026","format":false,"excerpt":"Master ClawdBot: the open-source self-hosted AI assistant. Covers installation, WhatsApp setup, API costs, local LLMs via Ollama, Lobster workflows, and security.","rel":"","context":"In &quot;AI&quot;","block_context":{"text":"AI","link":"https:\/\/www.jitendrazaa.com\/blog\/category\/ai\/"},"img":{"alt_text":"ClawdBot Complete Guide 2026: Open-Source AI Assistant - Featured Image","src":"https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/01\/ClawdBot-Complete-Guide-featured.png?fit=1200%2C675&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/01\/ClawdBot-Complete-Guide-featured.png?fit=1200%2C675&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/01\/ClawdBot-Complete-Guide-featured.png?fit=1200%2C675&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/01\/ClawdBot-Complete-Guide-featured.png?fit=1200%2C675&ssl=1&resize=700%2C400 2x, https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/01\/ClawdBot-Complete-Guide-featured.png?fit=1200%2C675&ssl=1&resize=1050%2C600 3x"},"classes":[]},{"id":31396,"url":"https:\/\/www.jitendrazaa.com\/blog\/others\/tips\/openclaw-auto-recovery-config-fix-guide-2026\/","url_meta":{"origin":6759,"position":3},"title":"OpenClaw Auto-Recovery &amp; Config Fix Guide | 2026","author":"Jitendra Zaa","date":"February 4, 2026","format":false,"excerpt":"Master OpenClaw auto-recovery with this comprehensive guide covering config corruption fixes, backup restoration cascade, gateway health monitoring with 5 health checks, and intelligent error auto-remediation for 24\/7 AI assistant uptime.","rel":"","context":"In &quot;AI&quot;","block_context":{"text":"AI","link":"https:\/\/www.jitendrazaa.com\/blog\/category\/ai\/"},"img":{"alt_text":"OpenClaw Auto-Recovery & Config Fix Guide - Featured Image","src":"https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/02\/OpenClaw-Auto-Recovery-Reliability-Guide-featured.png?fit=1200%2C675&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/02\/OpenClaw-Auto-Recovery-Reliability-Guide-featured.png?fit=1200%2C675&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/02\/OpenClaw-Auto-Recovery-Reliability-Guide-featured.png?fit=1200%2C675&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/02\/OpenClaw-Auto-Recovery-Reliability-Guide-featured.png?fit=1200%2C675&ssl=1&resize=700%2C400 2x, https:\/\/i0.wp.com\/www.jitendrazaa.com\/blog\/wp-content\/uploads\/2026\/02\/OpenClaw-Auto-Recovery-Reliability-Guide-featured.png?fit=1200%2C675&ssl=1&resize=1050%2C600 3x"},"classes":[]},{"id":1467,"url":"https:\/\/www.jitendrazaa.com\/blog\/java\/servlet\/difference-between-servletcontext-and-servletconfig\/","url_meta":{"origin":6759,"position":4},"title":"Difference between servletContext and ServletConfig","author":"Jitendra","date":"February 8, 2011","format":false,"excerpt":"What is difference between servletContext and ServletConfig?","rel":"","context":"In &quot;Servlet&quot;","block_context":{"text":"Servlet","link":"https:\/\/www.jitendrazaa.com\/blog\/category\/java\/servlet\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":5274,"url":"https:\/\/www.jitendrazaa.com\/blog\/others\/tips\/frequently-used-git-commands\/","url_meta":{"origin":6759,"position":5},"title":"Frequently Used Git Commands","author":"Jitendra","date":"August 22, 2018","format":false,"excerpt":"Most frequently used Git commands by developers","rel":"","context":"In &quot;Tech Tips&quot;","block_context":{"text":"Tech Tips","link":"https:\/\/www.jitendrazaa.com\/blog\/category\/others\/tips\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/www.jitendrazaa.com\/blog\/wp-json\/wp\/v2\/posts\/6759","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.jitendrazaa.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.jitendrazaa.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.jitendrazaa.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.jitendrazaa.com\/blog\/wp-json\/wp\/v2\/comments?post=6759"}],"version-history":[{"count":6,"href":"https:\/\/www.jitendrazaa.com\/blog\/wp-json\/wp\/v2\/posts\/6759\/revisions"}],"predecessor-version":[{"id":6828,"href":"https:\/\/www.jitendrazaa.com\/blog\/wp-json\/wp\/v2\/posts\/6759\/revisions\/6828"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.jitendrazaa.com\/blog\/wp-json\/wp\/v2\/media\/6760"}],"wp:attachment":[{"href":"https:\/\/www.jitendrazaa.com\/blog\/wp-json\/wp\/v2\/media?parent=6759"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.jitendrazaa.com\/blog\/wp-json\/wp\/v2\/categories?post=6759"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.jitendrazaa.com\/blog\/wp-json\/wp\/v2\/tags?post=6759"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}