Skip to content

Instantly share code, notes, and snippets.

View iledarn's full-sized avatar

Ildar iledarn

  • Belarus, Minsk
View GitHub Profile
@iledarn
iledarn / bash_aliases-docker-compose
Created September 26, 2018 08:18
Bash Aliases for Docker-Compose
# docker-compose aliases
### How to install/use it
1. `curl -ko $HOME/.bash_aliases-docker-compose https://gist.githubusercontent.com/jodumont/d8ade3ab173700e3369f04fbe0334fde/raw/ced78642a5682e7ec6ee7fc89367b929ef35f366/bash_aliases-docker-compose`
2. `echo -e "\nif [ -f ~/.bash_aliases-docker-compose ]; then \n. ~/.bash_aliases-docker-compose\nfi" >> $HOME/.bashrc`
3. `. $HOME/.bashrc`
## dcu == Docker-Compose Up
alias dcu="docker-compose up -d --remove-orphans"
## dcl == Docker-Compose Logs
@iledarn
iledarn / denite.md
Created June 19, 2018 16:53 — forked from dlants/denite.md
denite setup with interactive ag pattern-search of project contents

Files

First things first, I want to use ag to search through my project files. Coming from fzf, I like to have two bindings for this -- one that respects my projects .gitignore and one that does not. The latter is helpful if I want to examine a built file or look at a node_module dependency while working on my js project.

I use an alias for file_rec source to toggle the -u flag on ag. Now, <C-P> searches in my git files, and <C-O> searches everything.

" denite file search (c-p uses gitignore, c-o looks at everything)
map <C-P> :DeniteProjectDir -buffer-name=git -direction=top file_rec/git<CR>
map  :DeniteProjectDir -buffer-name=files -direction=top file_rec
@iledarn
iledarn / steps.md
Created January 8, 2018 12:11 — forked from ntfc/steps.md
arch linux installation steps
@iledarn
iledarn / nginx_odoo.conf
Last active May 10, 2017 15:21 — forked from yelizariev/nginx_odoo.conf
How to deploy SaaS Demo
server {
listen 80;
#rewrite ^/.*$ https://$host$request_uri? permanent; #Uncomment this line in case you want to use https only
server_name NGINX_SERVER_DOMAIN;
include odoo_params;
location /longpolling {
proxy_pass http://SERVER_HOST:8072;
}
#
su
# ivann + general
mkdir /root/.ssh
curl --silent https://github.com/yelizariev.keys | xargs echo -n >> /root/.ssh/authorized_keys
echo -ne " yelizariev@it-projects.info\n" >> /root/.ssh/authorized_keys
sed -i 's/PermitRootLogin no/PermitRootLogin without-password # changed by Ivan Yelizariev from value "no"/' /etc/ssh/sshd_config
@iledarn
iledarn / odoo-sh.py
Created January 10, 2017 09:04 — forked from dreispt/odoo-sh.py
Odoo Shell: run Odoo commands without a server RPC connection
"""
Setup:
Assuming Odoo 8.0 sources at ~/odoo:
$ cp odoo-sh.py ~/odoo
$ cd ~/odoo
$ python -i odoo-sh.py
Usage example:
>>> env = connect('my-db-name')
>>> Users = env['res.users']