Navigation

    Netgate Discussion Forum
    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search

    SSH auto script

    General pfSense Questions
    2
    3
    372
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • C
      CC last edited by

      So we are locking SSH down to keyed only accounts, multiple admins mean multiple keys, means multiple users; right now when you log into SSH on any account other then admin you don't get the menu (mostly used for  "16 - Restart PHP-FPM" when the GUI decides to not play any more).

      Is there any way of running a script on SSH login to run "sudo /etc/rc.initial" (the sudo part works fine, just want it to run it when users login)

      I've tried the usual linuxy things like .profile and  .bashrc

      Can anyone help please?

      1 Reply Last reply Reply Quote 0
      • C
        CC last edited by

        Sorry to bump but can anyone help?

        1 Reply Last reply Reply Quote 0
        • H
          heper last edited by

          check .profile  and .shrc in the root directory.

          copying those to the other users might do the trick

          1 Reply Last reply Reply Quote 0
          • First post
            Last post