Skip to content

Instantly share code, notes, and snippets.

@Siedrix
Siedrix / snippet.md
Last active Sep 3, 2018
Certbot wildcard subdomains
View snippet.md
git clone https://github.com/certbot/certbot
cd certbot
git checkout v0.22.0
sudo ./certbot-auto --os-packages-only
./tools/venv.sh
source venv/bin/activate
certbot -d *.domain.com --manual --preferred-challenges dns-01 --server https://acme-v02.api.letsencrypt.org/directory certonly
@Siedrix
Siedrix / spec.md
Last active Jun 6, 2016
The imposible project
View spec.md

Objetivo del evento:

  • Aprender a hacer landing pages.

Metricas a juzgar:

  • Que tan poco viable es la idea. Mientras menos viable y mas sci-fi, mejor.
  • Hacer una landing page que venda esta idea y convenza de comprar esta idea.

Posibles ideas:

View cacheless-server.js
const koa = require('koa')
const Router = require('koa-router')
const request = require('request-promise')
const app = koa()
const router = new Router()
router.get('/', function *(next) {
var body = yield request({
View nginx-sample
upstream siedrixServer {
server localhost:4000;
}
server {
listen 80;
server_name siedrix.com;
root /home/ubuntu/siedrix;
@Siedrix
Siedrix / ejercicio-1.js
Created Jan 24, 2016
Ejercicios de la tarea 1
View ejercicio-1.js
var inquirer = require('inquirer')
var valorAAdivinar = 6
inquirer.prompt([
{
type:'input',
name:'adivina',
message:'Elije un numero del 1 al 10'
}
], function (answers) {
@Siedrix
Siedrix / client.js
Created Apr 6, 2015
Tutum websocket examples
View client.js
var WebSocket = require('ws');
var userPublicToken = 'apikey';
var username = 'username';
var ws = new WebSocket('wss://stream.tutum.co/v1/events?token='+ userPublicToken +'&user=' +username);
ws.on('open', function() {
console.log('Connected');
});
@Siedrix
Siedrix / backbone.widget.js
Last active Aug 29, 2015
Backbone.Widget
View backbone.widget.js
Backbone.Widget = function() {
this.initialize.apply(this, arguments);
};
_.extend(Backbone.Widget.prototype, Backbone.Events, {
initialize : function(){},
});
Backbone.Widget.extend = Backbone.View.extend;
@Siedrix
Siedrix / add-register.py
Created Sep 7, 2014
Redbird example with adding host with redis
View add-register.py
import redis
import json
register = {
"src" : "nodebots-dev.mx",
"target" : "http://127.0.0.1:4500/"
}
registerAsStr = json.dumps(register)
View bower.json
{
"name": "url-patterns",
"version": "0.0.0",
"authors": [
"Siedrix <Siedrix@gmail.com>"
],
"license": "MIT",
"ignore": [
"**/.*",
"node_modules",
@Siedrix
Siedrix / bower.json
Created Jul 20, 2014
Example of Backbone and React working together
View bower.json
{
"name": "backbone-react-example",
"version": "1.0.0",
"authors": [
"Siedrix <Siedrix@gmail.com>"
],
"description": "backbone react todo list",
"license": "MIT",
"dependencies": {
"backbone": "~1.1.2",
You can’t perform that action at this time.