fix: upgrade IPFS http client library, esimports
This commit is contained in:
parent
34c4993cd9
commit
cf14cbc2bb
|
@ -14,22 +14,22 @@ services:
|
|||
- spk-video-encoder
|
||||
environment:
|
||||
IPFS_HOST: ipfs:5001
|
||||
ports:
|
||||
- "4001:4001"
|
||||
volumes:
|
||||
- ./data/video-encoder:/root/.spk-encoder
|
||||
ipfs:
|
||||
container_name: ipfs2
|
||||
image: ipfs/go-ipfs:latest
|
||||
image: ipfs/kubo:v0.18.1
|
||||
command:
|
||||
- daemon
|
||||
- --enable-pubsub-experiment
|
||||
networks:
|
||||
- spk-video-encoder
|
||||
ports:
|
||||
- "4001:4001"
|
||||
environment:
|
||||
IPFS_PATH: /etc/ipfs
|
||||
volumes:
|
||||
- ./data/ipfs:/etc/ipfs
|
||||
- ./data/ipfs-2:/etc/ipfs
|
||||
|
||||
networks:
|
||||
spk-video-encoder:
|
||||
|
|
File diff suppressed because it is too large
Load Diff
18
package.json
18
package.json
|
@ -3,8 +3,14 @@
|
|||
"version": "1.0.0",
|
||||
"description": "",
|
||||
"main": "dist/index.js",
|
||||
"type": "module",
|
||||
"directories": {
|
||||
"dist": "./dist"
|
||||
},
|
||||
"files": [
|
||||
"dist"
|
||||
],
|
||||
"dependencies": {
|
||||
"3id-did-provider": "^1.1.1",
|
||||
"@ceramicnetwork/3id-did-resolver": "^1.4.4",
|
||||
"@ceramicnetwork/http-client": "^1.4.0",
|
||||
"@ceramicnetwork/stream-tile": "^1.3.2",
|
||||
|
@ -18,6 +24,7 @@
|
|||
"@nestjs/swagger": "^5.1.5",
|
||||
"@nftstorage/ipfs-cluster": "github:3speaknetwork/ipfs-cluster",
|
||||
"@web-std/file": "^3.0.0",
|
||||
"3id-did-provider": "^1.1.1",
|
||||
"ajv": "^8.6.3",
|
||||
"axios": "^0.24.0",
|
||||
"cli-ux": "^5.6.3",
|
||||
|
@ -33,7 +40,7 @@
|
|||
"graphql": "^16.5.0",
|
||||
"graphql-type-long": "^0.1.1",
|
||||
"ipfs-cluster-api": "^0.0.9",
|
||||
"ipfs-http-client": "^53.0.1",
|
||||
"ipfs-http-client": "^60.0.0",
|
||||
"it-pipe": "^1.1.0",
|
||||
"it-pushable": "^1.4.2",
|
||||
"key-did-provider-ed25519": "^1.1.0",
|
||||
|
@ -49,12 +56,13 @@
|
|||
"node-graceful-shutdown": "^1.1.0",
|
||||
"node-schedule": "^2.1.0",
|
||||
"nodejs-file-downloader": "^4.9.3",
|
||||
"p-queue": "^6.6.2",
|
||||
"p-queue": "^7.3.0",
|
||||
"pouchdb": "^7.2.2",
|
||||
"pouchdb-find": "^7.2.2",
|
||||
"pouchdb-upsert": "^2.2.0",
|
||||
"reflect-metadata": "^0.1.13",
|
||||
"swagger-ui-express": "^4.3.0",
|
||||
"text-encoding": "^0.7.0",
|
||||
"tmp": "^0.2.1",
|
||||
"uuid": "^8.3.2",
|
||||
"yargs": "^17.2.1"
|
||||
|
@ -67,6 +75,7 @@
|
|||
"eslint-config-prettier": "^8.3.0",
|
||||
"eslint-plugin-prettier": "^3.4.0",
|
||||
"jest": "^27.0.6",
|
||||
"nodemon": "^2.0.20",
|
||||
"prettier": "^2.4.1",
|
||||
"ts-jest": "^27.0.5",
|
||||
"ts-node": "^10.4.0",
|
||||
|
@ -74,8 +83,9 @@
|
|||
"typescript": "^4.4.4"
|
||||
},
|
||||
"scripts": {
|
||||
"start": "node --experimental-specifier-resolution=node dist/index.js",
|
||||
"build": "tsc",
|
||||
"dev": "ts-node-dev src/index.ts",
|
||||
"dev": "nodemon --exec \"node --experimental-specifier-resolution=node --loader ts-node/esm\" src/index.ts",
|
||||
"lint:fix": "eslint --fix \"src/**/*.{ts,tsx}\"",
|
||||
"lint": "eslint \"src/**/*.{ts,tsx}\"",
|
||||
"test:report": "sensible-browser ./coverage/lcov-report/index.html",
|
||||
|
|
|
@ -1,14 +1,15 @@
|
|||
import CeramicHTTP from '@ceramicnetwork/http-client'
|
||||
import {CeramicClient} from '@ceramicnetwork/http-client'
|
||||
import { onShutdown } from "node-graceful-shutdown";
|
||||
import { ConfigService } from './config.service'
|
||||
import IPFSHTTP from 'ipfs-http-client'
|
||||
// import IPFSHTTP from 'ipfs-http-client'
|
||||
import { CoreService } from './modules/core/core.service'
|
||||
import {EncoderApiModule} from './api/index'
|
||||
|
||||
let instance: CoreService;
|
||||
async function startup(): Promise<void> {
|
||||
|
||||
// init ceramic
|
||||
const ceramic = new CeramicHTTP(ConfigService.getConfig().ceramicHost) //Using the public node for now.
|
||||
const ceramic = new CeramicClient(ConfigService.getConfig().ceramicHost) //Using the public node for now.
|
||||
|
||||
|
||||
instance = new CoreService(ceramic)
|
||||
|
|
|
@ -14,7 +14,7 @@ import PouchdbUpsert from 'pouchdb-upsert'
|
|||
import { EncodeStatus, GatewayJob, GatewayWorkerInfo, JobStatus } from '../encoder.model'
|
||||
import NodeSchedule from 'node-schedule'
|
||||
import { MongoClient, Db, Collection } from 'mongodb'
|
||||
import PQueue from 'p-queue'
|
||||
import {default as PQueue} from 'p-queue'
|
||||
//import { Cluster } from '@nftstorage/ipfs-cluster'
|
||||
import IpfsCluster from 'ipfs-cluster-api'
|
||||
import { IpfsClusterPinAdd } from '../../common/utils'
|
||||
|
@ -23,6 +23,7 @@ import { ScoringService } from './gateway/scoring'
|
|||
import Axios from 'axios'
|
||||
import moment from 'moment'
|
||||
|
||||
|
||||
export class GatewayService {
|
||||
self: CoreService
|
||||
events: EventEmitter
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
// "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */
|
||||
|
||||
/* Language and Environment */
|
||||
"target": "es2018" /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */,
|
||||
"target": "ES2020" /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */,
|
||||
"lib": [
|
||||
"ES2021"
|
||||
] /* Specify a set of bundled library declaration files that describe the target runtime environment. */,
|
||||
|
@ -26,9 +26,9 @@
|
|||
// "useDefineForClassFields": true, /* Emit ECMAScript-standard-compliant class fields. */
|
||||
|
||||
/* Modules */
|
||||
"module": "commonjs" /* Specify what module code is generated. */,
|
||||
"module": "ES2020" /* Specify what module code is generated. */,
|
||||
// "rootDir": "./", /* Specify the root folder within your source files. */
|
||||
// "moduleResolution": "node", /* Specify how TypeScript looks up a file from a given module specifier. */
|
||||
"moduleResolution": "node", /* Specify how TypeScript looks up a file from a given module specifier. */
|
||||
// "baseUrl": "./", /* Specify the base directory to resolve non-relative module names. */
|
||||
// "paths": {}, /* Specify a set of entries that re-map imports to additional lookup locations. */
|
||||
// "rootDirs": [], /* Allow multiple folders to be treated as one when resolving modules. */
|
||||
|
|
Loading…
Reference in New Issue