The instructions on Cloudflare's website are confusing and incomplete.
-
Install cloudflared:
brew install cloudflare/cloudflare/cloudflared -
Create the configuration file:
The instructions on Cloudflare's website are confusing and incomplete.
Install cloudflared:
brew install cloudflare/cloudflare/cloudflared
Create the configuration file:
I hereby claim:
To claim this, I am signing this object:
| { | |
| "Version": "2012-10-17", | |
| "Statement": [ | |
| { | |
| "Effect": "Allow", | |
| "Principal": "*", | |
| "Action": "execute-api:Invoke", | |
| "Resource": "arn:aws:execute-api:{REGION}:{ACCOUNT_ID}:{API_NAME}/*" | |
| }, | |
| { |
| { | |
| "Version": "2012-10-17", | |
| "Statement": [ | |
| { | |
| "Effect": "Allow", | |
| "Principal": "*", | |
| "Action": "execute-api:Invoke", | |
| "Resource": "arn:aws:execute-api:{REGION}:{ACCOUNT_ID}:{API_NAME}/*" | |
| }, | |
| { |
| #!/usr/bin/env python3.6 | |
| import os | |
| import sys | |
| from hashlib import md5 | |
| from argparse import ArgumentParser | |
| parser = ArgumentParser(description='Compare an S3 etag to a local file') | |
| parser.add_argument('inputfile', help='The local file') | |
| parser.add_argument('etag', help='The etag from s3') | |
| args = parser.parse_args() |
| partsizes = [ ## Default Partsizes Map (bytes) | |
| 8388608, # aws_cli/boto3 | |
| 15728640, # s3cmd | |
| factor_of_1MB(filesize, num_parts) # Used by many clients to upload large files | |
| ] |
| def calc_etag(inputfile, partsize): | |
| md5_digests = [] | |
| with open(inputfile, 'rb') as f: | |
| for chunk in iter(lambda: f.read(partsize), b''): | |
| md5_digests.append(md5(chunk).digest()) | |
| return md5(b''.join(md5_digests)).hexdigest() + '-' + str(len(md5_digests)) |
| #!/bin/bash | |
| ## | |
| ## Statically Compile SSH | |
| ## See https://github.com/andrew-d/static-binaries for more binaries | |
| ## | |
| set -e | |
| set -o pipefail | |
| set -x |