- プロセス間で通信を行う仕組み
- シグナルを受け取ったプロセスは実行中の処理を中断
- シグナルの種類に適した処理を行う
- 割り込みっぽい。
- 処理を中断したり、場合によってはそのあと処理を再開する
- シグナルの役割
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
import json | |
import requests | |
url = "https://qiita.com/api/v2/items" | |
params = { | |
'per_page': 20, | |
'query': 'python' | |
} |
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
[Unit] | |
Description=Consul service discovery agent | |
Requires=network-online.target | |
After=network.target | |
[Service] | |
User=consul | |
Group=consul | |
PIDFile=/run/consul/consul.pid | |
Restart=on-failure |
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
# -*- coding: utf-8 -*- | |
import hashlib | |
import hmac | |
import base64 | |
import requests | |
from datetime import datetime | |
ACCESS_KEY = u'12345678901234567890' | |
SECRET_KEY = u'1234567890abcdefghijklmnopqrstuvwxyzABCD' |