4 Replies Latest reply on Apr 28, 2003 4:26 AM by Aruna

    deploy on given time

    Aruna Newbie

      hello,
      Currently i'm using jboss-3.0.6.Our system running without any major error. Normally when new upgrade(new .ear file) it is auto deploying.
      I want to give exat time to deploy new version.Thats mean assume we want to give new version on mid night 12.00. when i upload ear it is deploying same time.but i want to it deploy on midnight 12.00.
      Is it posible.If it is posible can you give instruction to do it

      thanks
      pad

        • 1. Re: deploy on given time
          Jon Barnett Master

          Why don't you create a pending directory and use the native OS scheduler to move your deployment files from there to the JBoss deploy directory? Say "at" in an NT/Win2K environment, or "at" or "crontab" in a *nix environment. It seems more sensible to reuse than to re-invent the wheel. More environmentally byte friendly too. :)

          Unless there is a particular problem with using the native OS.

          • 2. Re: deploy on given time
            Aruna Newbie

            hi jonlee,
            Thanks your reply and i will try it. Do you have idea to do it on solaris 8 version. I'm new for solaris too. My project is running on sun server. Please help me jonlee. Thanks again for your valubale reply.

            Thanks
            Pad

            • 3. Re: deploy on given time
              Jon Barnett Master

              The first thing would be to check your "at" and "crontab" commands. If you have a complete installation of Solaris, you should "man at" and "man crontab" to get the manual information on the commands.

              Use the "at" command if you want a one-off execution.

              Use the "crontab" command if you want to execute automatically at a certain time every week, or at a certain time every month and so on.

              What you want is to create a script file that achieves what you want. For example:
              #/bin/sh
              mv /opt/JBoss-3.2.0/server/default/pending/*.war /opt/server/default/deploy

              This simple script just moves *.war files from the pending directory into the deploy directory. You can tighten things up by checking that files exist before moving them but that is an exercise left for the student. ;) Test your script to make sure it runs as you expect - make sure it works as the user you expect to execute the script as.

              Now add it to your crontab for the particular user/account you want to execute the script as. It is a bit beyond scope to cover the exact details for setting up your schedule but there are plenty of examples on-line. Just google it.

              A lot of this is beyond the scope of this forum but the *nix schedulers have plenty of information on-line so you shouldn't have too much an issue getting things running.

              Hope that helps.

              • 4. Re: deploy on given time
                Aruna Newbie

                hey jonlee,
                Thanks for your reply.I will try.If i need help i will contact you.

                Thanks
                pad