Skip to content

Instantly share code, notes, and snippets.

View yoimbert's full-sized avatar

yoimbert yoimbert

View GitHub Profile
@mrpeardotnet
mrpeardotnet / PVE-host-backup.md
Created December 17, 2019 18:03
Proxmox PVE Host Config Backup Script

Proxmox PVE Host Config Backup Script

This script can be used to backup essential configuration files from the Proxmox Virtual Enivronment (PVE) host.

The script will create backups using tar with specified backup prefix and date and time stamp in the file name. Script will also delete backups that are older then number of days specified.

Create backup script file

To create backup script that will be executed every day we can create backup script in /etc/cron.daily/ folder. We need to make it writeable by root (creator) only, but readable and executable by everyone:

touch /etc/cron.daily/pvehost-backup
***
*** Inscrivez vous aux webinaires 2017 : https://attendee.gotowebinar.com/register/7239291589398918401
***
Webinaire "Présentation des principaux services AWS" :
https://www.youtube.com/watch?v=FC--jteXU_8
http://www.slideshare.net/JulienSIMON5/presentation-des-services-aws
Webinaire "Modèle de sécurité AWS" :
https://www.youtube.com/watch?v=1QeKH-5nTIc
@ziadoz
ziadoz / chromcast-bgs.js
Last active October 12, 2015 15:19
Download Google ChromeCast Backgrounds with CasperJS
/**
* Command: casperjs chomecast-bgs.js [DIR] [START] [END]
* Examples: casperjs chomecast-bgs.js ~/Downloads/Chromecast
* casperjs chomecast-bgs.js ~/Downloads/Chromecast 25
* casperjs chomecast-bgs.js ~/Downloads/Chromecast 25 35
*
* Note: [DIR] (Required) The directory to download. This must exist, it won't be created.
* [START] (Optional) Start is the image number to start from, incase the script fails and needs to be restarted.
* [END] (Optional) End is the image number to finish at, if you only want a specific range of images.
*/
<?php
use Aws\Common\Aws;
use Aws\S3\Exception\S3Exception;
// make sure the SDK is installed
// I've used Composer to autoload it: http://docs.aws.amazon.com/aws-sdk-php/guide/latest/installation.html
/*
* jQuery File Upload Plugin PHP Class 7.1.0
* https://github.com/blueimp/jQuery-File-Upload
@aquelito
aquelito / git-command.md
Last active May 16, 2024 13:52
GIT - Ligne de commande principale
title category
Git config
Git

Rappel

Ne pas oublier : l'aide en ligne de commande.

@hummus
hummus / gist:8592113
Last active April 26, 2024 19:45
aws cli + jq example
wget http://stedolan.github.io/jq/download/linux64/jq
aws ec2 describe-instances --filters "Name=tag:Name,Values=$NAME" \
"Name=instance-state-name,Values=running" \
| jq -r \
".Reservations[] | .Instances[] | .InstanceId" \
aws ec2 describe-volumes --filters \
"Name=status,Values=available" \
| jq -r ".Volumes[] | .VolumeId" \
# Documentation: https://developers.google.com/compute/docs/gcutil/
# Move into home directory
cd ~
# Download gcutil-1.8.2.zip
curl https://google-compute-engine-tools.googlecode.com/files/gcutil-1.8.2.zip > gcutil-1.8.2.zip
# Unpack gcutil and remove original file
unzip gcutil-1.8.2.zip && unlink gcutil-1.8.2.zip
@robwierzbowski
robwierzbowski / gitcreate.sh
Last active August 8, 2023 07:31
A simple litte script. Create and push to a new github repo from the command line.
#!/bin/bash
# https://gist.github.com/robwierzbowski/5430952/
# Create and push to a new github repo from the command line.
# Grabs sensible defaults from the containing folder and `.gitconfig`.
# Refinements welcome.
# Gather constant vars
CURRENTDIR=${PWD##*/}
GITHUBUSER=$(git config github.user)