Sign inSign up

cofacts/url-resolver

By cofacts

Updated about 2 months ago

A standalone service scraps the specified URL and returns scrapped result and summary.

Image
0

769

cofacts/url-resolver repository overview

Cofacts URL Resolver

Build Status Coverage Status

A gRPC service that scraps the specified URL and returns scrapped result and summary extracted by [Readability.js]

Usage

First, create an .env file from .env.sample.

Run url resolver from built docker images

$ docker pull cofacts/url-resolver
$ docker run --rm --env-file .env -p 4000:4000 cofacts/url-resolver

You can use gRPC clients like BloomRPC to access the service for testing purpose.

To access the gRPC service, you can see docker-test.js for an example that uses @grpc/proto-loader.

Development

First, create an .env file from .env.sample. Fill in your env.

Install development dependencies

# After git clone
$ cd url-resolver
$ npm install

# Build js binary from proto files
$ npm run compile

Start dev server

$ npm start

After editing proto files, run npm run compile to generate corresponding Javascript binary.

Build

Directly use docker to build image.

$ docker build -t cofacts/url-resolver:latest .

Tag summary

Content type

Image

Digest

sha256:7ed1c1281

Size

364.3 MB

Last updated

about 2 months ago

docker pull cofacts/url-resolver