Correct gpg tty on su/sudo
This commit is contained in:
parent
1ebd39d510
commit
6c7050888f
12
setup.sh
12
setup.sh
@ -5,6 +5,7 @@ want_cicada_version=0.0.1a7
|
||||
want_evm=bloxberg
|
||||
|
||||
. aux/bdbg/bdbg.sh
|
||||
|
||||
_level=2
|
||||
_debug=1
|
||||
|
||||
@ -20,8 +21,7 @@ if [ "$UID" -eq 0 ]; then
|
||||
fi
|
||||
|
||||
. setup_check.sh
|
||||
|
||||
|
||||
. setup_path.sh
|
||||
|
||||
dbg $dbg_debug "importing keys"
|
||||
for f in ./keys/*.asc; do
|
||||
@ -118,8 +118,7 @@ if [ $update -gt 0 ]; then
|
||||
debug_flag="-v"
|
||||
fi
|
||||
pip install --index-url $PIP_INDEX_URL --extra-index-url $PIP_EXTRA_INDEX_URL $PIP_EXTRA_ARGS $debug_flag -r requirements.txt
|
||||
|
||||
dbg $dbg_debug "executing database migrations"
|
||||
update_path $HOME/.local/bin
|
||||
fi
|
||||
|
||||
|
||||
@ -163,11 +162,8 @@ dbg $dbg_debug "execute database migrations"
|
||||
|
||||
mkdir -vp $HOME/.local/share/cic/cache
|
||||
|
||||
python ../cic-internal-integration/apps/cic-cache/scripts/migrate.py -c /home/lash/.config/cic/cache/
|
||||
python ../cic-internal-integration/apps/cic-cache/scripts/migrate.py -c $HOME/.config/cic/cache/
|
||||
|
||||
if [ ! -z $want_evm ]; then
|
||||
. setup_${want_evm}.sh
|
||||
fi
|
||||
|
||||
|
||||
|
||||
|
@ -27,21 +27,7 @@ if [ ! -d $OPENETHEREUM_RUN ]; then
|
||||
chmod 400 $OPENETHEREUM_RUN/bootnode.pwd
|
||||
fi
|
||||
|
||||
_IFS=$IFS
|
||||
IFS=:
|
||||
read -rapaths <<< "$PATH"
|
||||
matchpath=
|
||||
for f in ${paths[@]}; do
|
||||
if [ "$f" == "$openethereum_dir" ]; then
|
||||
matchpath=1
|
||||
fi
|
||||
done
|
||||
|
||||
if [ -z "$matchpath" ]; then
|
||||
dbg dbg_info "Adding bloxberg executable path $openethereum_dir to \$PATH"
|
||||
export PATH=$PATH:$openethereum_dir
|
||||
echo "export PATH=\$PATH:$openethereum_dir" >> $HOME/.bashrc
|
||||
fi
|
||||
update_path $openethereum_dir
|
||||
|
||||
if [ ! -z "$install_env" ]; then
|
||||
popd
|
||||
|
@ -1,3 +1,5 @@
|
||||
export GPG_TTY=$(tty)
|
||||
|
||||
echo You have not selected a key to use. We will now make a new one.
|
||||
echo The personal details you provide below will not be shared anywhere without getting your permission first.
|
||||
|
||||
@ -42,6 +44,6 @@ mkdir -vp $HOME/.config/cic/staff-client/.gnupg
|
||||
chmod 0700 -v $HOME/.config/cic/staff-client/.gnupg
|
||||
|
||||
gpg --homedir $t --export-secret-keys | gpg --homedir $HOME/.config/cic/staff-client/.gnupg --import
|
||||
#gpg --homedir $HOME/.config/cic/staff-client/.gnupg --export -a > $HOME/.config/cic/staff-client/user.asc
|
||||
gpg --homedir $HOME/.config/cic/staff-client/.gnupg --export -a > $HOME/.config/cic/staff-client/user.asc
|
||||
|
||||
gpg --list-packets $HOME/.config/cic/staff-client/user.asc | awk '/issuer fpr/ { print $9; }' | cut -b -40 > $HOME/.config/cic/staff-client/key_fingerprint
|
||||
|
18
setup_path.sh
Normal file
18
setup_path.sh
Normal file
@ -0,0 +1,18 @@
|
||||
function update_path {
|
||||
pathdir=$1
|
||||
_IFS=$IFS
|
||||
IFS=:
|
||||
read -rapaths <<< "$PATH"
|
||||
matchpath=
|
||||
for f in ${paths[@]}; do
|
||||
if [ "$f" == "$pathdir" ]; then
|
||||
matchpath=1
|
||||
fi
|
||||
done
|
||||
if [ -z "$matchpath" ]; then
|
||||
dbg dbg_info "Adding executable path $pathdir to \$PATH"
|
||||
export PATH=$PATH:$pathdir
|
||||
echo "export PATH=\$PATH:$pathdir" >> $HOME/.bashrc
|
||||
fi
|
||||
IFS=$_IFS
|
||||
}
|
@ -3,10 +3,6 @@ Description=CIC transaction cache syncer
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Environment="RPC_PROVIDER=http://localhost:8545"
|
||||
Environment="CHAIN_SPEC=evm:byzantium:8995:bloxberg"
|
||||
Environment="CIC_REGISTRY=ADDRESS={{CIC_REGISTRY_ADDRESS}}"
|
||||
Environment="CIC_TRUST_ADDRESS={{CIC_TRUST_ADDRESS}}"
|
||||
ExecStart="cic-cache-trackerd -c %h/.config/cic/cache"
|
||||
Restart=always
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user