본문 바로가기

728x90

리눅스

SSH 키를 생성하고 배포하여 원격 서버에 SSH 접속하는 방법 SSH 키를 생성하고 배포하여 원격 서버에 SSH 접속하는 방법 1. SSH 키 생성 [server 작업] 로컬 컴퓨터에서 SSH 키 쌍을 생성해야 합니다. 이를 위해 ssh-keygen 명령을 사용합니다. 터미널에서 다음 명령을 실행하여 SSH 키 쌍을 생성합니다 ssh-keygen -t rsa -b 4096 -C "your_email@example.com" 위 명령을 실행하면 키 쌍 생성을 위해 몇 가지 옵션을 설정하라는 메시지가 표시됩니다. 엔터를 눌러 기본값을 사용하거나 필요한 옵션을 설정합니다. ssh-keygen 사용법 더보기 usage: ssh-keygen [-q] [-b bits] [-t dsa | ecdsa | ed25519 | rsa | rsa1] [-N new_passphrase] [.. 더보기
Ansible 설치 및 업그레이드 Ansible 설치 및 업그레이드 테스트 환경 운영체제 버전 정보 $ cat /etc/redhat-release CentOS Linux release 7.9.2009 (Core) Ansible 설치 python 버전 $ python --version Python 2.7.5 앤서블 설치 yum install -y ansible ansible-python3 앤서블 버전 ansible --version $ ansible --version ansible 2.9.27 config file = /etc/ansible/ansible.cfg configured module search path = [u'/root/.ansible/plugins/modules', u'/usr/share/ansible/plugins/mod.. 더보기
CentOS 7에서 python3 업그레이드 CentOS 7에서 python3 업그레이드 테스트 환경 운영체제 버전 $ cat /etc/redhat-release CentOS Linux release 7.9.2009 (Core) python 버전 $ python --version Python 2.7.5 $ python3 --version Python 3.6.8 SCL 유틸리티 설치 yum install -y centos-release-scl python 업그레이드 python3.8 설치 yum install -y rh-python38 rh-python38-python-pip python 버전 $ /opt/rh/rh-python38/root/usr/bin/python --version Python 3.8.11 alternatives 확인 altern.. 더보기
[Ansible] inventory(인벤토리) 설정 Ansible inventory 설정 Ansible은 인벤토리로 알려진 목록 또는 목록 그룹을 사용하여 인프라의 여러 관리 노드 또는 "호스트"에 대해 동시에 작동합니다. 인벤토리가 정의되면 패턴을 사용하여 Ansible을 실행할 호스트 또는 그룹을 선택합니다.(대상 서버 리스트) 구성 설정(Configuration settings) - ANSIBLE_CONFIG (환경 변수에 지정한 경우) - ansible.cfg (현재 디렉토리) - ~/.ansible.cfg (홈 디렉토리) - /etc/ansible/ansible.cfg (기본) vim ~/.ansible.cfg cat ~/.ansible.cfg [defaults] inventory = ~/inventory/hosts.ini host_key_che.. 더보기
Ubuntu Server 22.04 LTS (Jammy Jellyfish) Ubuntu Server 22.04 LTS (Jammy Jellyfish) LTS Releases old releases - old-releases.ubuntu.com Ubuntu 22.04.1 LTS (Jammy Jellyfish) Ubuntu 20.04.4 LTS (Focal Fossa) Ubuntu 18.04.6 LTS (Bionic Beaver) Ubuntu Server 22.04 LTS (Jammy Jellyfish) Ubuntu Server 22.04 LTS (Jammy Jellyfish) Daily Build https://cdimage.ubuntu.com/ubuntu-server/daily-live/current/ Ubuntu 22.04 LTS (Jammy Jellyfish) Beta ht.. 더보기
[리눅스] macOS에 ansible 설치 macOS에 ansible 설치 테스트 환경 system_profiler SPSoftwareDataType | egrep 'System Version' $ system_profiler SPSoftwareDataType | egrep 'System Version' System Version: macOS 12.5 (21G72) ansible 설치(brew install) ansible search brew search ansible $ brew search ansible ==> Formulae ansible ansible-cmdb ansible-language-server ansible-lint ansible@2.8 ansible@2.9 ==> Casks ansible-dk ansible informatio.. 더보기
macOS 버전 정보 확인(command) macOS 버전 정보 확인(command) macOS 버전 확인 $ sw_vers -h Usage: sw_vers [-productName|-productVersion|-buildVersion] sw_vers $ sw_vers ProductName:macOS ProductVersion:12.5 BuildVersion:21G72 system_profiler 명령 $ system_profiler -h Usage: system_profiler [-listDataTypes] system_profiler [-xml | -json] [-timeout n] [-detailLevel n] system_profiler [-xml | -json] [-timeout n] [dataType1 ... dataTypeN] -de.. 더보기
GitLab에서 리포지토리 미러링을 구성하는 방법(gitlab -> github 미러링) GitLab에서 리포지토리 미러링을 구성하는 방법(gitlab -> github 미러링) github 리포지토리 생성 및 tokens 생성 repository 생성 repository name : gitlab_mirror tokens 생성 Settings > Developer settings > Personal access tokens gitlab 프로젝트 생성 및 미러링 설정 프로젝트 생성 프로젝트 그룹 : testG 프로젝트 이름 : gitlab_source 미러링 설정 testG > gitlab_source > 저장소 설정 Git 저장소 URL : https://아이디@github.com/아이디/gitlab_morror.git 미러 방향 : Push 인증 방법 : 패스워드 패스워드 : 2691109.. 더보기

728x90