billing

package
v1.3.1 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

ftpserver allows to create your own FTP(S) server

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FTPLogin

func FTPLogin() (*ftp.ServerConn, error)

The ftp client is for CDR Pull method, that is the billing domain actively query CDR file from CHF

func PullCDRFile

func PullCDRFile(c *ftp.ServerConn, fileName string) ([]byte, error)

Types

type Access

type Access struct {
	User   string            `json:"user"`
	Pass   string            `json:"pass"`
	Fs     string            `json:"fs"`
	Params map[string]string `json:"params"`
}

type BillingDomain

type BillingDomain struct {
	// contains filtered or unexported fields
}

func OpenServer

func OpenServer(wg *sync.WaitGroup) *BillingDomain

The ftp server is for CDR Push method, that is the CHF will send the CDR file to the FTP server

func (*BillingDomain) Serve

func (b *BillingDomain) Serve(wg *sync.WaitGroup)

func (*BillingDomain) Stop

func (b *BillingDomain) Stop()

type FtpConfig

type FtpConfig struct {
	Version        int      `json:"version"`
	Accesses       []Access `json:"accesses"`
	Listen_address string   `json:"listen_address"`
}

Jump to

Keyboard shortcuts

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