전체 글222 ansible "basic: the specified credentials were rejected by the server" 문제점 - ansible을 이용하여 windows서버에 명령을 수행하면 아래와 같은 에러가 발생함. x.x.x.x | UNREACHABLE! => { "changed": false, "msg": "basic: the specified credentials were rejected by the server", "unreachable": true } 해결방법 해당 윈도우 서버에 파워쉘로 아래 명령어 수행 Set-Item -Force WSMan:\localhost\Client\Allowunencrypted $True Set-Item -Force WSMan:\localhost\Service\Allowunencrypted $True Set-Item -Force WSMan:\localhost\Service\auth.. 2022. 5. 25. ansible playbook debug passwd 프린트 하기 원하는 호스트의 /etc/passwd에 있는 계정리스트를 출력하고자한다. {{ 변수명.stdout_lines }}의 stdout_lines를 쓰면 결과가 깔끔하게 출력됨 --- - name: print passwd hosts: "{{ varhost }}" tasks: - name: print passwdaa shell: cat /etc/passwd | awk -F ':' '{print $1}' register: print_result - name: debug print debug: msg: "{{ print_result.stdout_lines }}" 수행명령어 ansible-playbook printpasswd.yml -e "varhost=localhost" -k 2022. 5. 24. svn 명령어 프로젝트 불러오기 svn checkout svn으로 파일 업로드하기 add와 commit을 해줘야 다음에 당겨받을때 추가한 파일까지 당겨온다. svn add 파일명 svn commit 파일명 -m "메시지" svn에 수정된 내역을 받아오기 svn update 2022. 5. 24. Using a SSH password instead of a key is not possible because Host Key checking is enabled and sshpass does not support this. Please add this host's fingerprint to your known_hosts file to manage this host. 문제점 젠킨스에서 ansible 명령어 수행시 아래와같은 에러가 발생함, console에서는 잘 수행됨 Using a SSH password instead of a key is not possible because Host Key checking is enabled and sshpass does not support this. Please add this host's fingerprint to your known_hosts file to manage this host. 해결방법 /etc/ansible/ansible.cfg 파일에 아래 내역 추가 후 다시 명령 수행 [defaults] host_key_checking = False 2022. 5. 23. centos7 svn: E205007: Could not use external editor to fetch log message; consider setting the $SVN_EDITOR environment variable or using the --message (-m) or --file (-F) options 에러내역 svn commit 수행 시도시 아래와 같은 에러 발생 # svn commit hihihseo.txt svn: E205007: Commit failed (details follow): svn: E205007: Could not use external editor to fetch log message; consider setting the $SVN_EDITOR environment variable or using the --message (-m) or --file (-F) options svn: E205007: None of the environment variables SVN_EDITOR, VISUAL or EDITOR are set, and no 'editor-cmd' run-time conf.. 2022. 5. 18. ansible "msg": "Missing sudo password" ansible 명령어 수행시 "msg": "Missing sudo password" 에러가 발생한다. PLAY [linux] ************************************************************************************************************************************************************************** TASK [Gathering Facts] **************************************************************************************************************************************.. 2022. 5. 16. 리눅스 linux playbook 예제 /etc/passwd 조회 후 특정 계정 출력 --- - hosts: linux tasks: - name: get value shell: cmd: cat /etc/passwd | grep magnus register: grep_output ignore_errors: yes changed_when: false - name: Print debug: msg: "{{ inventory_hostname }}: '{{ grep_output.stdout }}'" 2022. 5. 16. ansible command "python setup.py egg_info" failed with error code 1 문제점 pip3 install pywinrm 명령어 수행시 아래와 같은 에러코드가 출력됨 command "python setup.py egg_info" failed with error code 1 해결방안 아래 명령어 수행 sudo -H pip3 install --upgrade --ignore-installed pip setuptools 2022. 5. 12. ansible sing a SSH password instead of a key is not possible because Host Key checking is enabled and sshpass does not support this 문제점 리눅스 console에서는 정상 출력되나 jenkins를 통한 ansible 명령 수행시 아래와 같은 에러가 나온다. Using a SSH password instead of a key is not possible because Host Key checking is enabled and sshpass does not support this. Please add this host's fingerprint to your known_hosts file to manage this host. Running as SYSTEM Building in workspace /var/lib/jenkins/workspace/linux_ping [linux_ping] $ sshpass ******** /usr/bin/an.. 2022. 5. 9. 텔레그램 봇(telelgram bot) 채팅방 만들기 텔레그램 1:1채팅용 봇 만들기 검색창에 botfather 검색후 채팅시작 > 만들 봇의 이름을 넣는다. 그런 다음 생성하려는 봇의 ID를 만든다. 생성이 되면 다음과같이 아래와 같은 형태로 API키를 할당해준다. 531234568778:AAG8KCwoYbIxBxxxxxxxxxxx6mqk 잘만들어졌는지 확인하려면 브라우저에 아래 값을 넣어보고 결과가 나오는지 확인해본다. https://api.telegram.org/bot[할당받은토큰값]//getUpdates 블라우저 url창에 아래와 같이 입력 https://api.telegram.org/bot12345867:asdfasdfeereYadsfasdfeerere/getUpdates 결과 [ok":true,"result":{}] 텔레그램 검색창에 자신이 만든.. 2022. 5. 6. 이전 1 ··· 14 15 16 17 18 19 20 ··· 23 다음 반응형