Skip to content

Instantly share code, notes, and snippets.

View vanzhiganov's full-sized avatar

Vyacheslav Anzhiganov vanzhiganov

View GitHub Profile
@vanzhiganov
vanzhiganov / .ansible.cfg
Last active June 9, 2024 00:47 — forked from wbcurry/.ansible.cfg
Ansible: .ansible.cfg
# config file for ansible -- http://ansible.com/
# ==============================================
# nearly all parameters can be overridden in ansible-playbook
# or with command line flags. ansible will read ANSIBLE_CONFIG,
# ansible.cfg in the current working directory, .ansible.cfg in
# the home directory or /etc/ansible/ansible.cfg, whichever it
# finds first
[defaults]
#! /bin/sh
set -e
# This script originates from http://www.debian.org/mirror/anonftpsync
# CVS: cvs.debian.org:/cvs/webwml - webwml/english/mirror/anonftpsync
# Version: $Id: anonftpsync,v 1.43 2008-06-15 18:16:04 spaillar Exp $
# Note: You MUST have rsync 2.6.4 or newer, which is available in sarge
# and all newer Debian releases, or at http://rsync.samba.org/
@vanzhiganov
vanzhiganov / docker-nfs-volumes.md
Created May 5, 2023 08:18 — forked from ruanbekker/docker-nfs-volumes.md
NFS Volumes with Docker Swarm

Create NFS Volumes:

Creating the NFS Volume:

$ docker volume create --driver local \
  --opt type=nfs \
  --opt o=addr=192.168.1.115,uid=1000,gid=1000,rw \
  --opt device=:/mnt/volumes/mysql-test \
  mysql-test-1
@vanzhiganov
vanzhiganov / README.md
Created February 5, 2023 07:02 — forked from magnetikonline/README.md
BIND - delegate a sub domain for a zone.

BIND - delegate a sub domain for a zone

The scenario:

  • DNS zone myzone.com defined in BIND.
  • Authoritative name server at 123.16.123.1.
  • Subzone sub.myzone.com with an authoritative name server at 123.16.123.10.
  • Wishing to forward sub-zone to authoritative name server.

Config

@vanzhiganov
vanzhiganov / mysql_query_log.md
Created February 3, 2023 07:24 — forked from joseluisq/mysql_query_log.md
How to enable the MySQL/MariaDB general query logs

How to enable the MySQL/MariaDB general query logs

  1. Enter to MySQL/MariaDB server command-line tool (change root with your username and password):
mysql -u root -proot
  1. Set the general log file path:
SET GLOBAL general_log_file='/var/log/mysql/mycustom.log';
@vanzhiganov
vanzhiganov / README.md
Created January 5, 2023 05:47 — forked from denji/README.md
Simple Sentry docker-compose.yml
  1. Download docker-compose.yml to dir named sentry
  2. Change SENTRY_SECRET_KEY to random 32 char string
  3. Run docker-compose up -d
  4. Run docker-compose exec sentry sentry upgrade to setup database and create admin user
  5. (Optional) Run docker-compose exec sentry pip install sentry-slack if you want slack plugin, it can be done later
  6. Run docker-compose restart sentry
  7. Sentry is now running on public port 9000
@vanzhiganov
vanzhiganov / ansible_folder_structure
Created October 9, 2017 00:15 — forked from akkaash/ansible_folder_structure
Create Simple ansible folder structure
mkdir -p $PROJECT_NAME/roles/{web,db}/{tasks,handlers,templates}
touch $PROJECT_NAME/main.yml $PROJECT_NAME/roles/{web,db}/{tasks,handlers,templates}/main.yml
@vanzhiganov
vanzhiganov / letsencrypt-auto-renew
Created February 19, 2017 12:44 — forked from neutronth/letsencrypt-auto-renew
Let's Encrypt auto renew script
#/bin/sh
OPTS=$(getopt -o cehw: --long config:,expire-limit:,help,webservice: -n "$0" -- "$@")
if [ $? != 0 ]; then
echo "Terminating ..." >&2
exit 1
fi
CONFIG=/etc/letsencrypt/cli.ini
WEBSERVICE=nginx