Skip to content

Commit

Permalink
try to figure out dns issue in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
CamJN committed Aug 19, 2024
1 parent 07695f1 commit d340616
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ jobs:
ruby-version: ${{ env.DEFAULT_RUBY_VERSION }}
bundler-cache: true
- run: ./dev/ci/setup-host ${{ matrix.integration.label }}
- run: dscacheutil -q host -a name 1.passenger.test
- run: dscacheutil -q host -a name 127.0.0.1
if: matrix.os == 'macos-latest'
- run: ./dev/ci/run-tests-with-docker ${{ matrix.integration.label }}
if: matrix.os == 'ubuntu-latest'
Expand Down
4 changes: 2 additions & 2 deletions test/support/nginx_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def initialize(root_dir, log_file)
@controller = PhusionPassenger::DaemonController.new(
:identifier => 'Nginx',
:start_command => "#{CONFIG['nginx']} -p #{root_dir} -c '#{@config_file}'",
:ping_command => [:tcp, '127.0.0.1', PORT],
:ping_command => [:tcp, 'localhost', PORT],
:pid_file => @pid_file,
:log_file => @log_file,
:timeout => 60,
Expand All @@ -44,7 +44,7 @@ def stop
@controller.stop
# On OS X, the Nginx server socket may linger around for a while
# after Nginx shutdown, despite Nginx setting SO_REUSEADDR.
sockaddr = Socket.pack_sockaddr_in(PORT, '127.0.0.1')
sockaddr = Socket.pack_sockaddr_in(PORT, 'localhost')
eventually(30) do
!@controller.send(:ping_socket, Socket::Constants::AF_INET, sockaddr)
end
Expand Down

0 comments on commit d340616

Please sign in to comment.