Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

example config and groups #198

Closed
gedw99 opened this issue May 2, 2024 · 5 comments
Closed

example config and groups #198

gedw99 opened this issue May 2, 2024 · 5 comments

Comments

@gedw99
Copy link

gedw99 commented May 2, 2024

could an example folder be added that has working config.json and 1 or 2 groups json files ?

it will make it easy to learn how the system works and also to debug and do PR's

@gedw99
Copy link
Author

gedw99 commented May 2, 2024

If these config files can be released with tags then the code and config will stay in sync, allowing easier regression testing and setup too.

https://github.com/jech/galene/releases/tag/galene-0.8.2 for instance could have the config.json and group-x.json files with it.

@jech
Copy link
Owner

jech commented May 2, 2024

could an example folder be added that has working config.json and 1 or 2 groups json files ?

There's an example configuration file in the documentation: https://galene.org/README.html#the-global-configuration-file

There are three example group files in the documentation: https://galene.org/README.html#examples

allowing easier regression testing

We already test the parser: https://github.com/jech/galene/blob/master/group/description_test.go

@jech jech closed this as completed May 2, 2024
@gedw99
Copy link
Author

gedw99 commented May 2, 2024

seems docs and code are maybe out of sync or I am not configuring correctly.
Hence why sample json files would be good.

Actually the README and the WIKI docs are out of sync with how to model a config file.
The wiki seems to be right and the README wrong ?

errors

galene -data /Users/apple/workspace/go/src/github.com/gedw99/kanka-cloudflare/modules/video/video-conf/.data -insecure -static galene/static -groups /Users/apple/workspace/go/src/github.com/gedw99/kanka-cloudflare/modules/video/video-conf/.data/groups -recordings /Users/apple/workspace/go/src/github.com/gedw99/kanka-cloudflare/modules/video/video-conf/.data/recordings
2024/05/02 12:22:37 /Users/apple/workspace/go/src/github.com/gedw99/kanka-cloudflare/modules/video/video-conf/.data/config.json: json: cannot unmarshal object into Go struct field Configuration.admin of type []group.ClientPattern
2024/05/02 12:22:37 Starting built-in TURN server on :1194
2024/05/02 12:22:37 Group file /Users/apple/workspace/go/src/github.com/gedw99/kanka-cloudflare/modules/video/video-conf/.data/groups/group-x.json: json: unknown field "users"
turn ERROR: 2024/05/02 12:22:37 Failed to handle datagram: failed to handle Send-indication from 198.19.249.3:52793: packet write smaller than packet 0 != 112 (expected) err: write udp4 198.19.249.3:55178->198.19.249.3:50652: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:37 Failed to handle datagram: failed to handle Send-indication from 198.19.249.3:52793: packet write smaller than packet 0 != 112 (expected) err: write udp4 198.19.249.3:55178->198.19.249.3:50652: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:37 Failed to handle datagram: failed to handle Send-indication from 198.19.249.3:52793: packet write smaller than packet 0 != 112 (expected) err: write udp4 198.19.249.3:55178->198.19.249.3:56668: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:37 Failed to handle datagram: unable to handle ChannelData from 198.19.249.3:52793: failed writing to socket: write udp4 198.19.249.3:55178->198.19.249.3:50652: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:37 Failed to handle datagram: unable to handle ChannelData from 198.19.249.3:52793: failed writing to socket: write udp4 198.19.249.3:55178->198.19.249.3:56668: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:37 Failed to handle datagram: unable to handle ChannelData from 198.19.249.3:52793: failed writing to socket: write udp4 198.19.249.3:55178->198.19.249.3:50652: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:37 Failed to handle datagram: unable to handle ChannelData from 198.19.249.3:52793: failed writing to socket: write udp4 198.19.249.3:55178->198.19.249.3:56668: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:37 Failed to handle datagram: unable to handle ChannelData from 198.19.249.3:52793: failed writing to socket: write udp4 198.19.249.3:55178->198.19.249.3:50652: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:37 Failed to handle datagram: unable to handle ChannelData from 198.19.249.3:52793: failed writing to socket: write udp4 198.19.249.3:55178->198.19.249.3:56668: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:37 Failed to handle datagram: unable to handle ChannelData from 198.19.249.3:52793: failed writing to socket: write udp4 198.19.249.3:55178->198.19.249.3:50652: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:37 Failed to handle datagram: unable to handle ChannelData from 198.19.249.3:52793: failed writing to socket: write udp4 198.19.249.3:55178->198.19.249.3:56668: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:38 Failed to handle datagram: unable to handle ChannelData from 198.19.249.3:52793: failed writing to socket: write udp4 198.19.249.3:55178->198.19.249.3:50652: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:38 Failed to handle datagram: unable to handle ChannelData from 198.19.249.3:52793: failed writing to socket: write udp4 198.19.249.3:55178->198.19.249.3:56668: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:38 Failed to handle datagram: unable to handle ChannelData from 198.19.249.3:52793: failed writing to socket: write udp4 198.19.249.3:55178->198.19.249.3:50652: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:38 Failed to handle datagram: unable to handle ChannelData from 198.19.249.3:52793: failed writing to socket: write udp4 198.19.249.3:55178->198.19.249.3:56668: sendto: operation not permitted
turn ERROR: 2024/05/02 12:22:38 Failed to handle datagram: unable to handle ChannelData from 198.19.249.3:52793: failed writing to socket: write udp4 198.19.249.3:55178->198.19.249.3:56668: sendto: operation not permitted
2024/05/02 12:22:42 couldn't determine group base: json: cannot unmarshal object into Go struct field Configuration.admin of type []group.ClientPattern
2024/05/02 12:22:42 HTTP server error: json: cannot unmarshal object into Go struct field Configuration.admin of type []group.ClientPattern
2024/05/02 12:22:57 Relay test failed: timeout
2024/05/02 12:22:57 Perhaps you didn't configure a TURN server?
       mkdir -p $(DATA_ROOT)
       cp config.json $(DATA_ROOT)/

	mkdir -p $(DATA_ROOT)/groups
	cp group-x.json $(DATA_ROOT)/groups/

	mkdir -p $(DATA_ROOT)/recordings

	galena -data $(DATA_ROOT) -insecure -static $(MAIN_NAME)/static -groups $(DATA_ROOT)/groups -recordings $(DATA_ROOT)/recordings

config.json

{
    "admin":{"root": {"password":"secret", "permissions": "admin"}},
    "writableGroups": true,
    "publicServer": true
}

group-x.json

{
    "displayName": "main group",
    "description": "main group for testing",
    "contact": "gedw99@gmail.com",
    "comment": "comment test",
    "users":{
        "jch":  {"password":"1234", "permissions": "op"},
        "john": {"password": "secret", "permissions": "present"}
    },
    "fallback-users": [
        {"password": {"type": "wildcard"}, "permissions": "present"}
    ],
    "allow-recording": true,
    "auto-subgroups": true,
    "public": true
}

@gedw99
Copy link
Author

gedw99 commented May 2, 2024

sure

@jech
Copy link
Owner

jech commented May 2, 2024

The online docs are for the master branch, while you're running the 0.8 branch. Please use the docs that came with your version of Galene.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants