Configure Linux machine with custom SSH client configuration

From AcrodusWiki
Revision as of 15:40, 10 July 2024 by Alex (talk | contribs) (→‎EXAMPLE)

Introduction

This guide explains how to create custom static configuration for SSH client on a Linux machine. Instead of using command line options from the terminal a custom configuration file can be created.

HOW TO

The file /etc/ssh/ssh_config contains commented out options for an SSH client. These can be used as an example for a custom ssh config. Go into the subdirectory /etc/ssh/ssh_config.d/ and create a new file. In this file specify the ip address/hostnames for this configuration to apply to. Under this include all configuration options.

EXAMPLE

/etc/ssh/ssh_config.d/example.conf

Host *.solinno.co.uk

IdentityFile ~/.ssh/pinky_solinno
Port 2251