Friday, December 21, 2018

Github: retrieve individual files from Github in a Dockerfile

1
2
3
4
5
6
7
FROM alpine:edge
 
ARG githubtoken=1852...
 
RUN apk add --no-cache curl wget
 
RUN curl -o /var/mbqt/lib/MBQT/Bootstrap.pm -H "Authorization: token $githubtoken" -H 'Accept: application/vnd.github.v3.raw' -L https://api.github.com/repos/<org>/<repo>/contents/perl/lib/MBQT/Bootstrap.pm</repo></org>