-
-
Save ernestl/80d8f1df1be8d9a011ca368881ffab44 to your computer and use it in GitHub Desktop.
Snapd timer invoked oneshot service
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module github.com/ernestl/hello-world | |
go 1.19 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
"time" | |
) | |
func main() { | |
fmt.Println("Hello world running starting...") | |
for { | |
fmt.Println("Hello World!") | |
time.Sleep(2 * time.Second) | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: hello-world-service | |
base: core20 | |
version: '0.1' | |
summary: Hello world service | |
description: | | |
Prints "hello world" in the journal every 2 seconds | |
grade: stable | |
confinement: strict | |
apps: | |
print-hello: | |
command: bin/hello-world | |
daemon: simple | |
parts: | |
hello-world: | |
plugin: go | |
source-type: local | |
source: . | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment