Skip to content

Configure the Web Panel

Dave edited this page Dec 28, 2023 · 4 revisions

Note: This has not been fully tested on Windows or with Controller -> Target setup

1. Enable the Web Panel Setting:

  • Navigate to Settings > Discord Bot Settings in your AMP instance.
  • Enable the relevant setting.
  • Restart the instance to apply changes.
  • Ensure that a WebPanel-[InstanceName] directory is created in the instance folder.

2. Configure the Folders for Accessibility:

  • Create a new folder within your AMP instance to host the panel(s). This should be located inside the WebRoot directory.
    • For Linux: As your AMP user run the command mkdir -p /home/amp/.ampdata/instances/[ADS Name]/WebRoot/WebPanels/. Replace [ADS Name] with your ADS name.
    • For Windows: As your AMP user run the following in cmd/powershell/terminal mkdir C:\AMPDatastore\Instances\[ADS Name]\WebRoot\WebPanels. Ensure the correct drive and instance name are used.

3. Setting Up a Symlink to the HTML File:

  • Create a symbolic link (Symlink) from the WebPanel directory to the WebRoot.
    • For Linux: As your AMP user Execute ln -s /home/amp/.ampdata/instances/[Instance Name]/WebPanel-[InstanceName]/ /home/amp/.ampdata/instances/[ADS Name]/WebRoot/WebPanels/. Substitute [Instance Name] and [ADS Name] appropriately.
    • For Windows: As your AMP user run the following in cmd/powershell/terminal mklink /D C:\AMPDatastore\Instances\[ADS Name]\WebRoot\WebPanels\ C:\AMPDatastore\Instances\[Instance Name]\WebPanel-[InstanceName]\. Ensure the correct drive and instance names are used.

4. Accessing and Embedding the Web Panel:

  • Open your web browser and navigate to the panel by appending /WebPanels/WebPanel-[InstanceName]/panel.html to your AMP instance URL.
  • For embedding this panel into another site, a minimum width of 600px is recommended.

Additional Tips:

  • Troubleshooting: If you encounter issues, such as the symlink not creating or the panel not appearing, verify the paths and ensure that your commands were run as the AMP user.
  • Further Assistance: Create an Issue or message on Discord.