aggiunto script inserisci_ricicla

This commit is contained in:
scossa 2024-11-02 02:49:05 +01:00
parent 46f715dc61
commit 1f17f33ca3

View file

@ -1,6 +1,6 @@
#!/bin/bash #!/bin/bash
set -x #set -x
# Prendi credenziali db e tabella # Prendi credenziali db e tabella
DB_USER=$(jq -r '.db.user' ../server/config/default.json) DB_USER=$(jq -r '.db.user' ../server/config/default.json)
DB_PASS=$(jq -r '.db.password' ../server/config/default.json) DB_PASS=$(jq -r '.db.password' ../server/config/default.json)
@ -20,7 +20,7 @@ for i in "${coordinates[@]}"; do
# Genera dati ricicla # Genera dati ricicla
NAME='Ricicla' NAME='Ricicla'
DESCRIPTION='Alimenti quasi scaduti vicino ai cassoneti dei supermercati https://nel.computer/lefanze/book/153' DESCRIPTION='Alimenti quasi scaduti vicino ai cassoneti dei supermercati https://nel.computer/lefanze/book/153'
FILENAME='/var/www/html/leaflet/ruscomap/server/public/uploads/riciclaimg' FILENAME='riciclaimg'
COORDINATE="$i" COORDINATE="$i"
TS='2016-01-10 21:42:42' TS='2016-01-10 21:42:42'
@ -29,5 +29,4 @@ for i in "${coordinates[@]}"; do
# Esegue inserimento # Esegue inserimento
mysql -u "$DB_USER" -p"$DB_PASS" -D "$DB_NAME" -e "$SQL_COMMAND" mysql -u "$DB_USER" -p"$DB_PASS" -D "$DB_NAME" -e "$SQL_COMMAND"
done done