Skip to content

Commit

Permalink
Merge pull request #1743 from bakaphp/feat-octane-frankenphp
Browse files Browse the repository at this point in the history
  • Loading branch information
rwhite27 committed Jul 30, 2024
2 parents 423c014 + cb8092f commit 34b4086
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 7 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,7 @@ service-account.json
/tools/*
/tools/php-cs-fixer/*
/tools/php-cs-fixer/vendor/*

/caddy
frankenphp
frankenphp-worker.php
13 changes: 13 additions & 0 deletions Caddyfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,19 @@ http://localhost {
# Enable compression (optional)
encode zstd br gzip

@options_method {
method OPTIONS
}

handle @options_method {
header Access-Control-Allow-Origin "*"
header Access-Control-Allow-Methods "GET, POST, OPTIONS, PUT, DELETE"
header Access-Control-Allow-Headers "DNT,X-CustomHeader,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Content-Range,Range,Public-Key,Authorization,X-Kanvas-App,X-Kanvas-Key,X-Kanvas-Location"
header Access-Control-Max-Age "1728000"
header Content-Type "text/plain charset=UTF-8"
respond "" 204
}

php_fastcgi /php-fpm
# Execute PHP files from the public/ directory and serve assets
php_server
Expand Down
6 changes: 3 additions & 3 deletions docker-compose.1.x.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ x-common-queue-settings: &common-queue-settings
restart: always
build:
context: .
dockerfile: development.Dockerfile
dockerfile: 1.x.Dockerfile
extra_hosts:
- "host.docker.internal:host-gateway"
command:
Expand All @@ -28,7 +28,7 @@ services:
container_name: php${APP_CONTAINER_NAME}
build:
context: .
dockerfile: development.Dockerfile
dockerfile: 1.x.Dockerfile
extra_hosts:
- "host.docker.internal:host-gateway"
environment:
Expand Down Expand Up @@ -88,7 +88,7 @@ services:
restart: always
build:
context: .
dockerfile: development.Dockerfile
dockerfile: 1.x.Dockerfile
extra_hosts:
- "host.docker.internal:host-gateway"
command:
Expand Down
6 changes: 3 additions & 3 deletions docker-compose.development.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ x-common-queue-settings: &common-queue-settings
restart: always
build:
context: .
dockerfile: development.Dockerfile
dockerfile: franken.Dockerfile
extra_hosts:
- "host.docker.internal:host-gateway"
command:
Expand All @@ -28,7 +28,7 @@ services:
container_name: php${APP_CONTAINER_NAME}
build:
context: .
dockerfile: development.Dockerfile
dockerfile: franken.Dockerfile
extra_hosts:
- "host.docker.internal:host-gateway"
environment:
Expand Down Expand Up @@ -88,7 +88,7 @@ services:
restart: always
build:
context: .
dockerfile: development.Dockerfile
dockerfile: franken.Dockerfile
extra_hosts:
- "host.docker.internal:host-gateway"
command:
Expand Down
2 changes: 1 addition & 1 deletion franken.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM dunglas/frankenphp as base
FROM dunglas/frankenphp

ENV SERVER_NAME="http://"

Expand Down

0 comments on commit 34b4086

Please sign in to comment.