SUSE / machinery

A systems management toolkit for Linux
GNU General Public License v3.0
158 stars 32 forks source link

Machinery should not interpret a hostname #2260

Closed gaitjan closed 5 years ago

gaitjan commented 5 years ago

I try to reach a host using LocalForward. This is what happened:

gait@alpaca:~/.machinery> machinery inspect --ssh-port 2222 --name ut3s localhost

Inspecting localhost for os, packages, patterns, repositories, users, groups, services, changed-config-files, changed-managed-files, unmanaged-files...

Note: There are filters being applied during inspection. (Use `--verbose` option to show the filters)

Need to be root to inspect local system.
gait@alpaca:~/.machinery>

Solved this by having this in /etc/hosts: 127.0.0.1 localhost lokaal so I could do machinery inspect --ssh-port 2222 --name ut3s lokaal

thardeck commented 5 years ago

Yes, localhost is used to trigger the non-ssh inspection with root.

If you want to use ssh for local inspection you can use the local ip 127.0.0.1 which should also work for local redirects.

I think it should be ok this way.