How to show a non-interactive X session for displaying and periodically reload a webpage?
I have I all-in-one-pc running a webserver. As its display is constantly on, I was wondering how I could use it to display a website in parallel, e.g. the webserver's status page https://localhost/my/status/page and refreshing it periodically.
As I don't want anyone to be able to use this browser window to browse the internet, it would need to be non-interactive, i.e. not reacting to mouse and keyboard. Is there such thing as a non-interactive X session in which I could start a browser?
It would be okay if someone could kill the session with a keystroke, I only want to prevent using the session for browsing or opening additional programs.
browser webserver xserver
add a comment |
I have I all-in-one-pc running a webserver. As its display is constantly on, I was wondering how I could use it to display a website in parallel, e.g. the webserver's status page https://localhost/my/status/page and refreshing it periodically.
As I don't want anyone to be able to use this browser window to browse the internet, it would need to be non-interactive, i.e. not reacting to mouse and keyboard. Is there such thing as a non-interactive X session in which I could start a browser?
It would be okay if someone could kill the session with a keystroke, I only want to prevent using the session for browsing or opening additional programs.
browser webserver xserver
Why not turn off the screen? Eg.sleep 1 ; xset dpms force off
[source]. Other than that it sounds like you're after "kiosk mode" which Opera browser used to do really well.
– pbhj
Dec 2 at 15:42
@pbhj The kiosk mode is a good hint, will take a look at it. Definitely a valid search word to find a suitable tool!
– PhilLab
Dec 7 at 18:12
add a comment |
I have I all-in-one-pc running a webserver. As its display is constantly on, I was wondering how I could use it to display a website in parallel, e.g. the webserver's status page https://localhost/my/status/page and refreshing it periodically.
As I don't want anyone to be able to use this browser window to browse the internet, it would need to be non-interactive, i.e. not reacting to mouse and keyboard. Is there such thing as a non-interactive X session in which I could start a browser?
It would be okay if someone could kill the session with a keystroke, I only want to prevent using the session for browsing or opening additional programs.
browser webserver xserver
I have I all-in-one-pc running a webserver. As its display is constantly on, I was wondering how I could use it to display a website in parallel, e.g. the webserver's status page https://localhost/my/status/page and refreshing it periodically.
As I don't want anyone to be able to use this browser window to browse the internet, it would need to be non-interactive, i.e. not reacting to mouse and keyboard. Is there such thing as a non-interactive X session in which I could start a browser?
It would be okay if someone could kill the session with a keystroke, I only want to prevent using the session for browsing or opening additional programs.
browser webserver xserver
browser webserver xserver
asked Sep 7 at 13:59
PhilLab
787
787
Why not turn off the screen? Eg.sleep 1 ; xset dpms force off
[source]. Other than that it sounds like you're after "kiosk mode" which Opera browser used to do really well.
– pbhj
Dec 2 at 15:42
@pbhj The kiosk mode is a good hint, will take a look at it. Definitely a valid search word to find a suitable tool!
– PhilLab
Dec 7 at 18:12
add a comment |
Why not turn off the screen? Eg.sleep 1 ; xset dpms force off
[source]. Other than that it sounds like you're after "kiosk mode" which Opera browser used to do really well.
– pbhj
Dec 2 at 15:42
@pbhj The kiosk mode is a good hint, will take a look at it. Definitely a valid search word to find a suitable tool!
– PhilLab
Dec 7 at 18:12
Why not turn off the screen? Eg.
sleep 1 ; xset dpms force off
[source]. Other than that it sounds like you're after "kiosk mode" which Opera browser used to do really well.– pbhj
Dec 2 at 15:42
Why not turn off the screen? Eg.
sleep 1 ; xset dpms force off
[source]. Other than that it sounds like you're after "kiosk mode" which Opera browser used to do really well.– pbhj
Dec 2 at 15:42
@pbhj The kiosk mode is a good hint, will take a look at it. Definitely a valid search word to find a suitable tool!
– PhilLab
Dec 7 at 18:12
@pbhj The kiosk mode is a good hint, will take a look at it. Definitely a valid search word to find a suitable tool!
– PhilLab
Dec 7 at 18:12
add a comment |
1 Answer
1
active
oldest
votes
XInput
You can disable mouse and keyboard using libinput
In you session, open up a terminal and run
$ xinput list
⎡ Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ xwayland-pointer:16 id=6 [slave pointer (2)]
⎜ ↳ xwayland-relative-pointer:16 id=7 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
↳ xwayland-keyboard:16 id=8 [slave keyboard (3)]
So now you can disable the mouse, using the proper id:
xinput set-prop 6 "Device Enabled" 0
Don't use the core pointer, that will not work; so now you still see the cursor but its click does nothing.
You can disable the keyboard the same way
xinput set-prop 8 "Device Enabled" 0
Use 1 to enable them again
This is a manual method, you can turn this into a script autostarted with the session.
xtrlock
Another solution is to use the little utility xtrlock
sudo apt install xtrlock
and then
xtrlock
Your mouse cursor will turn into a lock and typing on the keyboard or clicking will do nothing. But if you type your password, the lock will be removed.
My test shows it does not work on 2 monitors, only one (in wayland) but this is not your setup it seems.
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1073102%2fhow-to-show-a-non-interactive-x-session-for-displaying-and-periodically-reload-a%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
XInput
You can disable mouse and keyboard using libinput
In you session, open up a terminal and run
$ xinput list
⎡ Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ xwayland-pointer:16 id=6 [slave pointer (2)]
⎜ ↳ xwayland-relative-pointer:16 id=7 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
↳ xwayland-keyboard:16 id=8 [slave keyboard (3)]
So now you can disable the mouse, using the proper id:
xinput set-prop 6 "Device Enabled" 0
Don't use the core pointer, that will not work; so now you still see the cursor but its click does nothing.
You can disable the keyboard the same way
xinput set-prop 8 "Device Enabled" 0
Use 1 to enable them again
This is a manual method, you can turn this into a script autostarted with the session.
xtrlock
Another solution is to use the little utility xtrlock
sudo apt install xtrlock
and then
xtrlock
Your mouse cursor will turn into a lock and typing on the keyboard or clicking will do nothing. But if you type your password, the lock will be removed.
My test shows it does not work on 2 monitors, only one (in wayland) but this is not your setup it seems.
add a comment |
XInput
You can disable mouse and keyboard using libinput
In you session, open up a terminal and run
$ xinput list
⎡ Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ xwayland-pointer:16 id=6 [slave pointer (2)]
⎜ ↳ xwayland-relative-pointer:16 id=7 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
↳ xwayland-keyboard:16 id=8 [slave keyboard (3)]
So now you can disable the mouse, using the proper id:
xinput set-prop 6 "Device Enabled" 0
Don't use the core pointer, that will not work; so now you still see the cursor but its click does nothing.
You can disable the keyboard the same way
xinput set-prop 8 "Device Enabled" 0
Use 1 to enable them again
This is a manual method, you can turn this into a script autostarted with the session.
xtrlock
Another solution is to use the little utility xtrlock
sudo apt install xtrlock
and then
xtrlock
Your mouse cursor will turn into a lock and typing on the keyboard or clicking will do nothing. But if you type your password, the lock will be removed.
My test shows it does not work on 2 monitors, only one (in wayland) but this is not your setup it seems.
add a comment |
XInput
You can disable mouse and keyboard using libinput
In you session, open up a terminal and run
$ xinput list
⎡ Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ xwayland-pointer:16 id=6 [slave pointer (2)]
⎜ ↳ xwayland-relative-pointer:16 id=7 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
↳ xwayland-keyboard:16 id=8 [slave keyboard (3)]
So now you can disable the mouse, using the proper id:
xinput set-prop 6 "Device Enabled" 0
Don't use the core pointer, that will not work; so now you still see the cursor but its click does nothing.
You can disable the keyboard the same way
xinput set-prop 8 "Device Enabled" 0
Use 1 to enable them again
This is a manual method, you can turn this into a script autostarted with the session.
xtrlock
Another solution is to use the little utility xtrlock
sudo apt install xtrlock
and then
xtrlock
Your mouse cursor will turn into a lock and typing on the keyboard or clicking will do nothing. But if you type your password, the lock will be removed.
My test shows it does not work on 2 monitors, only one (in wayland) but this is not your setup it seems.
XInput
You can disable mouse and keyboard using libinput
In you session, open up a terminal and run
$ xinput list
⎡ Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ xwayland-pointer:16 id=6 [slave pointer (2)]
⎜ ↳ xwayland-relative-pointer:16 id=7 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
↳ xwayland-keyboard:16 id=8 [slave keyboard (3)]
So now you can disable the mouse, using the proper id:
xinput set-prop 6 "Device Enabled" 0
Don't use the core pointer, that will not work; so now you still see the cursor but its click does nothing.
You can disable the keyboard the same way
xinput set-prop 8 "Device Enabled" 0
Use 1 to enable them again
This is a manual method, you can turn this into a script autostarted with the session.
xtrlock
Another solution is to use the little utility xtrlock
sudo apt install xtrlock
and then
xtrlock
Your mouse cursor will turn into a lock and typing on the keyboard or clicking will do nothing. But if you type your password, the lock will be removed.
My test shows it does not work on 2 monitors, only one (in wayland) but this is not your setup it seems.
edited Dec 4 at 7:51
answered Nov 30 at 11:12
solsTiCe
5,95422048
5,95422048
add a comment |
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1073102%2fhow-to-show-a-non-interactive-x-session-for-displaying-and-periodically-reload-a%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Why not turn off the screen? Eg.
sleep 1 ; xset dpms force off
[source]. Other than that it sounds like you're after "kiosk mode" which Opera browser used to do really well.– pbhj
Dec 2 at 15:42
@pbhj The kiosk mode is a good hint, will take a look at it. Definitely a valid search word to find a suitable tool!
– PhilLab
Dec 7 at 18:12