Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  1. First, install all the Frontend Requirements listed above & verify the backend/REST API is publicly accessible.
  2. Download the latest dspace-angular release from the DSpace GitHub repository. You can choose to either download the zip or tar.gz file provided by GitHub, or you can use "git" to checkout the appropriate tag (e.g. dspace-7.0-beta5) or branch.
  3. Install all necessary local dependencies by running the following from within the unzipped "dspace-angular" directory

    Code Block
    # change directory to our repo
    cd dspace-angular
    
    # install the local dependencies
    yarn install


  4. Create a Production Configuration file at [dspace-angular]/src/environment/environment.prod.ts. This file can be used to override any of the default configurations specified in the environment.common.ts (in that same directory).  At a minimum this file MUST include the "ui" and "rest" section sections similar to the following (keep in mind, you only need to include settings that you need to modify)

    Code Block
    export const environment = {
      // This example is valid if your Backend is publicly available at https://api.mydspace.edu/server/ 
      // It should be kept in sync with the value of "dspace.server.url" in the backend's local.cfg
      rest: { 
          ssl: true, 
          host: 'api.mydspace.edu',
          port: 80, 
          // NOTE: Space is capitalized because 'namespace' is a reserved string in TypeScript
          nameSpace: '/server' 
      }
    };
    Modify the Frontend configuration to point at your DSpace BackendBy default the Frontend will be configured to use the Demo Backend at 
      // This example is valid if your UI will be running at https://
    api7.dspace.org/server/

    Modify the "rest" section of the [dspace-angular]/src/environment/environment.common.ts configuration file, pointing it at your installed DSpace Backend.  For example:

    Code Block
    // This example is valid if your Backend is running at http://localhost:8080/server/
    // It should be kept in sync with the value of "dspace.server.url" in the backend local.cfg
    rest: {
       ssl: false,
       host: 'localhost',
       port: 8080,
       // NOTE: Space is capitalized because 'namespace' is a reserved string in TypeScript
       nameSpace: '/server'
    }
    (If necessary) modify the "ui" section of the [dspace-angular]/src/environment/environment.common.ts configuration file to match the host & port that you plan to run the UI from.  By default, these settings assume you will run the UI from http://localhost:4000/ Code Block// This example is valid if your UI will be running at http://localhost:4000 // It should
    mydspace.edu/ 
      // It should be kept in sync with the value of "dspace.ui.url" in the backend local.cfg 
      ui: { 
          ssl: 
    false
    true, 
          host: '
    localhost
    mydspace.edu', 
          port: 4000, 
          // NOTE: Space is capitalized because 'namespace' is a reserved string in TypeScript
          nameSpace: '/' 
      }
    };


    1. If there are other settings you know you need to modify in the default Alternatively, if you want, you can copy the "environment.common.ts" to a new file called "environment.prod.ts" and modify that new configuration file you can also copy them into this same file.
  5. Start the application

    Code Block
    # build and start the application
    yarn start


    1. To stop the application at any time, use Ctrl + C
  6. After a few minutes, the user interface will be running on your local machine. 
    1. Visit http://localhost:4000/
    2. For an example of what the default frontend looks like, visit the Demo Frontend:  https://dspace7-demodemo7.atmiredspace.comorg/ 

What Next?

After a successful installation, you may want to take a closer look at

...