Update README.md #207
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Petagraph Build Tests | |
on: [push] | |
jobs: | |
job_1: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python 3.10 | |
uses: actions/setup-python@v3 | |
with: | |
python-version: '3.10' | |
- name: ports | |
run: sudo netstat -tulpn | grep LISTEN | |
- name: Download Neo4j | |
run: | | |
curl -fsSL https://debian.neo4j.com/neotechnology.gpg.key |sudo gpg --dearmor -o /usr/share/keyrings/neo4j.gpg | |
echo "deb [signed-by=/usr/share/keyrings/neo4j.gpg] https://debian.neo4j.com stable 4.1" | sudo tee -a /etc/apt/sources.list.d/neo4j.list | |
sudo apt update | |
sudo apt install neo4j | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements-tests.txt | |
- name: Download OSF files #osf -p 6jtc9 fetch Datasets/Datasets.zip Datasets.zip; unzip Datasets.zip; | |
run: | | |
echo 'Downloading OSF data...'; | |
# osf -p 6jtc9 fetch Datasets/Petagraph_datasets.zip Petagraph_datasets.zip; | |
# unzip Petagraph_datasets.zip; rm Petagraph_datasets.zip; | |
# osf -p 6jtc9 fetch reduced_csvs_github_actions.zip reduced_csvs_github_actions.zip; | |
# unzip reduced_csvs_github_actions.zip; rm reduced_csvs_github_actions.zip; | |
# echo 'Finished Downloading and unzipping....'; | |
ls data; | |
- name: chmod | |
run: | | |
sudo chmod 777 -R /var/lib/neo4j/; sudo chmod 777 -R /etc/neo4j; | |
sudo chmod 777 -R /var/lib/neo4j/data; | |
sudo chmod 777 -R /var/log/neo4j/; sudo chmod 777 -R /var/run/neo4j | |
- name: Build Petagraph | |
run: | | |
# mv reduced_csvs_github_actions/C*.csv /var/lib/neo4j/import/; | |
rm -rf /var/lib/neo4j/data/databases/* | |
rm -rf /var/lib/neo4j/data/transactions/* | |
cd /var/lib/neo4j/ | |
export HEAP_SIZE=1G; echo heapsize set to: $HEAP_SIZE; # --relationships="import/CUI-CUIs.csv" | |
# neo4j-admin import --verbose --nodes=Concept="import/CUIs.csv" --nodes=Code="import/CODEs.csv" --relationships=CODE="import/CUI-CODEs.csv" --skip-bad-relationships --skip-duplicate-nodes | |
- name: sed Unauth | |
run: | | |
#sed -i '/dbms.security.auth_enabled=false/s/^#//g' /etc/neo4j/neo4j.conf | |
#sed -i '/dbms.connector.bolt.listen_address=:7687/s/^#//g' /etc/neo4j/neo4j.conf | |
#sed -i '/dbms.connector.bolt.advertised_address=:7687/s/^#//g' /etc/neo4j/neo4j.conf | |
sed -i '/dbms.default_listen_address=0.0.0.0/s/^#//g' /etc/neo4j/neo4j.conf | |
#sed -i '/dbms.default_advertised_address=localhost/s/^#//g' /etc/neo4j/neo4j.conf | |
#sed -i '/dbms.connector.bolt.enabled=true/c\dbms.connector.bolt.enabled=false' /etc/neo4j/neo4j.conf | |
#sed -i '/dbms.connector.http.listen_address=:7474/s/^#//g' /etc/neo4j/neo4j.conf | |
#sed -i '/dbms.connector.http.advertised_address=:7474/s/^#//g' /etc/neo4j/neo4j.conf | |
cat /etc/neo4j/neo4j.conf | |
echo '----------' | |
#sudo rm /var/lib/neo4j/data/dbms/aut*; | |
ls /var/lib/neo4j/data/dbms | |
- run: sudo ss -tulpn #sudo netstat -tulpn | grep LISTEN | |
- run: hostname -i; ulimit -n 40000 | |
- name: Run Tests | |
run: | | |
neo4j-admin set-initial-password neo4j2020 | |
sudo neo4j start; sleep 20; | |
sudo ss -tulpn #sudo netstat -tulpn | grep LISTEN; | |
echo '---------------' | |
- run: | | |
#/usr/bin/cypher-shell -a bolt://localhost:7687 -u neo4j -p neo4j; | |
#/usr/bin/cypher-shell "ALTER CURRENT USER SET PASSWORD FROM neo4j TO neo4j2020"; | |
#/usr/bin/cypher-shell "MATCH (n) RETURN COUNT(n)"; | |
- run: | | |
echo ''; #python tests/Petagraph_ingestion_test_auto.py #sudo /usr/bin/cypher-shell -a localhost -u neo4j -p neo4j; | |
#- name: Upload Artifact | |
# uses: actions/upload-artifact@v3 | |
# with: | |
# name: QC Report | |
# path: .github/graph_test_logs/logfile.txt | |