mirror of
https://github.com/AdguardTeam/AdGuardHome.git
synced 2024-11-27 09:18:58 +03:00
Merge: * move ./*.go files into ./home/ directory
* commit 'dc682763ff61874eb6043eaac5fa0eba17f7ddec': * move ./*.go files into ./home/ directory
This commit is contained in:
commit
6187871e3b
27 changed files with 37 additions and 28 deletions
2
Makefile
2
Makefile
|
@ -20,7 +20,7 @@ client/node_modules: client/package.json client/package-lock.json
|
|||
$(STATIC): $(JSFILES) client/node_modules
|
||||
npm --prefix client run build-prod
|
||||
|
||||
$(TARGET): $(STATIC) *.go dhcpd/*.go dnsfilter/*.go dnsforward/*.go
|
||||
$(TARGET): $(STATIC) *.go home/*.go dhcpd/*.go dnsfilter/*.go dnsforward/*.go
|
||||
GOOS=$(NATIVE_GOOS) GOARCH=$(NATIVE_GOARCH) GO111MODULE=off go get -v github.com/gobuffalo/packr/...
|
||||
PATH=$(GOPATH)/bin:$(PATH) packr -z
|
||||
CGO_ENABLED=0 go build -ldflags="-s -w -X main.VersionString=$(GIT_VERSION) -X main.updateChannel=$(CHANNEL)" -asmflags="-trimpath=$(PWD)" -gcflags="-trimpath=$(PWD)"
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"encoding/json"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import "testing"
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"io/ioutil"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"bytes"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"encoding/json"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"context"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"testing"
|
|
@ -1,6 +1,6 @@
|
|||
// Control: TLS configuring handlers
|
||||
|
||||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"context"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"archive/tar"
|
|
@ -1,6 +1,6 @@
|
|||
// +build ignore
|
||||
|
||||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"os"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"encoding/json"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"fmt"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"testing"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"fmt"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"bufio"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"testing"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"bufio"
|
||||
|
@ -49,7 +49,7 @@ const (
|
|||
)
|
||||
|
||||
// main is the entry point
|
||||
func main() {
|
||||
func Main() {
|
||||
// config can be specified, which reads options from there, but other command line flags have to override config values
|
||||
// therefore, we must do it manually instead of using a lib
|
||||
args := loadOptions()
|
||||
|
@ -174,7 +174,7 @@ func run(args options) {
|
|||
go periodicallyRefreshFilters()
|
||||
|
||||
// Initialize and run the admin Web interface
|
||||
box := packr.NewBox("build/static")
|
||||
box := packr.NewBox("../build/static")
|
||||
|
||||
// if not configured, redirect / to /install.html, otherwise redirect /install.html to /
|
||||
http.Handle("/", postInstallHandler(optionalAuthHandler(gziphandler.GzipHandler(http.FileServer(box)))))
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"fmt"
|
|
@ -1,6 +1,6 @@
|
|||
// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris
|
||||
|
||||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"os"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import "golang.org/x/sys/windows"
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"os"
|
|
@ -1,6 +1,6 @@
|
|||
// +build !windows,!nacl,!plan9
|
||||
|
||||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"log"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"log"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"fmt"
|
|
@ -1,4 +1,4 @@
|
|||
package main
|
||||
package home
|
||||
|
||||
import (
|
||||
"fmt"
|
9
main.go
Normal file
9
main.go
Normal file
|
@ -0,0 +1,9 @@
|
|||
package main
|
||||
|
||||
import (
|
||||
"github.com/AdguardTeam/AdGuardHome/home"
|
||||
)
|
||||
|
||||
func main() {
|
||||
home.Main()
|
||||
}
|
Loading…
Reference in a new issue