# Delete all containers
docker rm $(docker ps -aq)
# Delete all images
docker rmi $(docker images -q)
# Delete all untagged images
docker rmi $(docker images -q --filter "dangling=true")References:
| version: "3.3" | |
| services: | |
| mongo: | |
| image: mongo:4.1.1 | |
| restart: on-failure | |
| command: --wiredTigerCacheSizeGB 3 | |
| ports: | |
| # Charts db is available under port 27018 to not block the default mongo port | |
| - "8082:8081" |
| #!/bin/sh | |
| set -e | |
| HOST=localhost | |
| DB=test-entd-products | |
| COL=asimproducts | |
| S3PATH="s3://mongodb-backups-test1-entd/$DB/$COL/" | |
| S3BACKUP=$S3PATH`date +"%Y%m%d_%H%M%S"`.dump.gz | |
| S3LATEST=$S3PATH"latest".dump.gz | |
| /usr/bin/aws s3 mb $S3PATH |
# Delete all containers
docker rm $(docker ps -aq)
# Delete all images
docker rmi $(docker images -q)
# Delete all untagged images
docker rmi $(docker images -q --filter "dangling=true")References:
| from botocore.credentials import RefreshableCredentials | |
| from botocore.session import get_session | |
| from boto3 import Session | |
| def assumed_session(role_arn, session_name, session=None): | |
| """STS Role assume a boto3.Session | |
| With automatic credential renewal. |
| #!/usr/bin/python | |
| import os | |
| import sys | |
| import requests | |
| import json | |
| api_base = 'https://api.digitalocean.com/v2' |
| /* # OFFICIAL GITHUB BRAND COLORS | |
| -------------------------------------------------------------------- | |
| Official Github Brand Colors (August 20, 2015) from the | |
| GitHub internal CSS framework (Primer) version 2.3.3 | |
| Source URI: http://primercss.io/colors/ | |
| 1.a = Github Branding Color Swatches | |
| -------------------------------------------------------------------- */ | |
| .swatch-github-blue { | |
| background-color:#4078c0; |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
Other people's projects:
My projects (tutorials are on my blog at http://maxoffsky.com):