- Clean pkg cache
- Remove unused packages (orphans)
- Clean cache in /home
- remove old config files
- Find and Remove
- duplicates
- empty files
- empty directories
- broken symlinks
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 rest_framework.serializers | |
| import graphql.execution.executor | |
| from django.db.models import Model | |
| from graphene.utils import str_converters | |
| from functools import lru_cache | |
| @lru_cache(maxsize=None) |
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
| package auth | |
| import ( | |
| "context" | |
| "net/http" | |
| "strings" | |
| "google.golang.org/grpc/metadata" | |
| "github.com/andela/micro-api-gateway/pb/authorization" |
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
| mapboxgl.accessToken = 'pk.eyJ1IjoibW91cm5lciIsImEiOiJWWnRiWG1VIn0.j6eccFHpE3Q04XPLI7JxbA'; | |
| console.log('Version: ' + mapboxgl.version); | |
| const container = document.createElement('div'); | |
| container.style.width = '1200px'; | |
| container.style.height = '700px'; | |
| document.body.appendChild(container); |
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
| #!/usr/bin/env python | |
| import boto | |
| import sys, os | |
| from boto.s3.key import Key | |
| from boto.exception import S3ResponseError | |
| DOWNLOAD_LOCATION_PATH = os.path.expanduser("~") + "/s3-backup/" | |
| if not os.path.exists(DOWNLOAD_LOCATION_PATH): |
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 time | |
| from http.server import BaseHTTPRequestHandler, HTTPServer | |
| HOST_NAME = 'localhost' | |
| PORT_NUMBER = 9000 | |
| class MyHandler(BaseHTTPRequestHandler): | |
| def do_HEAD(self): | |
| self.send_response(200) |
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
| ssh-keygen -t rsa -b 4096 -m PEM -f jwtRS256.key | |
| # Don't add passphrase | |
| openssl rsa -in jwtRS256.key -pubout -outform PEM -out jwtRS256.key.pub | |
| cat jwtRS256.key | |
| cat jwtRS256.key.pub |
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
| # Extremely basic development setup to serve the current directory at http://localhost:9001 | |
| # Start nginx in this directory with `nginx -p . -c nginx.conf` | |
| # Stop nginx with `nginx -p . -s stop` | |
| events {} | |
| http { | |
| # Serve files with correct mimetypes on OSX | |
| # location may have to be adjusted depending on your OS and nginx install | |
| include /usr/local/etc/nginx/mime.types; |
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
| #!/usr/bin/env python | |
| # Compare a file on S3 to see if we have the latest version | |
| # If not, upload it and invalidate CloudFront | |
| import fnmatch | |
| import os | |
| import boto | |
| import pprint | |
| import re |
NewerOlder