]> git.ipfire.org Git - people/ms/ipfire-2.x.git/commitdiff
web: Create a function to show the service status
authorMichael Tremer <michael.tremer@ipfire.org>
Sat, 23 Mar 2024 17:42:13 +0000 (18:42 +0100)
committerMichael Tremer <michael.tremer@ipfire.org>
Mon, 2 Jun 2025 19:46:13 +0000 (19:46 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
html/cgi-bin/ovpnmain.cgi
html/html/themes/ipfire/include/css/style.css

index 06178bea51ff17cc13148410edee080d0c429248..6c4582b47efe8321c9e1c46ec6a01f78f9dafb1c 100644 (file)
@@ -5217,6 +5217,14 @@ END
 
     &Header::openbox('100%', 'LEFT', $Lang::tr{'ovpn roadwarrior settings'});
 
+       # Show the service status
+       &Header::ServiceStatus({
+               $Lang::tr{'ovpn roadwarrior server'} => {
+                       "process" => "openvpn",
+                       "pidfile" => "/var/run/openvpn.pid",
+               }
+       });
+
        print <<END;
     <table width='100%' border='0'>
     <form method='post'>
index f76892aa365288ff0ff95865ba2b9ac09dceb1d7..7479d20c2181b5a0066e1081a66d7ec389df7f55 100644 (file)
@@ -417,6 +417,7 @@ table.form tr.action td form {
        text-align: left;
 }
 
+<<<<<<< HEAD
 .tbl tr:nth-child(odd) td {
        background-color: var(--color-grey);
 }
@@ -440,6 +441,8 @@ table.form tr.action td form {
        background-color: var(--color-yellow);
 }
 
+=======
+>>>>>>> 7b19c1312 (web: Create a function to show the service status)
 .tbl th:first-child {
        border-left: 1px solid #363636;
        border-top: 1px solid #363636;
@@ -493,12 +496,20 @@ table.form tr.action td form {
        font-weight: bold;
 }
 
+<<<<<<< HEAD
 .tbl .status.is-running, .tbl .status.is-connected {
+=======
+.tbl .status.is-running {
+>>>>>>> 7b19c1312 (web: Create a function to show the service status)
        background-color: var(--color-green);
        color: var(--color-green-invert);
 }
 
+<<<<<<< HEAD
 .tbl .status.is-stopped, .tbl .status.is-disconnected {
+=======
+.tbl .status.is-stopped {
+>>>>>>> 7b19c1312 (web: Create a function to show the service status)
        background-color: var(--color-red);
        color: var(--color-red-invert);
 }
@@ -507,6 +518,7 @@ table.form tr.action td form {
        width: 33%;
 }
 
+<<<<<<< HEAD
 .tbl .status.is-connecting {
        background-color: var(--color-orange);
        color: var(--color-orange-invert);
@@ -576,6 +588,8 @@ table.form tr.action td form {
        color: var(--color-black-invert);
 }
 
+=======
+>>>>>>> 7b19c1312 (web: Create a function to show the service status)
 table.fw-nat tbody tr td {
        height: 2.25em;
 }