diff options
author | kaotisk <kaotisk@arching-kaos.com> | 2021-12-18 07:50:49 +0200 |
---|---|---|
committer | kaotisk <kaotisk@arching-kaos.com> | 2021-12-18 07:50:49 +0200 |
commit | 0a101637c6e0c2528b9ea9eb02892da3d862c56c (patch) | |
tree | b95ab07e7c85f2eb88dee57c9f3959dbc0a72f68 /init.sh | |
parent | 288e24bcd9c1905bc46a5bc97247bc6c9f642634 (diff) | |
download | arching-kaos-tools-0a101637c6e0c2528b9ea9eb02892da3d862c56c.tar.gz arching-kaos-tools-0a101637c6e0c2528b9ea9eb02892da3d862c56c.tar.bz2 arching-kaos-tools-0a101637c6e0c2528b9ea9eb02892da3d862c56c.zip |
Changes
- lower case names in ipfs fs
- gpg2 to gpg since gpg is the binary on most distributions
- add 3 new folders to store references to ZBLOCKs, BLOCKS and DATA
Diffstat (limited to 'init.sh')
-rwxr-xr-x | init.sh | 15 |
1 files changed, 10 insertions, 5 deletions
@@ -5,22 +5,25 @@ echo "INIT started" if [[ ! -d $WORKDIR ]] ; then mkdir $WORKDIR ;fi if [[ ! -d $CONFIGDIR ]] ; then mkdir $CONFIGDIR ;fi if [[ ! -d $BINDIR ]]; then mkdir $BINDIR ;fi +if [[ ! -d $ZBLOCKDIR ]]; then mkdir $ZBLOCKDIR ;fi +if [[ ! -d $BLOCKDIR ]]; then mkdir $BLOCKDIR ;fi +if [[ ! -d $DATADIR ]]; then mkdir $DATADIR ;fi if [[ ! -d $ARCHIVESDIR ]]; then mkdir $ARCHIVESDIR ;fi if [[ ! -f $GENESIS ]] ; then touch $GENESIS;fi if [[ ! -f $ZGENESIS ]] ; then echo "$(ipfs add -q $GENESIS)" > $ZGENESIS;fi if [[ ! -f $ZCHAIN ]] ; then echo "$(ipfs key gen zchain)" > $ZCHAIN;fi if [[ ! -f $ZLATEST ]] ; then cp $ZGENESIS $ZLATEST;fi -if [[ ! -f $ZCHAINASC ]] ; then gpg2 -bao $ZCHAINASC $ZCHAIN;fi +if [[ ! -f $ZCHAINASC ]] ; then gpg -bao $ZCHAINASC $ZCHAIN;fi if [[ ! -f $ZZCHAIN ]] ; then echo $(ipfs add -q $ZCHAINASC) > $ZZCHAIN;fi -if [[ ! -f $GENESISASC ]] ; then gpg2 -bao $GENESISASC $GENESIS;fi +if [[ ! -f $GENESISASC ]] ; then gpg -bao $GENESISASC $GENESIS;fi if [[ ! -f $ZGENESISASC ]] ; then echo $(ipfs add -q $GENESISASC) > $ZGENESISASC;fi ipfs files ls /zarchive > /dev/null 2>&1 if [ $? != 0 ]; then ipfs files mkdir /zarchive fi -ipfs files stat /ZLATEST > /dev/null 2>&1 +ipfs files stat /zlatest > /dev/null 2>&1 if [ $? != 0 ]; then - ipfs files cp /ipfs/$(cat $ZGENESIS) /ZLATEST + ipfs files cp /ipfs/$(cat $ZGENESIS) /zlatest fi # TODO GPG/PGP setup @@ -33,4 +36,6 @@ fi # TODO The thing is done, we are sitting on a genesis. # We also have an IPNS name to use. - +if [[ ! -f $BINDIR/json2bash ]] ; then cp json2bash $BINDIR ;fi +if [[ ! -f $BINDIR/ipfs-starter ]] ; then cp ipfs-starter $BINDIR ;fi +if [[ ! -f $BINDIR/pack_z_block ]] ; then cp pack_z_block $BINDIR ;fi |