Jump to content

adhitya syahputra

Members
  • Posts

    6
  • Reputation

    0
  • Files

    0
  • Rank

    Newbie
  • Joined

  • Last visited

About adhitya syahputra

  • Birthday May 15

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

adhitya syahputra's Achievements

Newbie

Newbie (1/14)

  • Reacting Well
  • First Post
  • Dedicated Rare
  • One Year In
  • Week One Done

Recent Badges

0

Reputation

  1. its my server.js /** * EXPRESS FOR ROUTING */ const serverOptions = { key: fs.readFileSync('/home/cert/total/privkey.pem'), cert: fs.readFileSync('/home/cert/total/cert.csr') } const express = require("express"); const app = express(); const https = require("https"); const server = https.createServer(serverOptions, app); /** it's my web.php Route::post('/settings/check_database_connection',[SettingController::class,'test_database_connection'])->name('connectDB'); Route::post('/settings/activate_license',[SettingController::class,'activate_license'])->name('activateLicense'); URL::forceScheme('https'); }); ?>
  2. 1- Open the .htaccess in the root path of the script and clear all code and save it. 2-Then, we will edit the server.js file and replace this code from: /** * EXPRESS FOR ROUTING */ const express = require("express"); const app = express(); const http = require("http"); const server = http.createServer(app); To: /** * EXPRESS FOR ROUTING */ const serverOptions = { key: fs.readFileSync('key.pem'), # key.pem is your ssl key cert: fs.readFileSync('cert.pem') #cert.pem is your ssl cert } const express = require("express"); const app = express(); const https = require("https"); const server = https.createServer(serverOptions, app); 3- edit the routes/web.php file and add this code at the end of the file: URL::forceScheme('https'); 4- Open .htaccess again, put the following code inside and save: <IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{REQUEST_URI} !^/socket.io/ RewriteCond %{REQUEST_URI} !^/backend-* RewriteCond %{REQUEST_URI} !^/public/ RewriteRule ^(.*)$ /public/$1 [L,QSA] </IfModule> <IfModule mod_security.c> SecFilterEngine Off SecFilterScanPOST Off </IfModule> 5- Restart your node.js project
  3. can we run the apps on https and show qr code succesfully on aapanel?
  4. Can we add spintext on auto reply @Magd Almuntaser?
×
  • Create New...