This is based on a guide on the Ubnt forums.
Log into your Edgerouter and run the following - sudo -i && vi /config/user-data/update-adblock-dnsmasq.sh
This will switch you to the root user and open up vi
.
#!/bin/bash
This is based on a guide on the Ubnt forums.
Log into your Edgerouter and run the following - sudo -i && vi /config/user-data/update-adblock-dnsmasq.sh
This will switch you to the root user and open up vi
.
#!/bin/bash
FROM node:${NODE_VERSION}-alpine | |
WORKDIR /app | |
ENV PATH /app/node_modules/.bin:$PATH | |
#COPY package.json yarn.lock ./ | |
COPY package*.json ./ | |
#RUN yarn install --pure-lockfile |
upstream php-fpm { | |
server unix:/var/run/php5-fpm.sock; | |
} | |
server { | |
listen 80; | |
server_name www.example.com; | |
rewrite ^ http://example.com$request_uri?; | |
} |
#!/bin/bash | |
# set -x | |
MANAGER=${1:-3} | |
WORKER=${2:-0} | |
#========================= | |
# Creating cluster members | |
#========================= |
traefik: | |
image: "traefik:v2.1" | |
container_name: "traefik" | |
hostname: "traefik" | |
restart: unless-stopped | |
env_file: | |
- .env | |
ports: | |
- "80:80" | |
- "443:443" |
# Providers :- discover the services that live on your infrastructure (their IP, health, ...) | |
# Entrypoints :- listen for incoming traffic (ports, ...) | |
# Routers :- analyse the requests (host, path, headers, SSL, ...). A router is in charge of connecting incoming requests to the services that can handle them. | |
# Services :- forward the request to your services (load balancing, ...). The Services are responsible for configuring how to reach the actual services that will eventually handle the incoming requests. | |
# Middlewares :- may update the request or make decisions based on the request (authentication, rate limiting, headers, ...) | |
version: "3.7" | |
networks: |
version: "3.8" | |
services: | |
dockerproxy: | |
image: tecnativa/docker-socket-proxy | |
environment: | |
- CONTAINERS=1 | |
networks: | |
- socket_docker | |
volumes: | |
- "/var/run/docker.sock:/var/run/docker.sock" |
lang en_US | |
keyboard us | |
timezone Europe/Helsinki --isUtc | |
reboot | |
text | |
cdrom | |
bootloader --location=mbr --append="rhgb quiet crashkernel=auto" | |
zerombr | |
clearpart --all --initlabel | |
autopart |
Sometime you need scrape prometheus metrics from external envoy that deploy not to kubernetes environment
You can use iptable or other stuff on external server to allow only trusted IP for scraping metrics - but for dynamic infrastructure some time it's hard to support it.
Envoy can expose this metrics more elegant style - using basic auth
Simple envoy.yaml
This guide explains how to create a simple multi cloud Docker cluster using Docker Swarm, Docker Machine and the three top cloud providers nowadays - Google Compute Engine, Microsoft Azure and AWS.
This guide assumes you have a Linux host with Docker CE installed. If you are using Docker for Mac or Docker for Windows you can avoid the Docker Machine set up since it comes included.