Good afternoon. My name is Alexey I write for the first time, hoping to get advice from you Recently I started to try building a programs into Snap package. I need to build a demon. But unfortunatly there was a many problems due working. I faced on the lacking of documentation and description of the principle operation with demons. I will try to describe the work and attaching a file with yaml file and binary file (f2d). The system should work with 2 demons, snmpd and my own sub-agent. snmp service is working with system. sub-agent is handle our requests, which are not known for the snmpd. snmp should be able to "--start" and "--stop". sub-agent can running with different keys, for example ./f2d -Lo -n
My questions: 1. How to make packaging into snap pack with 2 demons if I want a program running only by root and with the keys? 2. How to work with file out of $SNAP? 3. I collect snmp, he unpackage /etc/snmp/snmpd.conf and then I want to replace it by my own snmpd.conf. how to do it? 4. The system have snmp. Could I install and work with other snmp in a program, if snmp was build in snap package? The archive contains files *.mib.txt with information for snmp. If main snmpd doesn't knows *.mib.txt data they have sent sub-agent f2d. f2d - sub-agent f2d.dat - a data file which running with sub-agent and verify his changes. The file can be changed. In that build file must be located in /etc/snmp.data/f2d.dat Thank you for your attention! I really count upon your help. I would be deeply grateful for all your advice. Sincerely, Alexey snapcraft.yaml name: f2d version: 0.1 summary: This is my-snap's summary description: test snmp demon confinement: strict parts: f2d: plugin: copy files: bin/f2d : usr/bin/f2d bin/Alexey.MIB.txt : usr/share/snmp/mibs/alexey1.mib.txt bin/f2d.mib.txt : usr/share/snmp/mibs/f2d.mib.txt bin/f2d.dat : /etc/snmp.data/f2d.dat bin/snmpd.conf : etc/snmp/snmpd.conf integration: plugin: nil stage-packages: - snmp - snmpd - smitools apps: f2d: command: usr/bin/f2d daemon: simple snmpd: command: etc/init.d/snmpd --start stop-command: etc/init.d/snmpd --stop daemon: forking plugs: ['network']
-- Snapcraft mailing list Snapcraft@lists.snapcraft.io Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/snapcraft