Giter Site home page Giter Site logo

gateway's Introduction

Arweave Gateway

License Build Status codecov

Review the documentation to learn more about setting up and deploying a Gateway.

Requirements

  1. A Unix OS

  2. Docker and Docker Compose LTS

Quickstart with App Nodes

To get started with the new app nodes. Please read the Quick Start Guide. It goes over how to configure the environment and write filters for application specific needs.

Environment

By default, there is a default environment you can use located at .env.docker in the repository.

ARWEAVE_NODES=["http://lon-2.eu-west-1.arweave.net:1984","http://lon-4.eu-west-1.arweave.net:1984","http://lon-6.eu-west-1.arweave.net:1984"]

DATABASE_HOST=postgres
DATABASE_PORT=5432
DATABASE_USER=arweave
DATABASE_PASSWORD=arweave
DATABASE_NAME=arweave

ENVIRONMENT=public
PORT=3000

PARALLEL=1
ANS102=1

CACHING=1
CACHE_FOLDER=/gateway/cache
CACHE_OFFSET=0

MANIFEST=1
MANIFEST_PREFIX=amp-gw.online

TYPE=APP
FILTER=app.filter.json
START_HEIGHT=764180

Make sure you copy this configuration to .env.

cp .env.dev .env

You should also update the ARWEAVE_NODES to valid

Running the server

You can start the server with docker-compose.

# with npm
npm run docker:start

# with yarn
yarn docker:start

# with pure docker-compose
docker-compose up --build -d

You can spin down the docker-compose cluster with.

# with npm
npm run docker:stop

# with yarn
yarn docker:stop

# with pure docker-compose
docker-compose down

Testing

You can test if the server and the GraphQL queries are working properly by navigating to.

http://localhost:3000/graphql

This webpage should look similar to.

https://arweave.dev/graphql

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.