ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
All Data Structures Namespaces Files Functions Variables Modules Pages
ILIAS\Setup\CLI\InstallCommand Class Reference

Installation command. More...

+ Inheritance diagram for ILIAS\Setup\CLI\InstallCommand:
+ Collaboration diagram for ILIAS\Setup\CLI\InstallCommand:

Public Member Functions

 configure ()
 
 execute (InputInterface $input, OutputInterface $output)
 
- Public Member Functions inherited from ILIAS\Setup\CLI\BaseCommand
 __construct (callable $lazy_agent, ConfigReader $config_reader, array $preconditions)
 
 configure ()
 
 execute (InputInterface $input, OutputInterface $output)
 

Protected Member Functions

 printIntroMessage (IOWrapper $io)
 
 printOutroMessage (IOWrapper $io)
 
 buildEnvironment (Agent $agent, ?Config $config, IOWrapper $io)
 
 getObjective (Agent $agent, ?Config $config)
 
- Protected Member Functions inherited from ILIAS\Setup\CLI\BaseCommand
 getAgent ()
 
 shouldSayYes (InputInterface $input)
 
 printLicenseMessage (IOWrapper $io, InputInterface $input)
 
 printIntroMessage (IOWrapper $io)
 
 printOutroMessage (IOWrapper $io)
 
 readAgentConfig (Agent $agent, InputInterface $input)
 
 buildEnvironment (Agent $agent, ?Config $config, IOWrapper $io)
 
 getObjective (Agent $agent, ?Config $config)
 

Static Protected Attributes

static $defaultName = "install"
 
- Static Protected Attributes inherited from ILIAS\Setup\CLI\BaseCommand
static $defaultName = "install"
 

Additional Inherited Members

- Protected Attributes inherited from ILIAS\Setup\CLI\BaseCommand
 $lazy_agent
 
 $agent
 
 $config_reader
 
 $preconditions
 var Objective[] More...
 

Detailed Description

Installation command.

Definition at line 20 of file InstallCommand.php.

Member Function Documentation

◆ buildEnvironment()

ILIAS\Setup\CLI\InstallCommand::buildEnvironment ( Agent  $agent,
?Config  $config,
IOWrapper  $io 
)
protected

Definition at line 48 of file InstallCommand.php.

References ILIAS\Setup\Environment\RESOURCE_ACHIEVEMENT_TRACKER, ILIAS\Setup\Environment\RESOURCE_ADMIN_INTERACTION, and ILIAS\Setup\ArrayEnvironment\withConfigFor().

48  : Environment
49  {
50  $environment = new ArrayEnvironment([
52  // TODO: This needs to be implemented correctly...
53  Environment::RESOURCE_ACHIEVEMENT_TRACKER => new class implements AchievementTracker {
54  public function trackAchievementOf(Objective $objective) : void
55  {
56  }
57  public function isAchieved(Objective $objective) : bool
58  {
59  return false;
60  }
61  }
62  ]);
63 
64  if ($agent instanceof AgentCollection && $config) {
65  foreach ($config->getKeys() as $k) {
66  $environment = $environment->withConfigFor($k, $config->getConfig($k));
67  }
68  }
69 
70  return $environment;
71  }
if(!array_key_exists('PATH_INFO', $_SERVER)) $config
Definition: metadata.php:68
+ Here is the call graph for this function:

◆ configure()

ILIAS\Setup\CLI\InstallCommand::configure ( )

Definition at line 24 of file InstallCommand.php.

25  {
26  parent::configure();
27  $this->setDescription("Creates a fresh ILIAS installation based on the config");
28  }

◆ execute()

ILIAS\Setup\CLI\InstallCommand::execute ( InputInterface  $input,
OutputInterface  $output 
)

Definition at line 40 of file InstallCommand.php.

41  {
42  // ATTENTION: This is a hack to get around the usage of the echo/exit pattern in
43  // the setup for the command line version of the setup. Do not use this.
44  define("ILIAS_SETUP_IGNORE_DB_UPDATE_STEP_MESSAGES", true);
45  return parent::execute($input, $output);
46  }

◆ getObjective()

ILIAS\Setup\CLI\InstallCommand::getObjective ( Agent  $agent,
?Config  $config 
)
protected

Definition at line 73 of file InstallCommand.php.

References ILIAS\Setup\Agent\getInstallObjective(), and ILIAS\Setup\Agent\getUpdateObjective().

73  : Objective
74  {
75  return new ObjectiveCollection(
76  "Install and update ILIAS",
77  false,
78  $agent->getInstallObjective($config),
79  $agent->getUpdateObjective($config)
80  );
81  }
if(!array_key_exists('PATH_INFO', $_SERVER)) $config
Definition: metadata.php:68
+ Here is the call graph for this function:

◆ printIntroMessage()

ILIAS\Setup\CLI\InstallCommand::printIntroMessage ( IOWrapper  $io)
protected

Definition at line 30 of file InstallCommand.php.

References ILIAS\Setup\CLI\IOWrapper\title().

31  {
32  $io->title("Installing ILIAS");
33  }
+ Here is the call graph for this function:

◆ printOutroMessage()

ILIAS\Setup\CLI\InstallCommand::printOutroMessage ( IOWrapper  $io)
protected

Definition at line 35 of file InstallCommand.php.

References ILIAS\Setup\CLI\IOWrapper\success().

36  {
37  $io->success("Installation complete. Thanks and have fun!");
38  }
+ Here is the call graph for this function:

Field Documentation

◆ $defaultName

ILIAS\Setup\CLI\InstallCommand::$defaultName = "install"
staticprotected

Definition at line 22 of file InstallCommand.php.


The documentation for this class was generated from the following file: