Skip to content

How run Cronicle Service as Spesific User ? #792

Open
@hasanbasri1993

Description

Summary

i got error when run as root, i need run as user: pi

Traceback (most recent call last):
  File "on.py", line 7, in <module>
    bus = smbus.SMBus(DEVICE_BUS)
IOError: [Errno 13] Permission denied
High Performance MPEG 1.0/2.0/2.5 Audio Player for Layer 1, 2, and 3.
Version 0.3.2-1 (2012/03/25). Written and copyrights by Joe Drew,
now maintained by Nanakos Chrysostomos and others.
Uses code from various people. See 'README' for more!
THIS SOFTWARE COMES WITH ABSOLUTELY NO WARRANTY! USE AT YOUR OWN RISK!
tcgetattr(): Inappropriate ioctl for device
Title	: 15 Menit Sebelum Masuk         Artist : Moch Rizki                    
Album	: Bel Kbm                        Year	 : 2021
Comment :                                Genre : Opera                         

Directory: /home/pi/media/kbm
Playing MPEG stream from 15menit_sebelum.mp3 ...
MPEG 1.0 layer III, 128 kbit/s, 48000 Hz joint-stereo
ALSA lib pcm.c:2565:(snd_pcm_open_noupdate) Unknown PCM front
Can't find a suitable libao driver. (Is device in use?)
High Performance MPEG 1.0/2.0/2.5 Audio Player for Layer 1, 2, and 3.
Version 0.3.2-1 (2012/03/25). Written and copyrights by Joe Drew,
now maintained by Nanakos Chrysostomos and others.
Uses code from various people. See 'README' for more!
THIS SOFTWARE COMES WITH ABSOLUTELY NO WARRANTY! USE AT YOUR OWN RISK!
tcgetattr(): Inappropriate ioctl for device

Directory: /home/pi/media
Playing MPEG stream from jaros_panjang.mp3 ...
MPEG 1.0 layer III, 256 kbit/s, 44100 Hz stereo
ALSA lib pcm.c:2565:(snd_pcm_open_noupdate) Unknown PCM front
Can't find a suitable libao driver. (Is device in use?)
Traceback (most recent call last):
  File "off.py", line 7, in <module>
    bus = smbus.SMBus(DEVICE_BUS)
IOError: [Errno 13] Permission denied

Steps to reproduce the problem

Your Setup

Operating system and version?

Raspberry OS

Node.js version?

v16.7.0

Cronicle software version?

Version 0.9.59

Are you using a multi-server setup, or just a single server? single server

Are you using the filesystem as back-end storage, or S3/Couchbase? no

Can you reproduce the crash consistently?

When set npm run boot
After restart will run service as root

I must stop using sudo
Then start in user pi

Log Excerpts

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions