Skip to content

Instantly share code, notes, and snippets.

View monorkin's full-sized avatar
👻
Boo!

Stanko Krtalić monorkin

👻
Boo!
View GitHub Profile
@monorkin
monorkin / clean_docker.sh
Last active December 1, 2016 12:53
Script for cleaning garbage docker files
# Remove stopped images
echo "Removing unused containers..."
if [[ -z $(docker ps -a -q) ]]
then
echo "No unused containers found."
else
docker rm $(docker ps -a -q)
fi
# Remove dangling volumes
require 'rspec/autorun'
module Memoizer
def memoize(method_name)
method = instance_method(method_name)
define_method(method_name) do |*args|
variables = instance_variables.each_with_object({}) do |name, hash|
hash[name] = instance_variable_get(name) unless name == :@memoization
end

Server setup guide

Setting up a bare metal server

Passwordless authentification

After purchasing a bare metal server and receiving it's IP address and password, the first thing you need to do is connect to it using SSH.

@monorkin
monorkin / WAT.rb
Last active September 17, 2016 21:23
# Example 1
module Logger
extend self
attr_accessor :output, :log_actions
def log(&event)
self.log_actions ||= []
self.log_actions << event
end
@monorkin
monorkin / cv.md
Last active October 2, 2016 20:34

Stanko Krtalić Rusendić

I'm a 23 year old interested in software development, computer science, IoT and photography. Most of all I love creating software that people love to use and which makes their lives easier. I'm also a regular speaker at Zag.rb.

Contact