feat: add VirusShare_00482.zip #15
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: Test | |
on: [ push, pull_request ] | |
jobs: | |
sqlite: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install SQLite, git | |
run: | | |
sudo apt-get install -y git sqlite3 | |
shell: bash | |
- name: Checkout MalwareDB | |
run: | | |
git clone https://github.com/malwaredb/malwaredb-rs.git | |
- name: Create database | |
run: | | |
sqlite3 test.db < malwaredb-rs/crates/server/src/db/malwaredb_sqlite.sql | |
- name: Load sources | |
run: | | |
sqlite3 test.db < sources/VirusShare/VirusShare.sql | |
for src in `ls sources/VirusShare/*.zip.sql` | |
do | |
sqlite3 test.db < $src | |
done | |
ls -la test.db | |
postgres: | |
runs-on: ubuntu-latest | |
services: | |
postgres: | |
image: postgres | |
env: | |
POSTGRES_PASSWORD: whatever1 | |
POSTGRES_DB: testdb | |
POSTGRES_USER: postgres | |
ports: | |
- 5432 | |
options: >- | |
--health-cmd pg_isready | |
--health-interval 10s | |
--health-timeout 5s | |
--health-retries 5 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install git | |
run: | | |
sudo apt-get install -y git | |
shell: bash | |
- name: Checkout MalwareDB | |
run: | | |
git clone https://github.com/malwaredb/malwaredb-rs.git | |
- name: Create database | |
run: | | |
PGPASSWORD=whatever1 psql -U postgres -h 127.0.0.1 -p ${{ job.services.postgres.ports[5432] }} -d testdb -f malwaredb-rs/crates/server/src/db/malwaredb_pg.sql | |
- name: Load sources | |
run: | | |
PGPASSWORD=whatever1 psql -U postgres -h 127.0.0.1 -p ${{ job.services.postgres.ports[5432] }} -d testdb -f sources/VirusShare/VirusShare.sql | |
for src in `ls sources/VirusShare/*.zip.sql` | |
do | |
PGPASSWORD=whatever1 psql -U postgres -h 127.0.0.1 -p ${{ job.services.postgres.ports[5432] }} -d testdb -f $src | |
done |