Skip to content

Instantly share code, notes, and snippets.

View theprincy's full-sized avatar

Notelseit.com theprincy

View GitHub Profile
@theprincy
theprincy / LICENSE
Last active August 29, 2015 14:27 — forked from faizal2007/LICENSE
Bash Image Optimization for web
The MIT License (MIT)
Copyright (c) 2013 wackoen
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
@theprincy
theprincy / gist:9abedeff2c1e1354421b
Last active September 8, 2015 04:47 — forked from davidalexander/gist:1086455
Magento Snippets

Magento Snippets

Download extension manually using pear/mage

Pear for 1.4, mage for 1.5. File downloaded into /downloader/.cache/community/

./pear download magento-community/Shipping_Agent
./mage download community Shipping_Agent

Clear cache/reindex

@theprincy
theprincy / magento-code-snippets.md
Last active September 8, 2015 04:49 — forked from arosenhagen/magento-code-snippets.md
[magento] - code snippets

Magento Code Snippets

Download extension manually using mage

./mage config-set preferred_state stable
./mage clear-cache
./mage sync
./mage download community Module_Name
@theprincy
theprincy / bulk_ip_whois.py
Created March 26, 2017 07:57 — forked from atelenga/bulk_ip_whois.py
Simple script for bulk IP whois lookup
### Install DMitry pacakge before use
### sudo apt-get install dmitry
###
import sys, subprocess
if __name__ == "__main__":
if len(sys.argv) != 2:
print "usage: %s <file with IP list>" % sys.argv[0]
sys.exit(1)
@theprincy
theprincy / install.sh
Created May 3, 2018 06:12 — forked from stayallive/install.sh
Install PHP 5.6.7 on Plesk 11.5 & 12 (CentOS 6)
#!/bin/bash
# Make sure you are up to date
yum -y update && yum -y install wget
# Install EPEL repository
rpm -ivh http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
# Get us a clean working directory
mkdir /php
@theprincy
theprincy / file.html
Created June 11, 2018 11:31
Trasfer file server to another server
<body>
<form method="post">
<input name="url"size="50" />
<input name="submit" type="submit" />
</form>
<?php
set_time_limit (24 * 60 * 60);
if (!isset($_POST['submit'])) die();
// $destination_folder = 'download/';
$url = $_POST['url'];
@theprincy
theprincy / hetzner-proxmox-docker.sh
Last active February 15, 2023 11:02 — forked from rwenz3l/hetzner-proxmox-docker.sh
Hetzner Dedicated with Debian 10 and Proxmox 6 (LXC) + Docker-CE + Portainer [NAT]
#############################################
### Proxmox V & Docker-CE + Portainer #
#############################################
## Rescue System
# Erase other disks
dd if=/dev/zero of=/dev/sda bs=1M count=100
dd if=/dev/zero of=/dev/sdb bs=1M count=100
# You can install debian 10 via the guide:
@theprincy
theprincy / README.md
Last active February 9, 2021 13:41 — forked from mrrooijen/README.md
Setting up XEN on a Hetzner Dedicated Server

Setting up XEN on a Hetzner Dedicated Server

Author: Michael van Rooijen (@mrrooijen)

DISCLAIMER: I am a programmer, not a sysadmin in my day-to-day life. I provide this guide simply as a self-reference, and as a way to contribute to the community of developers. The main motivation for writing this guide is because of the lack of properly written guides/tutorials. They were either out-dated, inaccurate, in a non-English language or simply too vague to understand (at least for me, as a programmer and not a sysadmin).

I hope this guide helps getting you up and running with your own collection of VPS's on your own Dedicated Server over at Hetzner.de.

Requirements:

@theprincy
theprincy / install.php
Created February 9, 2021 14:51 — forked from tschoffelen/install.php
A simple PHP script that automatically downloads and unzips the latest version of Wordpress in the current directory (./), so that I don't have to download it and upload it to my server through FTP manually.
<?php
echo '<pre>';
echo '<span style="color:blue">DOWNLOADING...</span>'.PHP_EOL;
// Download file
file_put_contents('wp.zip', file_get_contents('https://wordpress.org/latest.zip'));
$zip = new ZipArchive();
$res = $zip->open('wp.zip');
if ($res === TRUE) {
@theprincy
theprincy / readydedis.com.conf
Created March 26, 2021 11:26 — forked from Bharat-B/readydedis.com.conf
nGINX rewrite rules for whmcs 8
server {
listen 80 default_server;
server_name readydedis.com www.readydedis.com;
return 301 https://readydedis.com$request_uri;
}
# HTTPS server
#
server {
listen 443;