mirror of
https://github.com/vimagick/dockerfiles.git
synced 2024-12-23 01:39:27 +02:00
16 lines
330 B
Bash
16 lines
330 B
Bash
|
#!/bin/bash
|
||
|
|
||
|
cd "$(dirname "${BASH_SOURCE[0]}")"
|
||
|
|
||
|
FILE=$(date -d yesterday +%F).csv.gz
|
||
|
SRC_FILE=/data/dns/data/$FILE
|
||
|
DST_FILE=/path/to/dns.csv.gz
|
||
|
|
||
|
echo "$(date +%FT%T) GET $FILE"
|
||
|
scp elk-us:$SRC_FILE $DST_FILE
|
||
|
|
||
|
echo "$(date +%FT%T) LOAD CSV"
|
||
|
docker exec -i memgraph_memgraph_1 mgconsole < load-csv.cql
|
||
|
|
||
|
echo "$(date +%FT%T) DONE"
|