1
0
mirror of https://github.com/rlister/dockerfiles.git synced 2025-12-11 00:36:27 +00:00

rename script and add ghcat

This commit is contained in:
Richard Lister
2015-02-09 14:14:23 -05:00
parent b37f5747b0
commit e581ed66c8
3 changed files with 15 additions and 3 deletions

View File

@@ -4,7 +4,9 @@ MAINTAINER Ric Lister, rlister@gmail.com
WORKDIR /app
ADD ghcp.sh /app/
RUN chmod 0755 ghcp.sh
ADD ghcp /app/
RUN chmod 0755 ghcp
ADD ghcat /app/
RUN chmod 0755 ghcat
ENTRYPOINT [ "/app/ghcp.sh" ]
ENTRYPOINT [ "/app/ghcp" ]

10
github-copy/ghcat Normal file
View File

@@ -0,0 +1,10 @@
#!/bin/sh
## simply cat all remote files to stdout
for src in $*
do
/usr/bin/curl -sL \
-H "Authorization: token $TOKEN" \
-H 'Accept: application/vnd.github.v3.raw' \
"https://api.github.com/repos/${REPO}/contents/${src}"
done