Skip to content

Instantly share code, notes, and snippets.

View afelicioni's full-sized avatar
👔
Focused on @aws ☁️

Alessio Felicioni afelicioni

👔
Focused on @aws ☁️
View GitHub Profile
https://support.hpe.com/hpesc/public/km/product/4248036/HPE-ProLiant-MicroServer-Models?ismnp=0&l5oid=4248009&productNumber=612275-421#t=DriversandSoftware&sort=relevancy&layout=table
@afelicioni
afelicioni / public-ip.sh
Created April 4, 2021 20:57
get public ip using curl, awk leveraging cloudflare trace endpoint
#!/bin/bash
IP=$(curl --location --request GET 'https://www.cloudflare.com/cdn-cgi/trace' 2>/dev/null | awk 'BEGIN { FS = "=" } ; $1 == "ip" { print $2 }')
echo $IP
pid.codes is a registry of USB PID codes for open source hardware projects. You can see a list of PID assignments, or learn how to get your own.
https://www.npmjs.com/package/node-cron
https://blog.pyrospect.com/2019/01/how-to-repeat-nodejs-tasks-on-windows.html
https://scotch.io/tutorials/nodejs-cron-jobs-by-examples
https://pm2.keymetrics.io/docs/usage/process-management/
https://pm2.keymetrics.io/docs/usage/startup/
var Base64={_keyStr:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",encode:function(e){var t="";var n,r,i,s,o,u,a;var f=0;e=Base64._utf8_encode(e);while(f<e.length){n=e.charCodeAt(f++);r=e.charCodeAt(f++);i=e.charCodeAt(f++);s=n>>2;o=(n&3)<<4|r>>4;u=(r&15)<<2|i>>6;a=i&63;if(isNaN(r)){u=a=64}else if(isNaN(i)){a=64}t=t+this._keyStr.charAt(s)+this._keyStr.charAt(o)+this._keyStr.charAt(u)+this._keyStr.charAt(a)}return t},decode:function(e){var t="";var n,r,i;var s,o,u,a;var f=0;e=e.replace(/[^A-Za-z0-9+/=]/g,"");while(f<e.length){s=this._keyStr.indexOf(e.charAt(f++));o=this._keyStr.indexOf(e.charAt(f++));u=this._keyStr.indexOf(e.charAt(f++));a=this._keyStr.indexOf(e.charAt(f++));n=s<<2|o>>4;r=(o&15)<<4|u>>2;i=(u&3)<<6|a;t=t+String.fromCharCode(n);if(u!=64){t=t+String.fromCharCode(r)}if(a!=64){t=t+String.fromCharCode(i)}}t=Base64._utf8_decode(t);return t},_utf8_encode:function(e){e=e.replace(/\r\n/g,"n");var t="";for(var n=0;n<e.length;n++){var r=e.charCodeAt(n);if(r<128){t+=String.fromCharCode
@afelicioni
afelicioni / The real customer point of view
Created August 1, 2020 08:33
The real customer point of view
Toglimi:
- la fatica che facevo prima
- i costi che avevo prima
- il tempo che impiegavo prima
- i limiti all’immaginazione di prima… e sarò tuo cliente.
Take me off:
- the effort I used to make
- the costs I had before
- the time I spent before
openssl s_client -tls1_2 -connect imaps.pec.aruba.it:993
@afelicioni
afelicioni / index.php
Created April 12, 2020 22:34
slim 4 setup on subdirectory
<?php
declare(strict_types=1);
use App\Application\Handlers\HttpErrorHandler;
use App\Application\Handlers\ShutdownHandler;
use App\Application\ResponseEmitter\ResponseEmitter;
use DI\ContainerBuilder;
use Slim\Factory\AppFactory;
use Slim\Factory\ServerRequestCreatorFactory;
@afelicioni
afelicioni / gist:b8026d54ec685648de5e26a901809a42
Created March 30, 2020 12:46
resend confirmation password for AWS cognito user in a pool (that has to be in FORCE_CHANGE_PASSWORD status)
aws cognito-idp admin-create-user --user-pool-id eu-central-1_*ID* --username *USERNAME* --message-action RESEND
https://www.linkedin.com/feed/update/urn:li:activity:6648868447843299328/