gateway

package
v1.0.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 24, 2022 License: MIT Imports: 28 Imported by: 0

Documentation

Overview

This package starts up the daemon and everything else. It contains the entry point for Android bindings: the Run() function.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsRunning

func IsRunning() bool

IsRunning returns a bool indicating whether the daemon is running.

func Run

func Run(repoPath, gatewayPort, interfaces string)

Run starts up the daemon and returns immediately.

repoPath is a path to a directory for the IPFS repo. It doesn't need to exist.

interfaces is a newline-delimited list of network interface definitions. It is only needed on Android. See get_interfaces.java for code of how this string is generated.

gatewayPort is the TCP port the gateway runs on.

func RunSynchronous

func RunSynchronous(repoPath, gatewayPort, interfaces string) int

RunSynchronous is like Run but returns an exit code greater than 0 if there are any errors. It does not return unless there is an error and the daemon has stopped.

func Stop

func Stop()

Stop stops the daemon within over 2 seconds. It does a graceful shutdown.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL