add ubuntu key
This commit is contained in:
parent
c3fc3ade47
commit
5654476508
9
sync.run
9
sync.run
@ -21,12 +21,16 @@ sleep 1 # prevent cpu spike on looping
|
|||||||
|
|
||||||
export MIRROR_DIR=/var/lib/ubuntumirror
|
export MIRROR_DIR=/var/lib/ubuntumirror
|
||||||
export IPFS_PATH=/var/lib/ipfs
|
export IPFS_PATH=/var/lib/ipfs
|
||||||
|
export KEYID=790BC7277767219C42C86F933B4FE6ACC0B21F32
|
||||||
|
|
||||||
export GNUPGHOME=/etc/debmirror/ubuntu
|
export GNUPGHOME=/etc/debmirror/ubuntu
|
||||||
mkdir -p $GNUPGHOME
|
mkdir -p $GNUPGHOME
|
||||||
chmod go-rwx $GNUPGHOME
|
chmod go-rwx $GNUPGHOME
|
||||||
|
|
||||||
gpg --import /usr/share/keyrings/ubuntu-archive-keyring.gpg
|
gpg --import /usr/share/keyrings/ubuntu-archive-keyring.gpg
|
||||||
cp $GNUPGHOME/pubring.gpg $GNUPGHOME/trustedkeys.gpg
|
|
||||||
|
gpg --recv-key $KEYID
|
||||||
|
gpg --export $KEYID > $GNUPGHOME/trustedkeys.kbx
|
||||||
|
|
||||||
chown -R ipfs:ipfs $GNUPGHOME
|
chown -R ipfs:ipfs $GNUPGHOME
|
||||||
|
|
||||||
@ -63,8 +67,7 @@ debmirror \
|
|||||||
# https://github.com/ipfs/go-ipfs/issues/3397#issuecomment-284337564
|
# https://github.com/ipfs/go-ipfs/issues/3397#issuecomment-284337564
|
||||||
|
|
||||||
echo "Adding the mirror files to IPFS."
|
echo "Adding the mirror files to IPFS."
|
||||||
hash="$($IPFS add --progress --local --nocopy --fscache --quieter
|
hash="$($IPFS add --progress --local --nocopy --fscache --quieter --recursive "$MIRROR_DIR" | tail -n1)"
|
||||||
--recursive "$MIRROR_DIR" | tail -n1)"
|
|
||||||
echo "Published IPFS hash ${hash}."
|
echo "Published IPFS hash ${hash}."
|
||||||
|
|
||||||
echo "Updating IPNS."
|
echo "Updating IPNS."
|
||||||
|
Loading…
Reference in New Issue
Block a user