From b07090d82125b294f3e5ecbcb2819200bf0b806c Mon Sep 17 00:00:00 2001 From: Gagan Deep Date: Thu, 31 Aug 2023 17:08:48 +0530 Subject: [PATCH] [ci] Updated system dependencies --- .github/workflows/ci.yml | 13 ++++++++++++- docker-compose.yml | 22 ++++++++++++++++++++++ tests/openwisp2/settings.py | 1 + 3 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 docker-compose.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index abceb5f5..b1c099a4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -34,7 +34,18 @@ jobs: - name: Install system libraries run: | sudo apt update - sudo apt-get -qq -y install xmlsec1 gettext + sudo apt-get -qq -y install xmlsec1 gettext \ + sqlite3 \ + fping \ + gdal-bin \ + libproj-dev \ + libgeos-dev \ + libspatialite-dev \ + spatialite-bin \ + libsqlite3-mod-spatialite + + - name: Start InfluxDB and Redis container + run: docker-compose up -d influxdb redis - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v2 diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 00000000..a7592770 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,22 @@ +version: "3" + +services: + influxdb: + image: influxdb:1.8-alpine + volumes: + - influxdb-data:/var/lib/influxdb + ports: + - "8086:8086" + environment: + INFLUXDB_DB: openwisp2 + INFLUXDB_USER: openwisp + INFLUXDB_USER_PASSWORD: openwisp + + redis: + image: redis:alpine + ports: + - "6379:6379" + entrypoint: redis-server --appendonly yes + +volumes: + influxdb-data: {} diff --git a/tests/openwisp2/settings.py b/tests/openwisp2/settings.py index abc4c2d0..7a846e15 100644 --- a/tests/openwisp2/settings.py +++ b/tests/openwisp2/settings.py @@ -370,6 +370,7 @@ }, } } + DATABASES['default']['ENGINE'] = 'openwisp_utils.db.backends.spatialite' if os.environ.get('SAMPLE_APP', False): INSTALLED_APPS.remove('openwisp_radius')