AnswerBun.com

Run script with user input during startup before xfce

Ask Ubuntu Asked on November 23, 2021

I’m trying to create configuration script that is doing some network related configuration during system startup. This configuration needs user input, so start process should be stopped and continued after script finishes. I created my service with such config file:

[Unit]
Description=Check config
After=network.target
Before=network-online.target

[Service]
Type=oneshot
TTYPath=/dev/tty13
ExecStartPre=/usr/bin/chvt 13
ExecStart=/opt/custom/config_script.sh
ExecStartPost=/usr/bin/chvt 1
TimeoutStartSec=0
StandardInput=tty
TTYVHangup=yes
TTYVTDisallocate=yes

[Install]
WantedBy=multi-user.target

I enabled my service and after reboot I see that it is executed. It shows that user input is expected, but start process doesn’t stop and soon after that XFCE is started. I have no chance to enter my input, so the script could finish. How can I achieve expected behavior? I use live USB with persistence, but this probably doesn’t affect this case.

Add your own answers!

Related Questions

“Konversation” Dictionary

0  Asked on November 18, 2021 by ron-piggott

     

How can I record sound in background

0  Asked on November 18, 2021

     

Configure GRE tunnel to start on reboot?

1  Asked on November 16, 2021 by gulamerah

   

Can’t install aptik package on ubuntu 15.04

2  Asked on November 16, 2021 by user1099913

   

KDE Apps on Ubuntu 20.04 – Right Click Issue

1  Asked on November 16, 2021 by timothy-c-quinn

       

Where are the Xubuntu download verification check sums?

2  Asked on November 16, 2021 by friendfx

   

Ask a Question

Get help from others!

© 2023 AnswerBun.com. All rights reserved. Sites we Love: PCI Database, MenuIva, UKBizDB, Menu Kuliner, Sharing RPP, SolveDir