Class Scripts

java.lang.Object
org.bgerp.app.dist.Scripts

public class Scripts extends Object
Distribution's scripts.
  • Constructor Details

    • Scripts

      public Scripts()
      Default constructor
  • Method Details

    • backup

      public Scripts backup(boolean db) throws Exception
      Runs the backup script.
      Parameters:
      db - whether to also back up the database
      Returns:
      this
      Throws:
      Exception - on a script error
    • backupRestore

      public Scripts backupRestore(String name) throws Exception
      Restores a backup by name.
      Parameters:
      name - backup name
      Returns:
      this
      Throws:
      Exception - on a script error
    • update

      public Scripts update(boolean force) throws Exception
      Runs the update script.
      Parameters:
      force - force update
      Returns:
      this
      Throws:
      Exception - on a script error
    • restart

      public Scripts restart(boolean force) throws Exception
      Restarts the application, or stops the container when running under Docker.
      Parameters:
      force - force restart
      Returns:
      this
      Throws:
      Exception - on a script error
    • install

      public Scripts install(List<String> files) throws Exception
      Installs the given update files.
      Parameters:
      files - update file names
      Returns:
      this
      Throws:
      Exception - on a script error
    • installc

      public Scripts installc(String changeId) throws Exception
      Installs a change by ID.
      Parameters:
      changeId - change ID
      Returns:
      this
      Throws:
      Exception - on a script error