File tree Expand file tree Collapse file tree 2 files changed +15
-3
lines changed
Expand file tree Collapse file tree 2 files changed +15
-3
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,9 @@ services:
1212 interval : 2s
1313 timeout : 10s
1414 retries : 5
15+ depends_on :
16+ imgproxy :
17+ condition : service_healthy
1518 imgproxy :
1619 image : darthsim/imgproxy
1720 environment :
Original file line number Diff line number Diff line change 1- const allowedDomains = process . env . ALLOWED_REMOTE_DOMAINS . split ( "," ) || [ "*" ] ;
2- const imgproxyUrl = process . env . IMGPROXY_URL || "http://imgproxy:8080" ;
3-
1+ const allowedDomains = process ? .env ? .ALLOWED_REMOTE_DOMAINS . split ( "," ) || [ "*" ] ;
2+ const imgproxyUrl = process ? .env ? .IMGPROXY_URL || "http://imgproxy:8080" ;
3+ const version = "0.0.2"
44Bun . serve ( {
55 port : 3000 ,
66 async fetch ( req ) {
77 const url = new URL ( req . url ) ;
8+ if ( url . pathname === "/" ) {
9+ return new Response ( `<h3>Next Image Transformation v${ version } </h3>More info <a href="https://github.com/coollabsio/next-image-transformation">https://github.com/coollabsio/next-image-transformation</a>.` , {
10+ headers : {
11+ "Content-Type" : "text/html" ,
12+ } ,
13+ } ) ;
14+ }
15+
16+
817 if ( url . pathname === "/health" ) {
918 return new Response ( "OK" ) ;
1019 } ;
You can’t perform that action at this time.
0 commit comments