我需要在構建結束時將構建工件上傳到 SharePoint。使用詹金斯管道。
我沒有找到任何插件來實作這一點。
我的 Jenkins 實體在 Linux 機器上運行。請提出實作這一目標的最佳方法
uj5u.com熱心網友回復:
為此,我正在為 Microsoft 365 使用 CLI(也適用于 linux)。看起來有點像這樣:
m365 login --authType password --userName user@contoso.com --password pass@word1
m365 spo file add --webUrl https://contoso.sharepoint.com/sites/project-x --folder 'Shared Documents' --path 'C:\MS365.jpg'
https://pnp.github.io/cli-microsoft365/cmd/login/
https://pnp.github.io/cli-microsoft365/cmd/spo/file/file-add/
您可能需要為您的 jenkins 添加特殊帳戶到您的共享點,或添加應用程式密碼才能從守護行程上傳檔案(如果您的共享點需要 MFA 身份驗證)
轉載請註明出處,本文鏈接:https://www.uj5u.com/ruanti/511670.html
標籤:詹金斯共享点詹金斯管道
上一篇:如何使用boto3上傳s3
