Skip to content
This repository has been archived by the owner on May 31, 2024. It is now read-only.

fix: Use ExtraHosts only for linux machines with native docker engine #461

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

MortalHappiness
Copy link
Member

TL;DR

Use ExtraHosts only for Linux machines with native docker engine

Type

  • Bug Fix
  • Feature
  • Plugin

Are all requirements met?

  • Code completed
  • Smoke tested
  • Unit tests added
  • Code documentation added
  • Any pending items have an associated Issue

Complete description

Detect whether /var/run/docker.sock is not a symbolic link and is a socket file. If true, add ExtraHosts. Otherwise, return empty ExtraHosts.

Tracking Issue

None

Follow-up issue

NA

Copy link

codecov bot commented Feb 14, 2024

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (9c87165) 67.69% compared to head (878526f) 67.71%.

❗ Current head 878526f differs from pull request most recent head 7c83a52. Consider uploading reports for the commit 7c83a52 to get more accurate results

Files Patch % Lines
pkg/docker/docker_util.go 88.88% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #461      +/-   ##
==========================================
+ Coverage   67.69%   67.71%   +0.02%     
==========================================
  Files         148      148              
  Lines        6639     6647       +8     
==========================================
+ Hits         4494     4501       +7     
- Misses       1855     1856       +1     
  Partials      290      290              
Flag Coverage Δ
unittests 67.71% <88.88%> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

pkg/docker/docker_util.go Outdated Show resolved Hide resolved
@MortalHappiness MortalHappiness force-pushed the bugfix/remove-non-native-linux-docker-extrahosts branch from 878526f to f88817d Compare February 15, 2024 06:11
@MortalHappiness MortalHappiness marked this pull request as draft February 15, 2024 06:16
Signed-off-by: Chi-Sheng Liu <chishengliu@chishengliu.com>
@MortalHappiness MortalHappiness force-pushed the bugfix/remove-non-native-linux-docker-extrahosts branch from f88817d to 7c83a52 Compare February 15, 2024 06:50
@MortalHappiness MortalHappiness marked this pull request as ready for review February 15, 2024 06:50
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants