This commit is contained in:
Jeffrey Paul 2017-01-09 10:46:19 +01:00
parent 655026cdbd
commit 1ba0219bd7
7 changed files with 70 additions and 50 deletions

View File

@ -10,7 +10,8 @@ clean:
deploy: pinlist.txt deploy: pinlist.txt
mkdir -p $(PINLIST_DIR) mkdir -p $(PINLIST_DIR)
rsync -avP ./pinlist.txt $(PINLIST_DIR)/pinlist.txt cat ./pinlist.txt > $(PINLIST_DIR)/pinlist.txt
cat ./bin/pin.sh > $(PINLIST_DIR)/pin.sh
ipfs add -r $(IPFS_ROOT) | \ ipfs add -r $(IPFS_ROOT) | \
tail -1 | \ tail -1 | \
awk -F' ' '{print $$2}' | \ awk -F' ' '{print $$2}' | \
@ -18,5 +19,13 @@ deploy: pinlist.txt
pinlist.txt: pins/*.json pinlist.txt: pins/*.json
jq -r .pins[] $^ > pinlist.new && mv pinlist.new $@ jq -r .pins[] $^ > pinlist.new && mv pinlist.new $@.tmp
echo "# $$(date -u +%s)" >> $@ echo "# timestamp=$$(date -u +%s)" >> $@.tmp
cat $@.tmp | sort | uniq > $@
rm $@.tmp
tidy:
for X in pins/*.json ; do \
echo $$X ; \
jq -S --indent 4 . $$X > $$X.new && mv $$X.new $$X ; \
done

View File

@ -5,7 +5,7 @@
}, },
"description": "test name from ber1 (sneak fileserver)", "description": "test name from ber1 (sneak fileserver)",
"pins": [ "pins": [
"/ipns/QmZKpS7iyUnDXcUxhou5arokZ5bZViZokEzDVAEGctBSMw" "/ipns/QmZKpS7iyUnDXcUxhou5arokZ5bZViZokEzDVAEGctBSMw/helloworld"
], ],
"url": "https://sneak.berlin" "url": "https://sneak.berlin"
} }

View File

@ -0,0 +1,11 @@
{
"contact": {
"email": "sneak@sneak.berlin",
"name": "Jeffrey Paul"
},
"description": "ubuntu trusty and xenial apt metadata mirror (<200MiB)",
"pins": [
"/ipns/QmZKpS7iyUnDXcUxhou5arokZ5bZViZokEzDVAEGctBSMw/mirrors/ubuntu/current/dists"
],
"url": "https://sneak.berlin/"
}