Comments (7)
I've found a solution that I don't like but it works.
In the pipelines editor on azure devops, go to variables section, and create a secret variable with a github access token in it. Then, refer to it in the git clone
command in the azure-pipelines.yml
file.
Resulting snippet from my yml file:
- script: |
cd some_dir
git clone https://x-access-token:$(astafan8-github-access-token)@github.com/ORG/OTHER_PRIVATE_REPO.git
cd OTHER_PRIVATE_REPO
git checkout v1
pip install -e .
displayName: 'Install OTHER_PRIVATE_REPO from tagged commit'
The x-access-token
part was found here.
from azure-pipelines-yaml.
Any progress on this front?
from azure-pipelines-yaml.
I'm having a similar issue but it results in a different message.
I'm having a pipeline for SOME_PRIVATE_REPO that uses code from OTHER_PRIVATE_REPO within the same organization ORG. Azure Pipelines is enabled and is aware of both repositories (in settings in github).
Here's a snippet of the azure-pipelines.yml
:
- script: |
cd some_dir
git clone https://github.com/ORG/OTHER_PRIVATE_REPO.git
cd OTHER_PRIVATE_REPO
git checkout v1
pip install -e .
displayName: 'Install OTHER_PRIVATE_REPO from tagged commit'
So, the job just hangs at the stage of Cloning into 'OTHER_PRIVATE_REPO'...
, and after some time gets automatically cancelled due to timeout.
I tried googling but couldn't find how to access other private github repo inside a pipeline for a private github repo. Does anybody know?
from azure-pipelines-yaml.
Having the exact same issue. I agree with @astafan8 - I don't like the solution with the secret and the access token. Ideally it should support multiple the build pipeline should support checkout tasks. I think it relates to this User Voice request
from azure-pipelines-yaml.
In order to consolidate to fewer feedback channels, we've moved suggestions and issue reporting to Developer Community. Sorry for any confusion resulting from this move.
from azure-pipelines-yaml.
Moved into Developer Community: https://developercommunity.visualstudio.com/content/problem/1007491/unable-to-clone-another-private-repo-from-the-same.html
Please use "Follow" button on the right to track it
from azure-pipelines-yaml.
@DominicCabral:
Please go to this link and answer Microsoft team: https://developercommunity.visualstudio.com/content/problem/1007491/unable-to-clone-another-private-repo-from-the-same.html
from azure-pipelines-yaml.
Related Issues (20)
- Devops for Micro Service HOT 1
- Yaml becomes invalid when specific `checkout:` syntax occurs more than once HOT 1
- How to use `Build.SourceVersionAuthor`? HOT 3
- by design there´s not available option in DeVops Service to create a new pipeline yaml for "existing" branch HOT 5
- deploy built artifacts in container uploads both checked out projects instead of right one HOT 2
- how to triger a build pipeline from powershell HOT 2
- Pipeline resource trigger documentation missing prerequisite HOT 1
- could find the branch error in azure yaml HOT 2
- python task ran successfull but pipeline is faiing with bash exit code 1 HOT 3
- Azure YAML Pipelines - Using template expression variables at non-global scope HOT 1
- Examples for resource pipeline and source inputs are not clear. HOT 9
- Hi Team While running my Azure pipeline.yaml I am getting following error: directive are not supported for the expression that are embedded within the string Directive are only supported when the entire value is an expression HOT 1
- This repo is missing important files
- It is possible to convert a json to variables/parameters YAML and iterate? HOT 3
- Support for conditions in templates? HOT 1
- Custom expression/function in Yaml HOT 1
- Azure DevOps YAML Template Powershell script file issue HOT 2
- Azure Pipelines Resource Trigger (branch filter) not working as expected. HOT 2
- GitHub Actions Build Error: Invalid App Path for Django-Celery-Beat Dockerfile HOT 3
- Error running pipeline after renaming default GitHub branch from 'master' to 'main' HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from azure-pipelines-yaml.