diff --git a/ci/pipelines/default-pipeline.yml b/ci/pipelines/default-pipeline.yml index b6dc685fc9..b88bcd414e 100644 --- a/ci/pipelines/default-pipeline.yml +++ b/ci/pipelines/default-pipeline.yml @@ -604,7 +604,7 @@ notify:dogfood-app: stage: notify when: on_success script: - - export GITHUB_TOKEN=$(dd-octo-sts token --scope DataDog/datadog-android --policy all.gitlab.pr) + - export GITHUB_TOKEN=$(dd-octo-sts token --scope ddoghq/datadog-android --policy all.gitlab.pr) - pip3 install GitPython requests - python3 ./ci/scripts/dogfood.py -v $CI_COMMIT_TAG -t app diff --git a/ci/scripts/dogfood.py b/ci/scripts/dogfood.py index 0238f41ca6..66a1bb87d3 100755 --- a/ci/scripts/dogfood.py +++ b/ci/scripts/dogfood.py @@ -22,9 +22,9 @@ TARGET_GRADLE_PLUGIN = "gradle-plugin" REPOSITORIES = { - TARGET_APP: "datadog-android", - TARGET_DEMO: "shopist-android", - TARGET_GRADLE_PLUGIN: "dd-sdk-android-gradle-plugin", + TARGET_APP: "ddoghq/datadog-android", + TARGET_DEMO: "DataDog/shopist-android", + TARGET_GRADLE_PLUGIN: "DataDog/dd-sdk-android-gradle-plugin", # Flutter is not needed because it pulls updates instead of being pushed them with the dogfood script. } @@ -67,7 +67,7 @@ def github_create_pr(repository: str, branch_name: str, base_name: str, version: '"title": "Update Datadog SDK to version ' + version + '", ' \ '"base":"' + base_name + '", "head":"' + branch_name + '"}' - url = "https://api.github.com/repos/DataDog/" + repository + "/pulls" + url = "https://api.github.com/repos/" + repository + "/pulls" response = requests.post(url=url, headers=headers, data=data) if response.status_code == 201: print("Pull Request created successfully") @@ -100,7 +100,7 @@ def generate_target_code(target: str, temp_dir_path: str, version: str): def git_clone_repository(repo_name: str, gh_token: str, temp_dir_path: str) -> Tuple[Repo, str]: print("Cloning repository " + repo_name) - url = "https://x-access-token:" + gh_token + "@github.com/DataDog/" + repo_name + url = "https://x-access-token:" + gh_token + "@github.com/" + repo_name repo = Repo.clone_from(url, temp_dir_path) base_name = repo.active_branch.name return repo, base_name @@ -112,7 +112,7 @@ def git_push_changes(repo: Repo, version: str, repo_name: str, branch_name: str, repo.index.commit("Update Datadog SDK to " + version) print("Pushing branch with commit-headless (signed)") - target = "DataDog/" + repo_name + target = repo_name head_sha = repo.head.commit.hexsha result = subprocess.run( [