Create a new repository, or reuse an existing one.
Generate a new SSH key:
ssh-keygen -t rsa -C "your_email@example.com"
Copy the contents of the file ~/.ssh/id_rsa.pub to your SSH keys in your GitHub account settings.
Test SSH key:
| # Creating an empty dictionary | |
| data = {} | |
| # OR | |
| data = dict() | |
| # Creating a dictionary with initial values | |
| data = {'a':1,'b':2,'c':3} | |
| # OR | |
| data = dict(a=1, b=2, c=3) |
| yum install zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel | |
| readline-devel tk-devel gdbm-devel db4-devel libpcap-devel xz-devel |
| DELETE TAG FROM REGISTRY | |
| See: https://github.com/docker/distribution/blob/master/docs/spec/api.md#deleting-an-image | |
| Working usage: https://github.com/byrnedo/docker-reg-tool | |
| Stackoverflow: https://stackoverflow.com/questions/25436742/how-to-delete-images-from-a-private-docker-registry | |
Create a new repository, or reuse an existing one.
Generate a new SSH key:
ssh-keygen -t rsa -C "your_email@example.com"
Copy the contents of the file ~/.ssh/id_rsa.pub to your SSH keys in your GitHub account settings.
Test SSH key:
| Here is a working example via aws-cli and jq. | |
| Preparation | |
| Create S3 bucket: | |
| aws s3 mb s3://wei20181202s3 | |
| make_bucket: wei20181202s3 | |
| Create SNS topic: | |
| aws sns create-topic --name wei20181202sns | |
| { |
git-credential-cache is a useful tool to remember your HTTP/HTTPS git credentials (though you really should be using SSH instead). It’s useful when using long passwords or access tokens. It stores them in memory for a specific amount of time.
$ git config --global credential.helper cache
$ git config --global credential.helper 'cache --timeout=600'
$ git config --global --unset credential.helper
| proxy_cache_path /tmp/cacheapi levels=1:2 keys_zone=microcacheapi:100m max_size=1g inactive=1d use_temp_path=off; | |
| server { | |
| listen 443 ssl http2 default_server; | |
| listen [::]:443 ssl http2 default_server; | |
| server_name example.com; | |
| location /api/ { | |
| # Rate Limiting | |
| limit_req zone=reqlimit burst=20; # Max burst of request |