-
Notifications
You must be signed in to change notification settings - Fork 5
71 lines (59 loc) · 2.44 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
name: Python/Database CI
on:
push:
branches:
- master
pull_request:
branches:
- master
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
env:
NEO4J_SHA256: 6d9bb8e21a4b80f8edefff89d6fe592812ae26eaf105cbc967bce88b62290bfd
NEO4J_TARBALL: neo4j-community-4.2.5-unix.tar.gz
NEO4J_EDITION: community
NEO4J_HOME: /var/lib/neo4j
steps:
- uses: actions/checkout@v2
- name: Set up neo4j user
run: |
sudo addgroup --gid 7474 --system neo4j
sudo adduser --uid 7474 --system --no-create-home --home "${{ env.NEO4J_HOME }}" --ingroup neo4j neo4j
- name: Install prereqs
run: |
sudo apt update
sudo apt install -y curl wget gosu jq
# pick up here from https://github.com/neo4j/docker-neo4j-publish/blob/d22293f2e465b63ee5a63f0a2b8f817717a64a8b/4.2.5/community/Dockerfile
- name: Install Neo4j
run: |
curl --fail --silent --show-error --location --remote-name https://dist.neo4j.org/${{ env.NEO4J_TARBALL }}
echo "${{ env.NEO4J_SHA256 }} ${{ env.NEO4J_TARBALL }}" | sha256sum -c --strict --quiet
sudo tar --extract --file ${{ env.NEO4J_TARBALL }} --directory /var/lib
sudo mv /var/lib/neo4j-* ${{ env.NEO4J_HOME }}
sudo rm ${{ env.NEO4J_TARBALL }}
sudo mv ${{ env.NEO4J_HOME }}/data /data
sudo mv ${{ env.NEO4J_HOME }}/logs /logs
sudo chown -R neo4j:neo4j /data
sudo chmod -R 777 /data
sudo chown -R neo4j:neo4j /logs
sudo chmod -R 777 /logs
sudo chown -R neo4j:neo4j ${{ env.NEO4J_HOME }}
sudo chmod -R 777 ${{ env.NEO4J_HOME }}
sudo ln -s /data ${{ env.NEO4J_HOME }}/data
sudo ln -s /logs ${{ env.NEO4J_HOME }}/logs
# sudo mv /tmp/neo4jlabs-plugins.json /neo4jlabs-plugins.json
# ^ come back to this once the rest works...
- name: Add neo4j bin directory to PATH
run: echo ${{ env.NEO4J_HOME }}/bin:$PATH >> $GITHUB_PATH
- name: Check the PATH to make sure neo4j-admin is there
run: echo "$PATH"
- name: Set up conda with Python 3.7.5
uses: s-weigand/setup-conda@v1.0.5
with:
activate-conda: true
python-version: 3.7.5
conda-channels: anaconda, conda-forge
- name: install python package
run: yes | pip3 install .