Skip to content

Instantly share code, notes, and snippets.

import Ember from 'ember';
import DS from 'ember-data';
const DEFAULT_NAMESPACE = 'DS.LSAdapter';
const LSAdapter = DS.Adapter.extend(Ember.Evented, {
/**
* This governs if promises will be resolved immediately for `findAll`
* requests or if they will wait for the store requests to finish. This matches
* the ember < 2.0 behavior.
@profOnno
profOnno / Alpine_linux_on_tilaa.md
Last active February 25, 2024 13:35
Alpine linux on Tilaa

Introduction

Tilaa is my vps provider but doesn't have alpine in the install options After playing around with the vps systems... coreos ubuntu.. i did make mistakes... coreos got invaded ... opened a webgui... forgot to protect it... needed to get some data from it. So used the Tilaa rescue boot (in the Dashboard) and mounted the disks. Also used it when i increased the disk size for an installation (if I remember correctly), deleting the partition, creating a new one with the same starting address), do a resize2fs to expand and voila.. Bob was my uncle.

After playing arround with Alpine Linux in coreos and ubuntu lxd. I thought it would be a nice distro to get running straight from the vps. A weekend without sunlight but with pixellight I got it running, needs another iteration to make it a smooth experiance :o.

DISCLAIMER Any action you take upon the information on this page is strictly at your own risk, I won't be liable for any losses and damages in connection with the use of this page.

St

Postgresql for Alpine

apk update
apk add postgresql

Then change /etc/postgresql/postgresql.conf

listen_addresses = 'localhost' # what IP address(es) to listen on;

@profOnno
profOnno / lxd_ovs.md
Last active October 29, 2017 18:42
trying LXD with openvswitch
// needed?
ifconfig lxdbr0 down

//delete containers using lxdbr0 and then delete the bridge

lxc network delete lxdbr0
sudo apt-get install openvswitch-switch
@profOnno
profOnno / rust_sailfish_qml.md
Last active September 20, 2017 21:39
Rust Sailfish QML

SSH

ssh -p 2222 -i ~/SailfishOS/vmshare/ssh/private_keys/engine/mersdk mersdk@localhost as root ssh -p 2222 -i ~/SailfishOS/vmshare/ssh/private_keys/engine/root root@localhost

Switch target

sb2 -t SailfishOS-armv7hl -R for root on armv7hl

sb2 -t SailfishOS-i486 -R for root on i486

@profOnno
profOnno / clock.jscad
Created December 17, 2016 13:52
OpenJSCAD clock animation
//
// clock animation
// for fast animation three.js or babylon.js ?..
// timeout bug... <shift><enter> starts new worker? old timer keeps running
function clock(hour, minute, second) {
var t = second + 60 * (minute + 60 * hour);
var h = cylinder({r:0.3,h:4}).setColor(1,0,0).rotateX(-t/60/60/12*360);
var m = cylinder({r:0.2,h:5}).setColor(0,1,0).rotateX(-t/60/60*360);
#!/usr/bin/env bash
# docker run -ti --name sailfish-dev5 --privileged -v $PATH_ON_HOST:/var/fairphone_os/ jftr/fairphone2-build-env /bin/bash
adduser fp2
usermod -a -G sudo fp2
su fp2
cd /home/fp2
1|shell@FP2:/ $ cat /proc/mounts | grep "^\/dev\/"
/dev/block/platform/msm_sdcc.1/by-name/system /system ext4 ro,seclabel,relatime,discard,data=ordered 0 0
/dev/block/platform/msm_sdcc.1/by-name/userdata /data ext4 rw,seclabel,nosuid,nodev,relatime,discard,noauto_da_alloc,data=ordered 0 0
/dev/block/platform/msm_sdcc.1/by-name/cache /cache ext4 rw,seclabel,nosuid,nodev,relatime,data=ordered 0 0
/dev/block/platform/msm_sdcc.1/by-name/persist /persist ext4 rw,seclabel,nosuid,nodev,relatime,data=ordered 0 0
/dev/block/platform/msm_sdcc.1/by-name/modem /firmware vfat ro,context=u:object_r:firmware_file:s0,relatime,uid=1000,gid=1000,fmask=0337,dmask=0227,codepage=cp437,iocharset=iso8859-1,shortname=lower,errors=remount-ro 0 0
/dev/fuse /mnt/shell/emulated fuse rw,nosuid,nodev,noexec,relatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
/dev/fuse /mnt/shell/emulated/0 fuse rw,nosuid,nodev,noexec,relatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
@profOnno
profOnno / fairphone_defconfig
Created November 4, 2016 12:52
Fairphone2 usb serial kernel config
# CONFIG_ARM_PATCH_PHYS_VIRT is not set
CONFIG_EXPERIMENTAL=y
CONFIG_SYSVIPC=y
CONFIG_AUDIT=y
CONFIG_RCU_FAST_NO_HZ=y
CONFIG_IKCONFIG=y
CONFIG_CGROUPS=y
CONFIG_CGROUP_DEBUG=y
CONFIG_CGROUP_FREEZER=y
CONFIG_CGROUP_CPUACCT=y
import DS from 'ember-data';
export default DS.Model.extend({
hash: DS.attr(),
size: DS.attr(),
height: DS.attr(),
version: DS.attr(),
merkleroot: DS.attr(),
time: DS.attr(),
nonce: DS.attr(),