This message was deleted.
# general
s
This message was deleted.
c
So, for now I've gone with getting a list with GetRepositories from Github, and I check if the repository already exist. If it exists, add Import option instead of creating it. If anyone has a better solution, please share. :)
k
Do you mean having different environments on the same repo? You can achieve that using Github Actions and different branches. Look at this https://www.pulumi.com/docs/guides/continuous-delivery/github-actions/
c
It's not what I mean. I'm using NewRepository from the pulumi-github SDK on a project with several stacks, when I run
pulumi up
on dev stack it get's created, then i do
pulumi up
on prod stack it will become a conflict because repo already exists.
b
You could move github repository resources into a separate pulumi project/stack like
Pulumi.github.yaml
and use stack reference to get the resource values you need.
👍 1