Skip to content

Commit

Permalink
Merge branch '2.1' of github.com:sulu/skeleton into 2.2
Browse files Browse the repository at this point in the history
  • Loading branch information
niklasnatter committed Jan 29, 2021
2 parents f3463f9 + 594963d commit 1e5bd4b
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
9 changes: 8 additions & 1 deletion .github/workflows/test-application.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,12 @@ on:
branches:
- '[0-9]+.x'
- '[0-9]+.[0-9]+'
schedule:
- cron: "0 0 * * *"

jobs:
test:
name: "Test and build with php ${{ matrix.php-version }} and Node.js ${{ matrix.node-version }}"
name: "PHP ${{ matrix.php-version }} and Node.js ${{ matrix.node-version }}"
runs-on: ubuntu-latest

strategy:
Expand Down Expand Up @@ -144,6 +146,11 @@ jobs:
env: ${{ matrix.env }}
working-directory: ${{ matrix.working-directory }}

- name: Test download-language script
run: bin/adminconsole sulu:admin:download-language nl
env: ${{ matrix.env }}
working-directory: ${{ matrix.working-directory }}

- name: Install and configure Node
uses: actions/setup-node@v1
with:
Expand Down
6 changes: 3 additions & 3 deletions public/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@
Debug::enable();
}

if ($trustedProxies = $_SERVER['TRUSTED_PROXIES'] ?? $_ENV['TRUSTED_PROXIES'] ?? false) {
Request::setTrustedProxies(\explode(',', $trustedProxies), Request::HEADER_X_FORWARDED_ALL ^ Request::HEADER_X_FORWARDED_HOST);
if ($trustedProxies = $_SERVER['TRUSTED_PROXIES'] ?? false) {
Request::setTrustedProxies(explode(',', $trustedProxies), Request::HEADER_X_FORWARDED_FOR | Request::HEADER_X_FORWARDED_PORT | Request::HEADER_X_FORWARDED_PROTO);
}

if ($trustedHosts = $_SERVER['TRUSTED_HOSTS'] ?? $_ENV['TRUSTED_HOSTS'] ?? false) {
if ($trustedHosts = $_SERVER['TRUSTED_HOSTS'] ?? false) {
Request::setTrustedHosts([$trustedHosts]);
}

Expand Down

0 comments on commit 1e5bd4b

Please sign in to comment.