In this guide we will cover two main cases:
- Ember specific library
- vendor library
The Ember library will assume that Ember has already ben loaded (higher in the loading order) and thus will assume it has access to the Ember API.
| # Set variables in .bashrc file | |
| # don't forget to change your path correctly! | |
| export GOPATH=$HOME/golang | |
| export GOROOT=/usr/local/opt/go/libexec | |
| export PATH=$PATH:$GOPATH/bin | |
| export PATH=$PATH:$GOROOT/bin |
| FROM wordpress | |
| RUN apt-get update && apt-get install -y libmagickwand-6.q16-dev --no-install-recommends \ | |
| && ln -s /usr/lib/x86_64-linux-gnu/ImageMagick-6.8.9/bin-Q16/MagickWand-config /usr/bin \ | |
| && pecl install imagick \ | |
| && echo "extension=imagick.so" > /usr/local/etc/php/conf.d/ext-imagick.ini | |
| RUN apt-get update && apt-get install -y ssmtp --no-install-recommends \ | |
| && echo 'sendmail_path=/usr/sbin/sendmail -t -i\nsendmail_from=FROM_MAIL_ADDRESS' > /usr/local/etc/php/conf.d/set-sendmail.ini |
| from smore.apispec import APISpec | |
| spec = APISpec( | |
| title='Swagger Petstore', | |
| version='1.0.0', | |
| description='This is a sample server Petstore server. You can find out more ' | |
| 'about Swagger at <a href=\"http://swagger.wordnik.com\">http://swagger.wordnik.com</a> ' | |
| 'or on irc.freenode.net, #swagger. For this sample, you can use the api ' | |
| 'key \"special-key\" to test the authorization filters', |
| alias dip="docker inspect -f '{{ .NetworkSettings.IPAddress }}'" | |
| dssh() { | |
| PID=$(docker inspect --format {{.State.Pid}} $1) | |
| sudo /usr/bin/nsenter --target $PID --mount --uts --ipc --net --pid env -i - $(sudo cat /proc/$PID/environ | xargs -0) bash | |
| } | |
| drmiall() { | |
| docker rmi `docker images -q -f dangling=true` | |
| } |
Так сложилось, что времени на блог в чистом виде у меня сейчас нет. А ссылки, между тем, все приходят и приходят. А я их, разумеется, все букмаркаю и букмаркаю. Я много думал, что с этими ссылками делать. Вот одна из моих гипотез.
Дада, те кто был на reddit знают - это примерно именно оно, с некоторыми уточнениями. У меня есть интересные ссылки, в среднем на английском языке. Особой пользы в них нет, однако можно было бы предложить живым людям обсуждать эти ссылки, высказывать свои суждения и вообще. Я это вижу так:
| def reload_urlconf(urlconf=None, urls_attr='urlpatterns'): | |
| if urlconf is None: | |
| urlconf = settings.ROOT_URLCONF | |
| if urlconf in sys.modules: | |
| reload(sys.modules[urlconf]) | |
| reloaded = import_module(urlconf) | |
| reloaded_urls = getattr(reloaded, urls_attr) | |
| set_urlconf(tuple(reloaded_urls)) |
I've been using a lot of Ansible lately and while almost everything has been great, finding a clean way to implement ansible-vault wasn't immediately apparent.
What I decided on was the following: put your secret information into a vars file, reference that vars file from your task, and encrypt the whole vars file using ansible-vault encrypt.
Let's use an example: You're writing an Ansible role and want to encrypt the spoiler for the movie Aliens.
| # Copyright (c) 2014 Andrey Vlasovskikh | |
| # | |
| # Permission is hereby granted, free of charge, to any person obtaining a copy | |
| # of this software and associated documentation files (the "Software"), to deal | |
| # in the Software without restriction, including without limitation the rights | |
| # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
| # copies of the Software, and to permit persons to whom the Software is | |
| # furnished to do so, subject to the following conditions: | |
| # | |
| # The above copyright notice and this permission notice shall be included in |