mirror of
https://github.com/hackerschoice/segfault.git
synced 2024-06-28 17:51:22 +00:00
Merge branch 'main' of github.com:hackerschoice/segfault
This commit is contained in:
commit
b4275a826f
@ -107,7 +107,7 @@ services:
|
|||||||
restart: ${SF_RESTART:-on-failure}
|
restart: ${SF_RESTART:-on-failure}
|
||||||
cgroup_parent: sf.slice
|
cgroup_parent: sf.slice
|
||||||
volumes:
|
volumes:
|
||||||
- "${SF_BASEDIR:-.}/config/etc/logpipe/config.yaml:/app/config.yaml:ro"
|
- "${SF_BASEDIR:-.}/config/etc/logpipe/:/app/config/:ro"
|
||||||
- "/dev/shm/sf/run/logpipe/:/app/sock/:rw"
|
- "/dev/shm/sf/run/logpipe/:/app/sock/:rw"
|
||||||
|
|
||||||
sf-portd:
|
sf-portd:
|
||||||
|
@ -21,7 +21,7 @@ type LogPipe struct {
|
|||||||
func main() {
|
func main() {
|
||||||
lp := LogPipe{}
|
lp := LogPipe{}
|
||||||
|
|
||||||
fbytes, ferr := os.ReadFile("config.yaml")
|
fbytes, ferr := os.ReadFile("./config/config.yaml")
|
||||||
if ferr == nil {
|
if ferr == nil {
|
||||||
err := yaml.Unmarshal(fbytes, &lp)
|
err := yaml.Unmarshal(fbytes, &lp)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@ -47,6 +47,8 @@ func listenOnSocket(socketFile string) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
os.Chmod(socketFile, 0777)
|
||||||
|
|
||||||
for {
|
for {
|
||||||
conn, err := listener.Accept()
|
conn, err := listener.Accept()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
Loading…
Reference in New Issue
Block a user