Skip to content

Instantly share code, notes, and snippets.

View coryjthompson's full-sized avatar

Cory Thompson coryjthompson

  • Sydney, Australia
View GitHub Profile
@coryjthompson
coryjthompson / Dockerfile
Created January 20, 2024 06:23
Issues and renews letsencrypt certificates within vault in format comptabile with Fabio.
FROM neilpang/acme.sh
RUN apk add jq bash
RUN wget https://releases.hashicorp.com/vault/1.3.2/vault_1.3.2_linux_amd64.zip && unzip vault_1.3.2_linux_amd64.zip -d /usr/local/bin/ && rm vault_1.3.2_linux_amd64.zip
ADD entrypoint.sh /entrypoint.sh
VOLUME /output
ENTRYPOINT ["/entrypoint.sh"]
@coryjthompson
coryjthompson / WebinarJam.php
Created January 20, 2016 17:19
Implements the WebinarJam API.
<?php
/**
* Class WebinarJam
* Implements the WebinarJam API as documented
* https://s3.amazonaws.com/webinarjam/files/WebinarJamAPI.pdf
*/
class WebinarJam {
public static $API_URL = 'https://app.webinarjam.com/api/v2/';
@coryjthompson
coryjthompson / 0.js
Created November 10, 2012 22:00
FileTransfer Progress with PhoneGap
var fileTransfer = new FileTransfer();
fileTransfer.onprogress = function(result){
var percent = result.loaded / result.total * 100;
percent = Math.round(percent);
console.log('Downloaded: ' + percent + '%');
};
fileTransfer.download(remoteFile, localPath, successCallback, errorCallback);