vi /etc/hosts
192.168.10.157 rabbitmq-1
192.168.10.159 rabbitmq-2
192.168.10.161 rabbitmq-3
This file contains hidden or 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
| <NotepadPlus> | |
| <UserLang name="Groovy" ext="groovy" udlVersion="2.1"> | |
| <Settings> | |
| <Global caseIgnored="no" /> | |
| <Prefix Keywords1="no" Keywords2="no" Keywords3="no" Keywords4="no" /> | |
| </Settings> | |
| <KeywordLists> | |
| <Keywords name="Comments">03/* 04*/ 00// 01 02</Keywords> | |
| <Keywords name="Keywords1">abstract break case catch continue default do else extends final finally for if implements instanceof native new private protected public return static switch synchronized throw throws transient try volatile while strictfp package import false null super this true</Keywords> | |
| <Keywords name="Keywords2">as assert def mixin property test using in it</Keywords> |
This file contains hidden or 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 | |
| # | |
| # Simple script to generate a basic bind configuration for home/lab use | |
| # | |
| # Local config - adjust as required | |
| OWNIP=192.168.111.3 | |
| NETWORK=192.168.111.0 | |
| NETMASK=/24 | |
| DNS1=192.168.111.1 |
This file contains hidden or 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
| # User authentication method. Could be set multiple times and in | |
| # that case all should succeed. To enable multiple methods use | |
| # multiple auth directives. Available options: certificate, certificate[optional], | |
| # plain, pam. | |
| #auth = "certificate" | |
| #auth = "plain[./ocserv-passwd]" | |
| #auth = "pam" | |
| # This indicates that a user may present a certificate. When that option | |
| # is set, individual users or user groups can be forced to present a valid |
(https://github.com/sandino/Markdown-Cheatsheet) (перевод, оригинал)
Поиграть с разметкой Markdown можно на демо-странице.
This file contains hidden or 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 | |
| name=$RANDOM | |
| url='http://localhost:9093/api/v1/alerts' | |
| echo "firing up alert $name" | |
| # change url o | |
| curl -XPOST $url -d "[{ | |
| \"status\": \"firing\", |
This file contains hidden or 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
| # Stop all containers | |
| docker stop `docker ps -qa` | |
| # Remove all containers | |
| docker rm `docker ps -qa` | |
| # Remove all images | |
| docker rmi -f `docker images -qa ` | |
| # Remove all volumes |
This file contains hidden or 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
| Инициализировать новый репозиторий: | |
| 1 | |
| git init rep-name | |
| Клонировать репозиторий с удаленного сервера: | |
| 1 | |
| git clone [email protected]:afiskon/hs-textgen.git | |
| Добавить в репозиторий файл: | |
| 1 | |
| git add file.txt | |
| Удалить файл из репозитория: |
The *.txt files here hold user and database parameters. Specifically, replication.txt contains the user/role and password to use for replication. Whereas database.txt contains an initial database, user/role and password to create on the master.
Run the master:
$ fig run -d master
Wait for it to start up completely. Start the slave:
mainly used in start-up script
When we play with iptables aka firewall we might end up in situation, where we execute rule, which has unforseen impact - lock yourself out. Recovering from this situation is necessity.
How to:
- Enable reboot via SMS.
- Test all commands in shell first before putting them into Start-up script. This way the command will be wiped out, when unit is rebooted.
NewerOlder