first commits

This commit is contained in:
David Young
2026-05-14 14:06:21 -06:00
parent d67dc1ad11
commit 015b3a8c5d
299 changed files with 87414 additions and 0 deletions

View File

@@ -0,0 +1,27 @@
---
layout: post
title: "如何使用非root用户执行docker命令"
subtitle: ""
description: "如何使用非root用户执行docker命令"
excerpt: "如何使用非root用户执行docker命令"
date: 2018-02-09 10:00:00
author: "赵化冰"
image: "/img/docker.jpg"
publishDate: 2018-02-09 10:00:00
showtoc: false
tags:
- Tips
- Docker
URL: "/2018/02/09/docker-without-sudo/"
categories: [ Tips ]
---
### Add the docker group if it doesn't already exist:
sudo groupadd docker
### Add the connected user "$USER" to the docker group. Change the user name to match your preferred user if you do not want to use your current user:
sudo gpasswd -a $USER docker
### Either do a newgrp docker or log out/in to activate the changes to groups.