This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Syabro's Oh My Zsh Theme for servers | |
# | |
# Install: | |
# curl -o ~/.oh-my-zsh/themes/syabro.zsh-theme "https://gist.githubusercontent.com/syabro/f0b1997e75998cc54067dd4e2cc59412/raw" && sed -i 's/^ZSH_THEME=".*"/ZSH_THEME="syabro"/' ~/.zshrc && source ~/.zshrc | |
# | |
# colors: https://www.ditig.com/256-colors-cheat-sheet | |
local red='%{%f%b%F{208}%B%}' | |
local white='%{%f%b%F{white}%B%}' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[tool.poetry] | |
name = "api" | |
version = "0.1.0" | |
description = "" | |
authors = ["Maxim Syabro <[email protected]>"] | |
[tool.poetry.dependencies] | |
python = "*" | |
django = "^2.1" | |
requests = "^2.19" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alfabank.ru | |
https://alfa-laboratory.github.io/arui-feather/styleguide/#themeprovider | |
BluePrint | |
http://blueprintjs.com/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ../nginx-push-stream-module required to be download | |
./configure --prefix=/etc/nginx --sbin-path=/usr/sbin/nginx --modules-path=/usr/lib/nginx/modules --conf-path=/etc/nginx/nginx.conf --error-log-path=/var/log/nginx/error.log --http-log-path=/var/log/nginx/access.log --pid-path=/var/run/nginx.pid --lock-path=/var/run/nginx.lock --http-client-body-temp-path=/var/cache/nginx/client_temp --http-proxy-temp-path=/var/cache/nginx/proxy_temp --http-fastcgi-temp-path=/var/cache/nginx/fastcgi_temp --http-uwsgi-temp-path=/var/cache/nginx/uwsgi_temp --http-scgi-temp-path=/var/cache/nginx/scgi_temp --user=nginx --group=nginx --with-http_ssl_module --with-http_realip_module --with-http_addition_module --with-http_sub_module --with-http_dav_module --with-http_flv_module --with-http_mp4_module --with-http_gunzip_module --with-http_gzip_static_module --with-http_random_index_module --with-http_secure_link_module --with-http_stub_status_module --with-http_auth_request_module --with-http_xslt_module=dynamic --with-threads - |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
{ | |
"extends": "airbnb", | |
"plugins": [ | |
"react" | |
], | |
"parser": "babel-eslint", | |
"parserOptions": { | |
"ecmaVersion": 7, | |
"sourceType": "module", | |
"ecmaFeatures": { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git fetch -p; for branch in `git branch -vv | grep ': gone]' | gawk '{print $1}'`; do git branch -d $branch; done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Setup | |
PROJECTS=“project1 project2" | |
AWS_BUCKET_NAME=... | |
export PGUSER=django | |
export PGPASSWORD=django | |
# Perform backup routines | |
for PROJECT in $PROJECTS; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo "Dumping $1 to /tmp/$1.pgdump..." | |
ssh [email protected] "pg_dump -U www-data -Fc -O $1" > /tmp/$1.pgdump | |
echo "Destroying current DB..."; | |
psql template1 -c "drop database if exists localdb;" > /dev/null | |
echo "Creating DB..."; | |
psql template1 -c "create database localdb" > /dev/null |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ssl_stapling on; | |
ssl on; | |
ssl_certificate /etc/nginx/ssl/bundle.crt; | |
ssl_certificate_key /etc/nginx/ssl/private/server.key; | |
ssl_session_timeout 24h; | |
ssl_session_cache shared:SSL:2m; | |
ssl_protocols TLSv1 TLSv1.1 TLSv1.2; | |
ssl_prefer_server_ciphers on; | |
ssl_ciphers 'ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA256:DHE-DSS-AES128-GCM-SHA256:kEDH+AESGCM:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:DHE-RSA-AES128-SHA256:DHE-RSA-AES128-SHA:DHE-DSS-AES128-SHA256:DHE-RSA-AES256-SHA256:DHE-DSS-AES256-SHA:DHE-RSA-AES256-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128-SHA256:AES256-SHA256:AES128-SHA:AES256-SHA:AES:CAMELLIA:DES-CBC3-SHA:!aNULL:!eNULL:!EXPORT:!DES:!RC4:!MD5:!PSK:!aECDH:!EDH-DSS-DES-CBC3-SHA:!EDH-RSA-DES-CBC3-SHA:!KRB5-DES-CBC3-SHA'; | |
ssl_ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
To speedup tests many developers disables migrations in tests | |
F.e. | |
apps = [app.split('.')[-1] for app in INSTALLED_APPS] | |
MIGRATION_MODULES = {app: "%s.skip_migrations" % app for app in apps} | |
But bad thing about it that migrations aren't being tested for conflicts | |
until we run manage.py migrations | |
This testcase solves it. | |
""" |
NewerOlder