Skip to content

New Site Initialisation

Mark Metcalfe edited this page Nov 27, 2024 · 10 revisions

Install a Totara Instance

The following is basic usage for creating a new Totara instance in ~/totara-sites. You may need to adjust for older Totara versions.

Replace <directory name> with the name of new site. It needs to be URL-safe.

If you are part of the Totara team please use the internal Git repository url, otherwise please refer to our help site for more information on how to gain access to the source code. Replace the <repositoryurl> with the correct url.

  1. Windows Only: The following commands need to be run from within the WSL instance (i.e Ubuntu Terminal)
  2. Clone the site. If you've already cloned the site and set up your config.php, skip to step 6
    cd ~/totara-sites
    git clone <repositoryurl> <directory name>
    
  3. Set hosts (if not already defined) by running ~/totara-docker-dev/tools/set_hosts.sh
  4. Copy the template config.php
    cd <directory name>
    cp ~/totara-docker-dev/config.php ./
    
  5. If you wish to use a different database, edit config.php to select the database you wish to use, by commenting and uncommenting lines.
  6. Create a database
    tdb create
    
  7. Build front end assets
    tnpm ci
    tnpm run tui-build
    cd server
    tnpm ci
    tgrunt css
    
  8. Run the site installation script
    cd ..
    tphp install
    

Now visit http://<directory name>.totara83/ - e.g. http://integration.totara83 - happy developing!

If this page is inaccurate for integration branch due to minimum version updates or other issues, please update it.

Clone this wiki locally