avatar
Articles
4
Tags
6
Categories
3

Home
Archives
Tags
Categories
Lee Blog
Home
Archives
Tags
Categories

Lee Blog

配置 SSH 公钥和私钥
Created2024-02-19|Linux
生成 SSH 密钥对: 在终端中输入以下命令生成 SSH 密钥对: 1ssh-keygen -t rsa -b 4096 -C "your_email@example.com" 这会在默认目录 ~/.ssh/ 下生成一个公钥文件 id_rsa.pub 和一个私钥文件 id_rsa。 将公钥添加到目标服务器: 将生成的公钥文件中的内容添加到目标服务器上的 ~/.ssh/authorized_keys 文件中。你可以使用 ssh-copy-id 命令来简化此过程: 1ssh-copy-id username@remote_host 这将把你的公钥添加到远程主机上指定用户的 authorized_keys 文件中。 设置私钥权限: 在本地机器上设置私钥文件的权限,确保只有你可以读取: 1chmod 600 ~/.ssh/id_rsa 测试连接: 使用 SSH 命令测试连接到目标服务器,确保已成功配置: 1ssh username@remote_host
Mac 配置 VS Code 环境变量
Created2024-02-01|Mac
打开 VS Code 按下⌘ + ⇧ + P 输入> path 选择Shell 命令:在 PATH 中安装“code”命令 或 Shell Command: Install 'code' command in PATH
非root用户使用Docker
Created2023-02-12|Docker
1234567891011[root@localhost ~]# groupadd docker[root@localhost ~]# groupsroot[root@localhost ~]# usermod -a -G docker lee[root@localhost ~]# grep docker /etc/groupdockerroot:x:994:docker:x:1001:lee[root@localhost ~]# service docker restartRedirecting to /bin/systemctl restart docker.service[root@localhost ~]# su lee[lee@localhost ~]$ docker images
Docker in WSL2 failed to start daemon: Error initializing network controller
Created2023-02-12|Docker
问题12345678910111213$ docker imagesCannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?$ sudo service docker startStarting Docker: docker.$ sudo service docker statusDocker is not running ... failed!$ sudo dockerd......failed to start daemon: Error initializing network controller: error obtaining controller instance: failed to create NAT chain DOCKER: iptables failed: iptables --wait -t nat -N DOCKER: iptables v1.8.4 (nf_tables): CHAIN_ADD failed (No s ...
1
avatar
Lee
Articles
4
Tags
6
Categories
3
Follow Me
Recent Post
配置 SSH 公钥和私钥2024-02-19
Mac 配置 VS Code 环境变量2024-02-01
非root用户使用Docker2023-02-12
Docker in WSL2 failed to start daemon: Error initializing network controller2023-02-12
Categories
  • Docker2
  • Linux1
  • Mac1
Tags
SSH VS Code Linux Docker Mac WSL2
Archives
  • 2024年02月2
  • 2023年02月2
Info
Article :
4
UV :
PV :
Last Update :
©2023 - 2024 By Lee