Skip to content

Instantly share code, notes, and snippets.

View rcranganu's full-sized avatar

Razvan Cranganu rcranganu

View GitHub Profile

5 Steps for Creating Templates and Virtual Machines on Proxmox using Linux Distro's Cloud Images

This tutorial guides you through the process of creating Templates and Virtual Machines on Proxmox using cloud-based images from various Linux distributions. We provide clear instructions for Alma Linux 9, Amazon Linux 2, CentOS 9, Fedora 38, Oracle Linux 9, RHEL 9, Rocky Linux 9, and Ubuntu 23.04 Lynx Lobster.

Note: The instructions have been tested on Proxmox 8.0.4.

Let's begin by choosing the cloud-based image. If you already have your preferred Linux distribution, skip to the 1st step.

To assist in making informed choices when selecting a Linux distribution for your virtual machines, we've compiled a table showcasing key characteristics of each cloud image. This table provides a snapshot of important attributes, including kernel version, Python version, number of processes initialized after boot, number of packages installed, free memory after boot, VM disk size, root partition disk size, used size on t

@rcranganu
rcranganu / aws-linux-2-wordpress.sh
Created October 24, 2019 10:05 — forked from byronfriesen/aws-linux-2-wordpress.sh
Amazon Linux 2 LTS - Wordpress / PHP-FPM / NGINX / MariaDB / WP-CLI Auto Install
#!/bin/bash
##############################################################
# Set Your System and Wordpress Config Preferences
##############################################################
export SYSTEM_USER=username # User PHP-FPM runs under
# Database
export WP_DB_NAME=wordpress
@rcranganu
rcranganu / roles_invesitgation.md
Created August 18, 2017 08:49 — forked from facultymatt/roles_invesitgation.md
Roles and permissions system for Nodejs
<!DOCTYPE html>
<html>
<head>
<title>Bodum B2B</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="Bodum B2B website">
<style>
body {
background-color:#ffffff;
@rcranganu
rcranganu / file.php
Last active May 18, 2016 23:17
Get current user cover image url
<?php
$current_user = wp_get_current_user();
$cover_src = bp_attachments_get_attachment( 'url', array( 'item_id'=> $current_user->ID, ) );
@rcranganu
rcranganu / delete_orders.php
Last active May 16, 2016 13:29
Magento: Delete orders from based on ID
<?php
require 'app/Mage.php';
Mage::app('admin')->setUseSessionInUrl(false);
// set the orders id range
for ($i = 100000000; $i <= 100018752; ++$i) {
$range[] = $i;
}
$test_order_ids=$range;
@rcranganu
rcranganu / child-pages.php
Created September 22, 2014 20:06
List the excepert of a child pages
<?php
$args = array(
'post_type' => 'page',
'posts_per_page' => -1,
'post_parent' => $post->ID,
'order' => 'ASC',
'orderby' => 'menu_order'
);
@rcranganu
rcranganu / key_pref
Last active August 29, 2015 14:03
sublimetext user pref
[
{ "keys": ["super+k"], "command": "toggle_side_bar" },
{ "keys": ["super+f12"], "command": "goto_definition" }
]
@rcranganu
rcranganu / shrink.js
Last active August 29, 2015 13:56
shrink the top bar of a site
jQuery(function( $ ){
$(document).on("scroll", function(){
if($(document).scrollTop() > 100){
$(".site-header").addClass("shrink");
} else {
$(".site-header").removeClass("shrink");
@rcranganu
rcranganu / WP: custom_meta_box.php
Last active December 16, 2015 22:39
Custom Meta Fields
<?php
//Standard post CustomFieds
function add_custom_meta_box() {
add_meta_box(
'custom_meta_box', // $id
'Custom Meta Box', // $title
'show_custom_meta_box', // $callback
'post', // $page
'normal', // $context
'high'); // $priority