File tree Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -333,6 +333,16 @@ export class Http1Server implements Printable {
333
333
} ) ;
334
334
}
335
335
336
+ // The /up endpoint is used by Kamal.
337
+ public enableKamalPing ( path = '/up' , response : string | Uint8Array = 'yes' ) {
338
+ this . route ( {
339
+ path,
340
+ handler : ( ctx ) => {
341
+ ctx . res . end ( response ) ;
342
+ } ,
343
+ } ) ;
344
+ }
345
+
336
346
// ---------------------------------------------------------------- Printable
337
347
338
348
public toString ( tab = '' ) : string {
Original file line number Diff line number Diff line change @@ -72,7 +72,9 @@ export class RpcServer implements Printable {
72
72
}
73
73
74
74
public enableHttpPing ( ) : void {
75
- this . http1 . enableHttpPing ( ) ;
75
+ const http1 = this . http1 ;
76
+ http1 . enableHttpPing ( ) ;
77
+ http1 . enableKamalPing ( ) ;
76
78
}
77
79
78
80
public enableCors ( ) : void {
You can’t perform that action at this time.
0 commit comments