Skip to content

Instantly share code, notes, and snippets.

View schiggi's full-sized avatar

Alex Schikalow schiggi

View GitHub Profile
@schiggi
schiggi / arm.md
Created December 5, 2023 20:57 — forked from alexellis/arm.md
Test swarm connectivity

Regular PC / cloud architecture (64-bit)

See the snippets "guide.md" and "redis.md" below.

Swarm on a Raspberry Pi

If you're wanting to run Docker Swarm on your Raspberry Pi checkout these instructions:

@schiggi
schiggi / transfer_to_git.sh
Last active January 12, 2018 12:08
Automatic database transfer for test environment with sql modifications via Git
#!/bin/bash
# Set variables
DB_NAME="database"
TMP_DB="tmp-db"
DB_USER="transfer_user_mysql"
CNF_PATH="$HOME/.transfer_user.cnf"
WORK_PATH="$HOME/db_transfers"
FULLDATE=$(date +"%Y-%d-%m %H:%M")
NOW=$(date +"%Y-%m-%d-%H-%M")
@schiggi
schiggi / Pull-and-Sync-Data-Between-Google-Doc-Spreadsheet-and-MySQL.gs
Created August 15, 2017 18:28
You can pull data from MySQL database to Google doc spreadsheet auto with just click of a button or scheduled time. This is great use for retrieving data in spreadsheet format.
// MySQL to Google Spreadsheet By Pradeep Bheron
// Support and contact at pradeepbheron.com
function myMySQLFetchData() {
var conn = Jdbc.getConnection('jdbc:mysql://127.0.0.1:3306/employee_db', 'username', 'pass'); // Change it as per your database credentials
var stmt = conn.createStatement();
var start = new Date(); // Get script starting time
@schiggi
schiggi / update_mysql_from_dbf.php
Last active January 20, 2017 11:22
Little script to update data from dbf to mysql
<?php
require_once('config.php');
$dbf_file = 'KESZLET.DBF';
$dbf_table_columns = 'CIKKSZAM, DARAB';
// Set temp table in db to work with for update (will perform a JOIN with product table)
$temp_table = 'TMP-vega_import_stock';
// Set column names for product model and quantity in temp table
$temp_table_columns = ["product_model_identifier" => 'model_sku',"product_quantity" => 'qty'];