-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from startin-blox/feature/docker-compose
Feature/docker compose
- Loading branch information
Showing
29 changed files
with
534 additions
and
93 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# DBS RELATED CONFIGS | ||
APP_NAME=dbs | ||
PYTHONUNBUFFERED=1 | ||
DJANGO_LOG_LEVEL=DEBUG | ||
|
||
# FILECOIN RELATED CONFIGS | ||
DBS_URL='http://127.0.0.1:8000' | ||
LOCATION_URL='127.0.0.1' | ||
PRIVATE_KEY='8837837383' | ||
LIGHTHOUSE_API_TOKEN='xyv02u242vfvvdgdv24874nnnnndg' | ||
USER_SQL='root' | ||
PASSWORD_SQL='root' | ||
DATABASE_SQL='filecoin_dbs' | ||
HOST_SQL='127.0.0.1' | ||
DATANAME_SQL='quote' | ||
MUMBAI_RPC='https://polygon-mumbai.blockpi.network/v1/rpc/public' | ||
|
||
# ARWEAVE RELATED CONFIGS | ||
ACCEPTED_PAYMENTS='ethereum,matic' | ||
NODE_RPC_URIS='default,default' | ||
BUNDLR_URI='https://devnet.bundlr.network' | ||
PORT='8081' | ||
# Needs to be provisioned with Matic and GoerliEth | ||
PRIVATE_KEY='0000000000000000000000000000000000000000000000000000000000000000' | ||
SQLITE_DB_PATH='db' | ||
REGISTRATION_INTERVAL=60000 | ||
DBS_URI='http://localhost:8000' | ||
SELF_URI='http://localhost' | ||
IPFS_GATEWAY='https://cloudflare-ipfs.com/ipfs/' | ||
ARWEAVE_GATEWAY='https://arweave.net/' | ||
MAX_UPLOAD_SIZE='1099511627776' | ||
# Needs to be provisioned with Matic/WMatic and GoerliETH/WETH | ||
TEST_PRIVATE_KEY='0000000000000000000000000000000000000000000000000000000000000000' | ||
ENABLE_EXPENSIVE_TESTS='false' | ||
CHAIN_ID='80001' | ||
TOKEN_ADDRESS='0x9c3C9283D3e44854697Cd22D3Faa240Cfb032889' |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
__pycache__ | ||
venv | ||
server/db.sqlite3 | ||
.env |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
[submodule "services/dbs_filecoin"] | ||
path = services/dbs_filecoin | ||
url = https://github.com/oceanprotocol/dbs_filecoin.git | ||
[submodule "services/dbs_arweave"] | ||
path = services/dbs_arweave | ||
url = https://github.com/oceanprotocol/dbs_arweave.git |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
version: "3.9" | ||
services: | ||
dbs: | ||
build: . | ||
network_mode: host | ||
environment: | ||
- PYTHONUNBUFFERED=1 | ||
- DJANGO_LOG_LEVEL=DEBUG=value | ||
volumes: | ||
- .:/usr/src/app | ||
mariadb: | ||
container_name: ${APP_NAME}_mariadb | ||
image: mariadb | ||
restart: always | ||
environment: | ||
MARIADB_ROOT_PASSWORD: root | ||
MARIADB_USER: test | ||
MARIADB_PASS: pass | ||
MARIADB_DATABASE: filecoin_dbs | ||
MARIADB_HOST: 127.0.0.1 | ||
healthcheck: | ||
test: mariadb --user=root --password=root --silent --execute "use filecoin_dbs;" | ||
interval: 1s | ||
timeout: 3s | ||
retries: 10 | ||
# volumes: | ||
# - ./mounts/mariadb:/var/lib/mariadb | ||
network_mode: host | ||
dbs_filecoin: | ||
container_name: filecoin | ||
build: ./services/dbs_filecoin/ | ||
env_file: .env # Used to provide the filecoin env variables | ||
depends_on: | ||
mariadb: | ||
condition: service_healthy | ||
network_mode: host | ||
dbs_arweave: | ||
container_name: arweave | ||
build: ./services/dbs_arweave/ | ||
env_file: .env | ||
network_mode: host | ||
ipfs: | ||
image: ipfs/kubo | ||
network_mode: host | ||
ipfs-cluster: | ||
image: ipfs/ipfs-cluster | ||
network_mode: host |
Binary file not shown.
Binary file not shown.
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
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
40 changes: 40 additions & 0 deletions
40
server/oceandbs/migrations/0020_alter_acceptedtoken_paymentmethod_and_more.py
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# Generated by Django 4.1.2 on 2023-01-18 16:31 | ||
|
||
import datetime | ||
from django.db import migrations, models | ||
import django.db.models.deletion | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('oceandbs', '0019_remove_file_file_file_cid_file_title_and_more'), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterField( | ||
model_name='acceptedtoken', | ||
name='paymentMethod', | ||
field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='acceptedTokens', to='oceandbs.paymentmethod'), | ||
), | ||
migrations.AlterField( | ||
model_name='payment', | ||
name='paymentMethod', | ||
field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='payments', to='oceandbs.paymentmethod'), | ||
), | ||
migrations.AlterField( | ||
model_name='paymentmethod', | ||
name='storage', | ||
field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='paymentMethods', to='oceandbs.storage'), | ||
), | ||
migrations.AlterField( | ||
model_name='quote', | ||
name='expiration', | ||
field=models.DateTimeField(default=datetime.datetime(2023, 1, 18, 17, 1, 41, 275788, tzinfo=datetime.timezone.utc)), | ||
), | ||
migrations.AlterField( | ||
model_name='quote', | ||
name='nonce', | ||
field=models.DateTimeField(default=datetime.datetime(2023, 1, 11, 16, 31, 41, 275770, tzinfo=datetime.timezone.utc)), | ||
), | ||
] |
30 changes: 30 additions & 0 deletions
30
...r/oceandbs/migrations/0021_alter_paymentmethod_storage_alter_quote_expiration_and_more.py
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# Generated by Django 4.1.2 on 2023-02-02 17:04 | ||
|
||
import datetime | ||
from django.db import migrations, models | ||
import django.db.models.deletion | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('oceandbs', '0020_alter_acceptedtoken_paymentmethod_and_more'), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterField( | ||
model_name='paymentmethod', | ||
name='storage', | ||
field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='payment', to='oceandbs.storage'), | ||
), | ||
migrations.AlterField( | ||
model_name='quote', | ||
name='expiration', | ||
field=models.DateTimeField(default=datetime.datetime(2023, 2, 2, 17, 34, 7, 719831, tzinfo=datetime.timezone.utc)), | ||
), | ||
migrations.AlterField( | ||
model_name='quote', | ||
name='nonce', | ||
field=models.DateTimeField(default=datetime.datetime(2023, 1, 26, 17, 4, 7, 719811, tzinfo=datetime.timezone.utc)), | ||
), | ||
] |
29 changes: 29 additions & 0 deletions
29
.../oceandbs/migrations/0022_paymentmethod_rpcendpointurl_alter_quote_expiration_and_more.py
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# Generated by Django 4.1.2 on 2023-02-13 14:46 | ||
|
||
import datetime | ||
from django.db import migrations, models | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('oceandbs', '0021_alter_paymentmethod_storage_alter_quote_expiration_and_more'), | ||
] | ||
|
||
operations = [ | ||
migrations.AddField( | ||
model_name='paymentmethod', | ||
name='rpcEndpointUrl', | ||
field=models.URLField(default='https://example.com', max_length=2048), | ||
), | ||
migrations.AlterField( | ||
model_name='quote', | ||
name='expiration', | ||
field=models.DateTimeField(default=datetime.datetime(2023, 2, 13, 15, 16, 25, 188917, tzinfo=datetime.timezone.utc)), | ||
), | ||
migrations.AlterField( | ||
model_name='quote', | ||
name='nonce', | ||
field=models.DateTimeField(default=datetime.datetime(2023, 2, 6, 14, 46, 25, 188897, tzinfo=datetime.timezone.utc)), | ||
), | ||
] |
24 changes: 24 additions & 0 deletions
24
server/oceandbs/migrations/0023_alter_quote_expiration_alter_quote_nonce.py
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Generated by Django 4.1.2 on 2023-02-13 14:46 | ||
|
||
import datetime | ||
from django.db import migrations, models | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('oceandbs', '0022_paymentmethod_rpcendpointurl_alter_quote_expiration_and_more'), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterField( | ||
model_name='quote', | ||
name='expiration', | ||
field=models.DateTimeField(default=datetime.datetime(2023, 2, 13, 15, 16, 28, 315596, tzinfo=datetime.timezone.utc)), | ||
), | ||
migrations.AlterField( | ||
model_name='quote', | ||
name='nonce', | ||
field=models.DateTimeField(default=datetime.datetime(2023, 2, 6, 14, 46, 28, 315577, tzinfo=datetime.timezone.utc)), | ||
), | ||
] |
Oops, something went wrong.