To reboot VPS 5 minutes after midnight everyday:
Login via SSH and run the following:
echo shutdown -r now > /root/shutdown.sh;chmod +x /root/shutdown.sh
Then run crontab -e and enter this line:
5 0 * * * /root/shutdown.sh
Then save and exit.
by dev
To reboot VPS 5 minutes after midnight everyday:
Login via SSH and run the following:
echo shutdown -r now > /root/shutdown.sh;chmod +x /root/shutdown.sh
Then run crontab -e and enter this line:
5 0 * * * /root/shutdown.sh
Then save and exit.
by dev
Add the following line above your rule to exclude a directory (for example, journal) from rewrite rule
RewriteRule ^(journal)($|/) - [L]
To exclude multiple folders, use the following condition above your rule
RewriteCond %{REQUEST_URI} !^/(folder1|folder2/.*)$
OR
RewriteRule ^(folder1|folder2)($|/) - [L]
To exclude all existent directories, you will need to use the following condition above your rule
RewriteCond %{REQUEST_FILENAME} !-d
by dev
Solutions:
Check /var/vmail/* permission
drwx------ 4 vmail mail 34 ene 16 14:01 domain.tld
Or try update roundcube
sh /scripts/mail_roundcube_update
by dev
Open the file IssueHandler.inc.php at pages/issue/IssueHandler.inc.php and under the function “$showToc” (search and find) add the following code.
$pubIdPlugins = PluginRegistry::loadCategory('pubIds', true); $templateMgr->assign('pubIdPlugins', $pubIdPlugins);
Now add DOI code to the article_summary.tpl
{* DOI (requires plugin) *} {* CCDN *} {foreach from=$pubIdPlugins item=pubIdPlugin} {if $pubIdPlugin->getPubIdType() != 'doi'} {continue} {/if} {assign var=pubId value=$article->getStoredPubId($pubIdPlugin->getPubIdType())} {if $pubId} {assign var="doiUrl" value=$pubIdPlugin->getResolvingURL($currentJournal->getId(), $pubId)|escape} <div class="itemdoi"> <span class="doilabel"> <img src="https://demo.codexcafe.net/ojs3/plugins/themes/ajsrp/img/doi_logo.jpg" width="20"> {capture assign=translatedDOI}{translate key="plugins.pubIds.doi.readerDisplayName"}{/capture} {translate key="semicolon" label=$translatedDOI} </span> <span class="doivalue"> <a {if $journal}href="{url journal=$journal->getPath() page="article" op="view" path=$articlePath}"{else}href="{url page="article" op="view" path=$articlePath}"{/if}> {$pubId} </a> </span> </div> {/if} {/foreach}
That’s all!
by dev
How to change the SSH port
vi /etc/ssh/sshd_config
Port 1234
/scripts/restartsrv_sshd
or
sudo systemctl restart ssh.service
ssh USER@HOSTNAME -p1234
Use your USER and HOSTNAME and the password and confirm new port.
If the SSH test on the new port is successful you can close the connection. If it is not successful, this SSH connection should not be closed until the SSH test on the new port is successful. Else revert the port to previous state and restart.
find / -name “sshd_config” -print
/usr/share/openssh/sshd_config
/etc/ssh/sshd_config
find / -name “sshd_config” 2>/dev/null
vi /usr/share/openssh/sshd_config
vi /etc/nftables.conf
ufw allow 1234/tcp
vi /etc/services
systemctl restart ssh
service ssh restart
systemctl restart ssh.service
ssh root@server_ip -p NEW_PORT
ssh root@123.512.11.6 -p 1234