Draft: Add Flatpak based sample agent creation doc
3 unresolved threads
3 unresolved threads
Signed-off-by: Sudarshan C P sudarshan.cp2@in.bosch.com
Merge request reports
Activity
Filter activity
requested review from @refi64
1 +++ 2 title = "Creating an Application Agent" 3 weight = 100 4 toc = true 5 6 date = "2022-04-26" 7 8 +++ 9 10 An agent is a non graphical program which runs in the background. Agents can be used for playing music or computing expensive operations like indexing large databases, for example. 184 G_DBUS_INTERFACE_SKELETON (self->tick_board), 185 connection, 186 "/org/apertis/HelloWorld/Agent/TickBoard", 187 error)) 188 { 189 g_warning ("Failed to export TickBoard D-Bus interface (reason: %s)", 190 (*error)->message); 191 } 192 193 return ret; 194 } 195 ``` 196 197 Note that it is recommended that an application registers as above before exporting any other interfaces to D-Bus. 198 199 # Flatpak 234 $ cd helloworld-simple-agent 235 $ flatpak-builder --repo=repo --force-clean build-dir flatpak-recipe.yaml 236 ``` 237 238 - Install 239 240 ``` 241 $ cd helloworld-simple-agent 242 $ flatpak --if-not-exists --user remote-add --no-gpg-verify helloworld-simple-agent repo/ 243 $ flatpak install -y helloworld-simple-agent org.apertis.headless.helloworld-simple-agent 244 ``` 245 - Running the agent 246 247 ``` 248 $ cd helloworld-simple-agent 249 $ flatpak run org.apertis.headless.helloworld-simple-agent