Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Bookmarks
  • Search
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

Cloudron Forum

Apps | Demo | Docs | Install
  1. Cloudron Forum
  2. LAMP
  3. [Template] Flarum - Modern, fast & free community software

[Template] Flarum - Modern, fast & free community software

Scheduled Pinned Locked Moved LAMP
2 Posts 2 Posters 166 Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    simong
    wrote on last edited by simong
    #1

    98ca6d3a-9b7a-4928-b339-dce50ab6a083-image.png

    Flarum - The community framework for small to enterprise communities that is extensible, scalable and completely free!

    ea28091b-3029-4604-9681-03b128ae33c2-image.png

    ########################################
    Main Page: https://flarum.org/
    Demo: https://flarum.org/software/demo
    Community: https://discuss.flarum.org
    Docs: https://docs.flarum.org
    ########################################

    Automatic Cloudron Parameters:
    ✅ Database
    ✅ Location (URL)
    ✅ REDIS: Use optional install comment
    ⚠️ MAIL (only on first setup)
    ⚠️ LDAP: Optional Setup
    ❌ App Updates (Done via UI or Composer)


    Installation:

    1. Install LAMP App
    2. Open Terminal and run the Installation Command:
    composer create-project --no-interaction flarum/flarum:^1.8.0 /app/data/flarum && sed -i 's|/app/data/public|/app/data/flarum/public|g' /app/data/apache/app.conf && cd /app/data/flarum && composer require flarum/extension-manager:"*" && (read -p "Admin-User: " username && read -p "Admin-Password: " password && read -p "Admin-Email: " email && read -p "Forum-Name: " forum_title && php -r "file_put_contents('flarum-config.json', json_encode(['debug' => false, 'baseUrl' => 'https://' . getenv('CLOUDRON_APP_DOMAIN'), 'databaseConfiguration' => ['driver' => 'mysql', 'host' => getenv('CLOUDRON_MYSQL_HOST'), 'port' => 3306, 'database' => getenv('CLOUDRON_MYSQL_DATABASE'), 'username' => getenv('CLOUDRON_MYSQL_USERNAME'), 'password' => getenv('CLOUDRON_MYSQL_PASSWORD'), 'prefix' => ''], 'adminUser' => ['username' => '$username', 'password' => '$password', 'email' => '$email'], 'settings' => ['forum_title' => '$forum_title', 'mail_driver' => 'smtp', 'mail_host' => getenv('CLOUDRON_MAIL_SMTP_SERVER'), 'mail_port' => getenv('CLOUDRON_MAIL_SMTP_PORT'), 'mail_encryption' => '', 'mail_username' => getenv('CLOUDRON_MAIL_SMTP_USERNAME'), 'mail_password' => getenv('CLOUDRON_MAIL_SMTP_PASSWORD'), 'mail_from' => getenv('CLOUDRON_MAIL_FROM')]], JSON_PRETTY_PRINT));" && php flarum install --file=flarum-config.json && sed -i -e "s/'host' => '.*'/'host' => getenv('CLOUDRON_MYSQL_HOST')/g" -e "s/'database' => '.*'/'database' => getenv('CLOUDRON_MYSQL_DATABASE')/g" -e "s/'username' => '.*'/'username' => getenv('CLOUDRON_MYSQL_USERNAME')/g" -e "s/'password' => '.*'/'password' => getenv('CLOUDRON_MYSQL_PASSWORD')/g" -e "s/'url' => '.*'/'url' => 'https:\/\/'.getenv('CLOUDRON_APP_DOMAIN')/g" config.php && rm flarum-config.json)
    
    1. restart the app and open the website

    Optional Settings:
    LDAP (Install only - Setup in Admin UI) using credentials.txt from Cloudron File Manager:

    cd /app/data/flarum && composer require yippy/flarum-ext-auth-ldap && php flarum assets:publish
    

    REDIS (Install + Setup):

    cd /app/data/flarum && composer require blomstra/flarum-redis:* && if grep -q "Blomstra\\\\Redis\\\\Extend\\\\Redis" /app/data/flarum/extend.php; then sed -i 's/new Blomstra\\Redis\\Extend\\Redis([^)]*)/new Blomstra\\Redis\\Extend\\Redis([\n        "host" => getenv("CLOUDRON_REDIS_HOST"),\n        "password" => getenv("CLOUDRON_REDIS_PASSWORD"),\n        "port" => getenv("CLOUDRON_REDIS_PORT"),\n        "database" => 1,\n    ])/' /app/data/flarum/extend.php; else sed -i '/return \[/a \ \ \ \ new Blomstra\\Redis\\Extend\\Redis([\n        "host" => getenv("CLOUDRON_REDIS_HOST"),\n        "password" => getenv("CLOUDRON_REDIS_PASSWORD"),\n        "port" => getenv("CLOUDRON_REDIS_PORT"),\n        "database" => 1,\n    ]),' /app/data/flarum/extend.php; fi
    
    1 Reply Last reply
    4
    • S simong referenced this topic on
    • robiR Offline
      robiR Offline
      robi
      wrote on last edited by
      #2

      Well done!

      Super easy @simong

      Conscious tech

      1 Reply Last reply
      2
      • J joseph referenced this topic on
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Bookmarks
      • Search