Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
17 commits
Select commit Hold shift + click to select a range
0dc76a9
feat: use http agent that respects environment proxy settings when st…
NlightNFotis Dec 4, 2024
8f2cb3a
build: add undici to node_modules folder - CI fails without it
NlightNFotis Dec 4, 2024
78be2f1
ci: add configuration tto run proxy with zstd package to test streami…
NlightNFotis Dec 3, 2024
9c48c8b
ci: add capability to handle container initialisation steps to sync.py
NlightNFotis Dec 5, 2024
b4bc093
ci: remove patch file and cleanup justfile
NlightNFotis Dec 5, 2024
b706e37
chore: add changelog entry
NlightNFotis Dec 5, 2024
182c5e7
chore: reword description in CHANGELOG.md
NlightNFotis Dec 6, 2024
a89fbc8
docs: add readme for justfile/pr-checks update
NlightNFotis Dec 9, 2024
c901aee
ci: remove dns for container running proxy steps (experimental)
NlightNFotis Dec 9, 2024
3951a82
Merge branch 'main' into NlightNFotis/detect_use_proxy_when_streaming
NlightNFotis Dec 9, 2024
51e71f8
docs: add documentation for the reason why we need to have a setup st…
NlightNFotis Dec 9, 2024
4c20d4f
feat: cleanup destination directory if we fail during streaming of th…
NlightNFotis Dec 9, 2024
c6454d5
Merge branch 'main' into NlightNFotis/detect_use_proxy_when_streaming
henrymercer Dec 10, 2024
9323695
Update PR checks readme instructions
aeisenberg Dec 9, 2024
88bcf64
feat: change wording of error reporting when a failure occurs during …
NlightNFotis Dec 11, 2024
9e8cd42
fix: move changelog entry to appropriate place
NlightNFotis Dec 11, 2024
1e5b591
Merge branch 'main' into NlightNFotis/detect_use_proxy_when_streaming
NlightNFotis Dec 11, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
ci: add configuration tto run proxy with zstd package to test streami…
…ng with proxy
  • Loading branch information
NlightNFotis committed Dec 4, 2024
commit 78be2f13336dc457973edb5e350e589e622028dc
27 changes: 23 additions & 4 deletions .github/workflows/__test-proxy.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pr-checks/checks/test-proxy.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: "Proxy test"
description: "Tests using a proxy specified by the https_proxy environment variable"
versions: ["linked"]
versions: ["linked", "nightly-latest"]

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test was passing before when we were streaming zstd bundles with a CodeQL Action version that wasn't respecting proxy settings, presumably because the CodeQL Action could still access the bundle without the proxy.

Can we update the test to ensure that we're downloading the bundle via the proxy?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the latest test added as part of this PR, I'm fairly confident we're downloading the bundle through the proxy.

The reason it worked before is that it didn't test the streaming of the bundle, because when linked is passed as the version, the prepare-step action was choosing the .tar.gz bundle by default - as example the latest run from a PR merged recently.

I am not sure though how it makes that selection between the .tar.gz and the .tar.zst one, because in this PR, the same job downloaded the .tar.zst one. But previously, we didn't go through this code because the same job was opting for the .tar.gz when downloading.

Will look more into that and report back any interesting findings.

operatingSystems: ["ubuntu"]
container:
image: ubuntu:22.04
Expand Down
7 changes: 7 additions & 0 deletions pr-checks/justfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Perform all necessary steps to update the PR checks
update-pr-checks:
Comment thread
NlightNFotis marked this conversation as resolved.
python3 -m venv env
env/bin/activate
pip3 install ruamel.yaml
python3 sync.py
git apply pr-checks.patch
18 changes: 18 additions & 0 deletions pr-checks/test-proxy.patch
Comment thread
NlightNFotis marked this conversation as resolved.
Outdated
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
diff --git a/.github/workflows/__test-proxy.yml b/.github/workflows/__test-proxy.yml
index b6831b7a0..3be758b02 100644
--- a/.github/workflows/__test-proxy.yml
+++ b/.github/workflows/__test-proxy.yml
@@ -45,6 +45,13 @@ jobs:
python-version: '3.11'
- name: Check out repository
uses: actions/checkout@v4
+ - name: Set up GitHub CLI
+ run: |
+ curl -fsSL https://cli.github.com/packages/githubcli-archive-keyring.gpg | sudo dd of=/usr/share/keyrings/githubcli-archive-keyring.gpg
+ sudo apt-key add /usr/share/keyrings/githubcli-archive-keyring.gpg
+ sudo apt-add-repository https://cli.github.com/packages
+ sudo apt-get update
+ sudo apt-get install gh
- name: Prepare test
id: prepare-test
uses: ./.github/actions/prepare-test