File tree 2 files changed +30
-0
lines changed
2 files changed +30
-0
lines changed Original file line number Diff line number Diff line change @@ -47,6 +47,27 @@ The source repository contains an `example.env` and an
47
47
cp example-config.json config.json
48
48
# edit config.json
49
49
50
+ ### Hooks
51
+
52
+ flat-manager can be configured to run hook scripts during the upload
53
+ and publish processes. These are configured per-repository in the
54
+ config file; see ` example-config.json ` .
55
+
56
+ The publish hook runs in the build directory before a build is published
57
+ to a main repository. It can modify the build, for example by rewriting
58
+ the appstream files in the commits.
59
+
60
+ Check scripts are run after a build is uploaded. Builds may not be
61
+ published unless all checks have passed. The check is marked as failed
62
+ if the command exits with a nonzero code (or marked as requiring review
63
+ if ` "reviewable": true ` is set).
64
+
65
+ Check scripts may also set their own status via the flat-manager API,
66
+ though this will be overridden if the command exits with a nonzero code.
67
+ To facilitate this, check scripts are run with ` FLAT_MANAGER_BUILD_ID ` and
68
+ ` FLAT_MANAGER_JOB_ID ` environment variables to pass to the API. The same
69
+ endpoint can be used by other systems for manual reviews.
70
+
50
71
## Database
51
72
52
73
flat-manager uses a PostgreSQL database to store information, and
Original file line number Diff line number Diff line change 24
24
"suggested-repo-name" : " testrepo-beta" ,
25
25
"runtime-repo-url" : " https://dl.flathub.org/repo/flathub.flatpakrepo" ,
26
26
"gpg-key" : null ,
27
+ "hooks" : {
28
+ "publish" : [" true" ],
29
+ "checks" : {
30
+ "example-check" : {
31
+ "command" : [" true" ],
32
+ "reviewable" : true
33
+ }
34
+ }
35
+ },
27
36
"subsets" : {
28
37
"all" : {
29
38
"collection-id" : " org.test.Beta" ,
You can’t perform that action at this time.
0 commit comments