Skip to content

Instantly share code, notes, and snippets.

@ed-parsadanyan
ed-parsadanyan / dumbbell_plot.R
Created April 17, 2022 23:50
R code for the Telegram bot powered by n8n
# Make a dumbbell plot of the current and min/max temperatures in some EU capitals
# 2022-04-18 by Ed Parsadanyan
library(ggplot2)
library(ggthemes)
library(magrittr)
library(dplyr)
library(tidyr)
library(lubridate)
@ed-parsadanyan
ed-parsadanyan / workflow.json
Last active May 9, 2022 10:51
n8n extract gas price
{
"nodes": [
{
"parameters": {},
"name": "Start",
"type": "n8n-nodes-base.start",
"typeVersion": 1,
"position": [
240,
300
@ed-parsadanyan
ed-parsadanyan / docker-compose-example.yml
Last active May 12, 2022 12:13
Example of Docker Compose file with several services and NGINX reverse proxy
version: '3.5'
services:
nginx:
image: nginx
restart: always
volumes:
- './nginx.conf:/etc/nginx/nginx.conf:z'
- './config/container/letsencrypt:/etc/letsencrypt:z'
@ed-parsadanyan
ed-parsadanyan / nginx-example.conf
Created May 12, 2022 11:55
Example of NGINX configuration that works together with the docker-compose.yml setup
worker_processes 1;
events { worker_connections 1024; }
http {
sendfile on;
upstream n8n {
server n8n:5678;
}
@ed-parsadanyan
ed-parsadanyan / certify-example.sh
Last active May 12, 2022 12:11
Run this script once per new subdomain
#!/usr/bin/env bash
Domain='sub.domain.com'
Email="myfancy@email.com"
Staging=0
if [ ! -z "$1" ]; then
Domain="$1"
if [ ! -z "$2" ]; then
{
"nodes": [
{
"parameters": {},
"name": "Start",
"type": "n8n-nodes-base.start",
"typeVersion": 1,
"position": [
240,
300
{
"nodes": [
{
"parameters": {},
"name": "Start",
"type": "n8n-nodes-base.start",
"typeVersion": 1,
"position": [
240,
300
{
"nodes": [
{
"parameters": {},
"name": "Start",
"type": "n8n-nodes-base.start",
"typeVersion": 1,
"position": [
240,
300
{
"meta": {
"instanceId": "dfdeafd1c3ed2ee08eeab8c2fa0c3f522066931ed8138ccd35dc20a1e69decd3"
},
"nodes": [
{
"parameters": {},
"id": "7dbe7f1e-3400-447d-b33b-1401af681fd2",
"name": "Start",
"type": "n8n-nodes-base.start",
@ed-parsadanyan
ed-parsadanyan / models.xsl
Created September 8, 2023 09:33
XSLT stylesheet for an SQL to XML conversion example
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
<html>
<head>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/css/bootstrap.min.css"></link>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/js/bootstrap.bundle.min.js"></script>
<style>
.emoji {
font-size: 1.5rem; /* Adjust as needed */
line-height: 1.5rem;