Ansible Privilege Escalation

[root@localhost ansbile_playbook]# ansible-playbook install_docker.yamlPLAY [awsnode] ********************************************************************TASK [Gathering Facts] ********************************************************************
ok: [34.229.157.247]
TASK [Download the docker repo.] ********************************************************************
fatal: [34.229.157.247]: FAILED! => {"changed": false, "checksum_dest": null, "checksum_src": "d7ff809b1df9aaba3a0e3e0c68ed188e3d3ff9d9", "dest": "/etc/yum.repos.d/docker-ce.repo", "elapsed": 0, "msg": "Destination /etc/yum.repos.d is not writable", "src": "/home/ec2-user/.ansible/tmp/ansible-tmp-1649573642.0434856-1978-145705028410837/tmpesi9z8h6", "url": "https://download.docker.com/linux/rhel/docker-ce.repo"}
PLAY RECAP ********************************************************************
34.229.157.247 : ok=1 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0
shows ec2-user.
privilege escalation
- hosts: awsnode
tasks:
- name: Download the docker repo.
get_url:
url: "https://download.docker.com/linux/rhel/docker-ce.repo"
dest: "/etc/yum.repos.d"

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store