The dev branch of jetson-inference/jetson-utils has native support for RTSP output. It internally manages the GstRtspServer. You should be able to try it out if you clone/build the dev branch and use something like jetson.utils.videoOutput("rtsp://@:1234/my_stream")