Skip to content

Instantly share code, notes, and snippets.

View egoldblum's full-sized avatar

Ethan Goldblum egoldblum

View GitHub Profile
@egoldblum
egoldblum / cloudflare.md
Created October 27, 2015 01:39
Weird Cloudflare TLS SANs
$ openssl s_client  -connect cdnjs.com:443 2>/dev/null | openssl x509  -noout -text  | grep DNS
DNS:ssl255262.cloudflaressl.com, DNS:*.69.co.za, DNS:*.aginmotion.ca, DNS:*.al-aqsa.org, DNS:*.anolon.com, DNS:*.assisted.by, DNS:*.athleteally.org, DNS:*.bentbristle.com, DNS:*.bownty.co.uk, DNS:*.bowntycdn.net, DNS:*.buyafakediploma.com, DNS:*.cdnjs.com, DNS:*.centralcash.net, DNS:*.contractors4you.com, DNS:*.dealsof.us, DNS:*.farmforum.ca, DNS:*.glacieragweb.com, DNS:*.iconlasik.com, DNS:*.iqmatics.com, DNS:*.lba-floral.com, DNS:*.miqromoney.com, DNS:*.pcplanet.com, DNS:*.riknews.com.cy, DNS:*.sahunting.co.za, DNS:*.shophalfmoon.com, DNS:*.silverstone.com, DNS:*.teachandexplore.com, DNS:*.techumor.com.br, DNS:*.top10sextoys.co.za, DNS:*.woon-ro.com, DNS:69.co.za, DNS:aginmotion.ca, DNS:al-aqsa.org, DNS:anolon.com, DNS:assisted.by, DNS:athleteally.org, DNS:bentbristle.com, DNS:bownty.co.uk, DNS:bowntycdn.net, DNS:buyafakediploma.com, DNS:cdnjs.com, DNS:centralcash.net, DNS:contractors4you.com, DNS:dealsof.us,

We want to use pdftk, a binary cli program to generate PDF files. https://www.pdflabs.com/tools/pdftk-server/

We don't have access to apt-get at runtime on Modulus, so we can't just apt-get install pdftk. So, can we compile from source and build a binary that we can ship alongside the meteor source code?

To avoid weird toolchain/cross-compilation issues, let's do the build in the same environment as it will run. Handily modulus supplies the DOCKERFILEs for the images we run inside of:

alias full move screenOriginX;screenOriginY screenSizeX;screenSizeY
alias full move screenOriginX;screenOriginY screenSizeX;screenSizeY
alias lefthalf move screenOriginX;screenOriginY screenSizeX/2;screenSizeY
alias righthalf move screenOriginX+screenSizeX/2;screenOriginY screenSizeX/2;screenSizeY
alias topleft corner top-left resize:screenSizeX/2;screenSizeY/2
alias topright corner top-right resize:screenSizeX/2;screenSizeY/2
alias bottomleft corner bottom-left resize:screenSizeX/2;screenSizeY/2
alias bottomright corner bottom-right resize:screenSizeX/2;screenSizeY/2
bind return:shift;cmd ${full}
alias full move screenOriginX;screenOriginY screenSizeX;screenSizeY
alias full move screenOriginX;screenOriginY screenSizeX;screenSizeY
alias lefthalf move screenOriginX;screenOriginY screenSizeX/2;screenSizeY
alias righthalf move screenOriginX+screenSizeX/2;screenOriginY screenSizeX/2;screenSizeY
alias topleft corner top-left resize:screenSizeX/2;screenSizeY/2
alias topright corner top-right resize:screenSizeX/2;screenSizeY/2
alias bottomleft corner bottom-left resize:screenSizeX/2;screenSizeY/2
alias bottomright corner bottom-right resize:screenSizeX/2;screenSizeY/2
bind return:shift;cmd ${full}
{
"options": [
{
"dest": null,
"predicate": [
"abi"
]
},
{
"dest": "channels",
{
"influencers": {
"node": {
...
},
"edges": {
"default": {
"dest": "channels"
},
"options": [
{
"influencers": {
"node": {
"resourcePath": "/li/v2/onboard/influencers",
"logo": "influencer",
"title": "Get insights from the world's top minds",
"subtitle": "Follow LinkedIn Influencers to hear what industry leaders have to say.",
"type": "influencers",
"submitToastText": "Following",
"postResourcePath": "/li/v2/onboard/influencers"
{
"root": {
"default": {
"dest": "pymk",
"pathLength": 4
},
"options": [
{
"dest": "m2m",
"predicate": [
{
"root": {
"default": {
"dest": "pymk",
"pathLength": 4
},
"options": [{
"dest": "m2m",
"predicate": [
"abi"