Traceback (most recent call last): File "test.py", line 11, in <module> import requests ImportError: No module named requests
https://pypi.org/project/requests/
https://stackoverflow.com/questions/18363022/importerror-no-module-named-pip
Security Researcher, DevOps, SRE
Traceback (most recent call last): File "test.py", line 11, in <module> import requests ImportError: No module named requests
https://pypi.org/project/requests/
https://stackoverflow.com/questions/18363022/importerror-no-module-named-pip
$ fdisk -l $ growpart /dev/xvda $ growpart /dev/xvda 1 $ lsblk $ xfs_growfs -d / $ df -h
Scrot is a quite popular command line tool and one of the swiss army tools sysadmin need to have. When I’m not be able to install it via the repository, this is what I did to make it work :
$ wget http://mirror.ghettoforge.org/distributions/gf/el/7/gf/x86_64/giblib-1.2.4-27.gf.el7.x86_64.rpm $ wget http://packages.psychotic.ninja/7/base/x86_64/RPMS/scrot-0.8-12.el7.psychotic.x86_64.rpm $ sudo rpm -i giblib-1.2.4-27.gf.el7.x86_64.rpm $ sudo rpm -i scrot-0.8-12.el7.psychotic.x86_64.rpm
aws s3 ls --summarize --human-readable --recursive s3://bucket_name/go/to/path | grep 'Total'
Change bucket_name and go/to/path to yours
Check the remote file whether it exists
ssh -q ubuntu@10.10.10.10 [[ -f /etc/nginx/conf.d/test.conf ]] && echo "true" || echo "false"
aws codebuild create-webhook --project-name --filter-groups "[[{\"type\":\"EVENT\",\"pattern\":\"PULL_REQUEST_MERGED\"}]]"
Scan network :
nmap -sP 172.16.0.56/24
Install redshift with dnf or yum:
sudo dnf install redshift
Apply screen reduction
redshift -O 2500
Reset the setting
redshift -x
This is one of the coolest trick I’ve ever seen when working with VIM. This plugin allows you to run the bash terminal inside the VIM. And you can actually make it a spitted pane within your VIM work space.
Check out this plugin:
Open vim config:
vim ~/.vimrc
call plug#begin('~/.vim/plugged') Plug 'lrvick/Conque-Shell' call plug#end()
Close the ~/.vimrc file, and open vim again, and Install the plugin with this syntax:
:PlugInstall
export AWS_PROFILE=profile_name