2017-10-17 126 views
1

是否可以創建一個Windows用戶登錄名,作爲基於Linux的Docker鏡像在Windows PC(無Active Directory)上運行的MSSQL?在MSSQL(linux docker)上爲本地Windows用戶創建登錄

CREATE LOGIN [PC-NAME\LocalUser] FROM WINDOWS 

如果是,Docker鏡像需要哪種配置才能做到這一點?目前,我得到了以下錯誤:

Windows NT user or group 'PC-NAME\LocalUser' not found. Check the name again. 
+0

退房這篇文章中,大多數人使用sqlauth與泊塢窗:HTTPS://blogs.msdn.microsoft.com/containerstuff/2017/01/30/create-a-container-with-active-directory-support/ – TheGameiswar

+0

使用sql用戶的登錄按預期工作。我們有很多單元測試用於執行測試的本地用戶(構建代理)登錄。一個選項是編輯所有測試以使用特定的sql用戶。 socond選項是我的問題的答案:)(如果可能的話) – WebDucer

回答

1

MS Docs: Configure SQL Server 2017 container images on Docker

Eugene_Resnick Aug 18, 2017 Anyway to connect to the DB without using SA? Either a local account on the Windows host or through a gMSA on the host containers domain? LuisBosquez Aug 23, 2017

@Eugene_Resnick Integrated Authentication is still not supported on SQL Server on Linux. You can create a new login and connect to it like a regular installation of SQL Server. In fact, we recommend at least changing the SA password after it was first provisioned.

+0

謝謝。所以我們將編輯我們的單元測試,以便能夠使用docker鏡像作爲測試數據庫實例。 – WebDucer