Use /var/ubot as data directory
This commit is contained in:
parent
39c1deacc0
commit
03b5e60a97
2
bin/ubot
2
bin/ubot
@ -2,7 +2,7 @@
|
||||
from telethon import TelegramClient, events
|
||||
from config import *
|
||||
|
||||
client = TelegramClient('ubot', api_id, api_hash)
|
||||
client = TelegramClient('/var/ubot/ubot', api_id, api_hash)
|
||||
|
||||
@client.on(events.NewMessage)
|
||||
async def edit(event):
|
||||
|
6
install
6
install
@ -41,9 +41,9 @@ mkuser(){
|
||||
|
||||
addfiles(){
|
||||
# Install executable and config
|
||||
mkdir /etc/ubot
|
||||
install -o root -g bot -m640 config.py /etc/ubot/config.py
|
||||
install -m755 bin/ubot /usr/bin/ubot
|
||||
install -m770 -o root -g bot /var/ubot
|
||||
install -m640 -o root -g bot config.py /var/ubot/config.py
|
||||
install -m755 -o root -g root bin/ubot /usr/bin/ubot
|
||||
|
||||
# Install service files on installed inits
|
||||
if [ -e /sbin/openrc ]
|
||||
|
Loading…
x
Reference in New Issue
Block a user