-
Notifications
You must be signed in to change notification settings - Fork 317
Switch macOS to test against local server #2750
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
9f7037e to
38f2498
Compare
9f47116 to
a4d4c3f
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #2750 +/- ##
==========================================
+ Coverage 72.71% 72.81% +0.10%
==========================================
Files 283 283
Lines 58996 58997 +1
==========================================
+ Hits 42896 42959 +63
+ Misses 16100 16038 -62
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
eng/pipelines/common/templates/steps/configure-sql-server-macos-step.yml
Show resolved
Hide resolved
|
/azp run |
|
Azure Pipelines successfully started running 2 pipeline(s). |
Don't test Azure AAD connectivity in localhost jobs Don't pass secrets if variables are empty
|
/azp run CI-SqlClient |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
/azp run CI-SqlClient |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
/azp run CI-SqlClient |
|
Azure Pipelines successfully started running 1 pipeline(s). |
cea4c54 to
c7f699d
Compare
|
/azp run CI-SqlClient |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
/azp run CI-SqlClient |
|
Azure Pipelines failed to run 1 pipeline(s). |
|
/azp run CI-SqlClient |
|
Azure Pipelines failed to run 1 pipeline(s). |
|
/azp run CI-SqlClient |
|
Azure Pipelines successfully started running 1 pipeline(s). |
5519b0e to
f99fbcd
Compare
|
/azp run CI-SqlClient |
|
Azure Pipelines successfully started running 1 pipeline(s). |
benrr101
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This all looks pretty decent to me, especially if it unblocks fork builds.
Only thing I'm not sure about - this removes tests for macos against azure sql?
@David-Engel thoughts on adding back a mac-azure run only for non-forked builds? You mentioned above that we can remove some network permissions. Is that still a benefit given the forked build fix included here. |
@mdaigle The original reason to eliminate macOS+Azure was to get rid of usage of the AAD SP Secret (the "eliminate secrets" compliance task). We can't do AD Managed Identity from the Azure-hosted mac pools, so we don't have a password-less auth option for mac. Moving Mac to test against localhost honestly may get us more code coverage than testing Mac against Azure SQL DB. There are a lot of tests that are skipped against Azure SQL. If we want to do Mac + Azure in the future (honestly not a very high priority, in my mind since Linux + Azure is so close to Mac + Azure), we may be able to leverage a new Mac hosting service in MS that we are looking at for ODBC, which might eventually support AAD Managed Identity. |
Co-authored-by: samsharma2700 <[email protected]>
This PR switches macOS jobs to install Docker and a local SQL Server container instance instead of connecting to an Azure SQL DB instance for testing. This will allow us to get rid of the network permissions required for the mac agents to access Azure SQL DB and we can also get rid of the AADServicePrincipal connection info.
The ConfigurableIpPreferenceTest had to be adjusted to not run on macOS when targeting localhost as I couldn't get IPv6 working. It appears IPv6 in Docker is only supported on Linux:
https://docs.docker.com/engine/daemon/ipv6/
It might be coming soon for macOS, though: docker/for-mac#1432
Additions: (these should make #3094 obsolete)
Update: This also fixes CI for PRs from forks.
PRs from forks won't have access to any secrets (tightened security policy) so they won't be able to run the AE enclave jobs and a few tests that exercised AAD Service Principal Secret methods. Any PRs that break those from forks may only be caught by the nightly scheduled CI runs against main.
You can see fewer jobs ran in this screenshot for this PR compared to #3108:

Code coverage difference shows 66% from this fork PR and 72% from #3108.