Skip to content

Instantly share code, notes, and snippets.

View azizshamim's full-sized avatar
:octocat:
talkin' bout GitHub

Aziz Shamim azizshamim

:octocat:
talkin' bout GitHub
View GitHub Profile
@0xabad1dea
0xabad1dea / copilot-risk-assessment.md
Last active September 11, 2023 10:21
Risk Assessment of GitHub Copilot

Risk Assessment of GitHub Copilot

0xabad1dea, July 2021

this is a rough draft and may be updated with more examples

GitHub was kind enough to grant me swift access to the Copilot test phase despite me @'ing them several hundred times about ICE. I would like to examine it not in terms of productivity, but security. How risky is it to allow an AI to write some or all of your code?

Ultimately, a human being must take responsibility for every line of code that is committed. AI should not be used for "responsibility washing." However, Copilot is a tool, and workers need their tools to be reliable. A carpenter doesn't have to

The Freenode resignation FAQ, or: "what the fuck is going on?"

IMPORTANT NOTE:

It's come to my attention that some people have been spamming issue trackers with a link to this gist. While it's a good idea to inform people of the situation in principle, please do not do this. By all means spread the word in the communities that you are a part of, after verifying that they are not aware yet, but unsolicited spam is not helpful. It will just frustrate people.

Update 3 (May 24, 2021)

A number of things have happened since the last update.

############################################################
# Daemon
############################################################
# Start in daemon (background) mode and release terminal (default: off)
daemon on
# File to store the process ID, also called pid file. (default: not defined)
process_id_file /var/run/motion.pid
@yunano
yunano / consul-template.service
Created May 1, 2015 15:54
/etc/systemd/system/consul-template.service
[Unit]
Description=consul-template
Requires=network-online.target
After=network-online.target consul.service vault.service
[Service]
EnvironmentFile=-/etc/sysconfig/consul-template
Restart=on-failure
ExecStart=/usr/local/sbin/consul-template $OPTIONS -config=/etc/consul-template.d

How to become a decent photographer in five years

You're not gonna become a master in your spare time, but you can get decently good at photography in five years of dedicated but non-full-time practice. It's taken me about twice that to get decent, but I fucked around a lot along the way.

You don't need a ton of fancy equipment, but photography does require some gear. I'll limit the gear-buying here to once a year (not counting books).

@stephenyeargin
stephenyeargin / remote-control-dashing.md
Last active April 27, 2017 11:41
Using Dashing with Hubot to control which dashboard is being shown.

Remotely control your Dashing Dashboard

The problem

We have a dashboard at the office that displays some internal company metrics so everyone can be up to speed on them. However, when we have guests, we have to either SSH into the Raspberry Pi or simply turn off the television. This seems clumsy, and we can do better than that.

The solution

Dashing works by adding event listeners in Javascript and updating the associated widgets. We're going to hijack this process to build a simple redirect that can accept a posted value and send the dashboard to another screen.

@jfryman
jfryman / gist:4744a01fd68b6336377a
Last active May 22, 2020 17:48
DO Post Mortem - Mark Imbriaco
Hi, I would like to take a moment to apologize for the problems you may have experienced accessing your droplets in the NYC2 region July 21st, starting around 6PM Eastern time. Providing a stable infrastructure for all customers is our number one priority, and whenever we fall short we work to understand the problem and take steps to reduce the chance of it happening again.
In this case, we’ve determined what were a few related events which contributed to the outage:
First, we had a problematic optical module in one of our switches that was sending malformed packets to one of the core switches in our network. Under normal circumstances, losing connectivity to a single core switch should not be problematic since each cabinet in our datacenter is connected to multiple upstream switches. In this case, however, the invalid data caused problems with the upstream core switch.
When the core switch received the invalid packet, it triggered a bug in the software on the core switch which caused some internal process
require "thread"
Thread.abort_on_exception = true
class ReadWriteLock
def initialize
@lock_request_queue = SizedQueue.new(1)
@thread = Thread.new { thread_main }
@readers = 0
@writer_queue = []
GitHub is pretty awesome. Pass it on!
@kesor
kesor / Gemfile
Created March 19, 2013 00:32
Vagrant configuration to install two Ubuntu 12.04 servers, first server has a Chef Server installed, second server has a Chef Client installed, and the folder where these files are places is configured to be a Chef Workstation using admin.pem.
source "https://rubygems.org"
gem 'chef', '>= 11.0'
gem 'librarian'
gem 'vagrant', '= 1.0.6'
gem 'vagrant-hostmaster'
gem 'foodcritic'