上QQ阅读APP看书,第一时间看更新
Getting ready
As with the previous section, confirm that both of your Vagrant boxes are enabled, and connect to the first using the vagrant command:
$ vagrant ssh centos1
To configure different options for our user, we're going to create an SSH configuration file in our home directory.
This goes in the same place as most of our SSH files, ~/.ssh/.
Whenever you see a ~ character, think of it as my home in your head. Expanded, this location is /home/vagrant/.ssh/.
Create the file, lock down the permissions, and open it in your editor of choice—I'm going to use vi.
Be sure to call it config:
[vagrant@centos1 ~]$ touch ~/.ssh/config
[vagrant@centos1 ~]$ chmod 600 ~/.ssh/config
[vagrant@centos1 ~]$ vi ~/.ssh/config