Use Python to:
- send a plain text email
- send an email with attachment
- receive and filter emails according to some criteria
| # python3 | |
| # apt install python-pip | |
| # apt install python3-evdev | |
| # pip install evdev | |
| # | |
| # list devices | |
| # ls /dev/input/ | |
| # | |
| # https://diyprojects.io/python-library-evdev-raspberry-pi-use-gamepad-diy-projects-servomotor-games/#.Xa8ZR-gzaUl |
| # list nat networks | |
| VBoxManage list natnets | |
| # remove nat network | |
| VBoxManage natnetworks remove --netname <network-name> |
| #------------ bootstrap the cluster nodes -------------------- | |
| start_cmd='redis-server --port 6379 --cluster-enabled yes --cluster-config-file nodes.conf --cluster-node-timeout 5000 --appendonly yes' | |
| redis_image='redis:5.0-rc' | |
| network_name='redis_cluster_net' | |
| docker network create $network_name | |
| echo $network_name " created" | |
| #---------- create the cluster ------------------------ |
Use Python to:
| node{ | |
| stage('git pull') { | |
| git url: 'https://github.com/caiogallo/ci-sample.git', branch: 'master' | |
| } | |
| stage('build'){ | |
| withMaven(maven: 'maven'){ | |
| sh 'mvn clean package' | |
| } | |
| } | |
| stage('Build docker images'){ |
| ➜ elixir git:(master) make clean test | |
| cd lib/elixir && "/home/caio/Downloads/elixir/rebar" clean | |
| ==> elixir (clean) | |
| rm -rf ebin | |
| rm -rf lib/*/ebin | |
| rm -rf lib/elixir/test/ebin | |
| rm -rf lib/*/tmp | |
| rm -rf lib/mix/test/fixtures/git_repo | |
| rm -rf lib/mix/test/fixtures/deps_on_git_repo | |
| rm -rf lib/mix/test/fixtures/git_rebar |
| SELECT username, count(1) falhas | |
| FROM sys.dba_audit_session | |
| WHERE returncode != 0 | |
| and trunc(timestamp) >= trunc(sysdate) | |
| group by username | |
| union | |
| SELECT '>>TOTAL DE ERROS', count(1) falhas | |
| FROM sys.dba_audit_session | |
| WHERE returncode != 0 | |
| and trunc(timestamp) >= trunc(sysdate) |
| select 'ALTER SYSTEM KILL SESSION ''' || sid || ',' || serial# || ''' immediate;' | |
| from | |
| v$session | |
| where | |
| username in ('DEV6SVT_MDS') | |
| order by | |
| blocking_session; |