-
Notifications
You must be signed in to change notification settings - Fork 799
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
Intercept Xonotic stdout for SDK Integration #218
Intercept Xonotic stdout for SDK Integration #218
Conversation
Build Failed 😱 Build Id: ae77ad29-b1c9-4fe5-a4ff-892c099b1530 Build Logs
|
Build Failed 😱 Build Id: 61ae0bd9-e3fc-4e3b-a325-d3a9d9726145 Build Logs
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some small nits, but otherwise LGTM.
ENTRYPOINT /home/xonotic/wrapper -i /home/xonotic/Xonotic/server_linux.sh |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Small thing here: missing newline at end of file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
examples/xonotic/README.md
Outdated
@@ -2,6 +2,10 @@ | |||
|
|||
Example using a [Xonotic](http://www.xonotic.org) dedicated game server. | |||
|
|||
*Note:* This example doesn't directly integrate the SDK (yet), but calls it via a separate binary. | |||
This example wraps the Xonotic server with a [Go](https://golang.org) binary, and introspect |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Short to "introspects stdout"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice. Done.
examples/xonotic/README.md
Outdated
This example wraps the Xonotic server with a [Go](https://golang.org) binary, and introspect | ||
the stdout output to provide the event hooks for the SDK integration. | ||
|
||
It is not a direct integration, but is a nice way of demoing an approach for to integrate with existing |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
an approach for integrating
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
image: gcr.io/agones-images/xonotic-example:0.2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing newline.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
examples/xonotic/gameserver.yaml
Outdated
@@ -23,5 +23,5 @@ spec: | |||
spec: | |||
containers: | |||
- name: xonotic | |||
image: gcr.io/agones-images/xonotic-example:0.1 | |||
image: gcr.io/agones-images/xonotic-example:0.2 | |||
# imagePullPolicy: Always # add for development |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note part of the diff technically, but since you're in the neighborhood, maybe add a newline here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
examples/xonotic/main.go
Outdated
@@ -18,22 +18,93 @@ import ( | |||
"log" | |||
"time" | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The following imports can be moved up one line to be next to log and time.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
examples/xonotic/main.go
Outdated
} | ||
|
||
// Write will intercept the incoming stream, and forward | ||
// the contents to it's `forward` Writer. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
its
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch!
Change the Xonotic example to have wrapper around the server execution, and use the content of stdout to determine what to do with the SDK for GameServer lifecycle management.
f532299
to
6bb72a3
Compare
Build Succeeded 👏 Build Id: 89a804d1-addb-4d39-b61c-25bed3af95db The following development artifacts have been built, and will exist for the next 30 days:
|
Change the Xonotic example to have wrapper around the server execution, and use the content of stdout to determine what to do with the SDK for GameServer lifecycle management.