Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move from CircleCI to GitHub Actions #1849

Merged
merged 9 commits into from
Jul 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
308 changes: 0 additions & 308 deletions .circleci/config.yml

This file was deleted.

87 changes: 87 additions & 0 deletions .github/workflows/commit-to-main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
name: Trigger basic downstream CI

permissions:
contents: read

on:
push:
branches: [ "main" ]

jobs:
trigger-downstream-ci:
strategy:
fail-fast: false
runs-on: ubuntu-latest
steps:
# TODO: missing projects?
- name: Trigger OQS-OpenSSL CI
run: |
curl --silent \
--write-out "\n%{response_code}\n" \
--user ${BUILD_TRIGGER_TOKEN}: \
--request POST \
--header "Content-Type: application/json" \
--data '{ "branch": "OQS-OpenSSL_1_1_1-stable", "parameters": { "run_downstream_tests": true } }' \
Copy link
Member

Choose a reason for hiding this comment

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

Doesn't look necessary to keep this one

Copy link
Member Author

Choose a reason for hiding this comment

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

Same comment as below re liboqs-rust applies here.

https://circleci.com/api/v2/project/gh/open-quantum-safe/openssl/pipeline | tee curl_out \
&& grep -q "201" curl_out
- name: Trigger OQS-BoringSSL CI
run: |
curl --silent \
--write-out "\n%{response_code}\n" \
--user ${BUILD_TRIGGER_TOKEN}: \
--request POST \
--header "Content-Type: application/json" \
--data '{ "branch": "master", "parameters": { "run_downstream_tests": true } }' \
https://circleci.com/api/v2/project/gh/open-quantum-safe/boringssl/pipeline | tee curl_out \
&& grep -q "201" curl_out
- name: Trigger OQS-OpenSSH CI
run: |
curl --silent \
--write-out "\n%{response_code}\n" \
--user ${BUILD_TRIGGER_TOKEN}: \
--request POST \
--header "Content-Type: application/json" \
--data '{ "branch": "OQS-v8", "parameters": { "run_downstream_tests": true } }' \
Copy link
Member

Choose a reason for hiding this comment

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

When to add/change this to v9?

Copy link
Member

Choose a reason for hiding this comment

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

The v9 branch doesn't yet work; the current PR from @geedo0 gets the basic test suite running but still doesn't have full PQ or hybrid support. I think we can merge this PR with v8, and then when v9 is ready, we can come back and update the liboqs CI.

https://circleci.com/api/v2/project/gh/open-quantum-safe/openssh/pipeline | tee curl_out \
&& grep -q "201" curl_out
- name: Trigger oqs-provider CI
run: |
curl --silent \
--write-out "\n%{response_code}\n" \
--user ${BUILD_TRIGGER_TOKEN}: \
--request POST \
--header "Content-Type: application/json" \
--data '{ "branch": "main" }' \
https://circleci.com/api/v2/project/gh/open-quantum-safe/oqs-provider/pipeline | tee curl_out \
&& grep -q "201" curl_out
- name: Trigger liboqs-dotnet CI
run: |
curl --silent \
--write-out "\n%{response_code}\n" \
--user ${BUILD_TRIGGER_TOKEN}: \
--request POST \
--header "Content-Type: application/json" \
--data '{ "branch": "master" }' \
https://circleci.com/api/v2/project/gh/open-quantum-safe/liboqs-dotnet/pipeline | tee curl_out \
&& grep -q "201" curl_out
- name: Trigger liboqs-java CI
run: |
curl --silent \
--write-out "\n%{response_code}\n" \
--user ${BUILD_TRIGGER_TOKEN}: \
--request POST \
--header "Content-Type: application/json" \
--data '{ "branch": "master" }' \
https://circleci.com/api/v2/project/gh/open-quantum-safe/liboqs-java/pipeline | tee curl_out \
Copy link
Member

Choose a reason for hiding this comment

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

Doesn't look as necessary as triggering liboqs-rust, does it?

Copy link
Member Author

Choose a reason for hiding this comment

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

Or liboqs-go... My intent with this PR was just to duplicate existing CCI functionality as closely as possible to make sure it worked on GH and make any improvements in a follow-up PR. But I could do both in one shot, if that would be preferable from a review standpoint.

Copy link
Member Author

Choose a reason for hiding this comment

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

@baentsch I'll interpret the thumbs-up as an endorsement of a follow-up PR to address #1783 and merge this as is.

&& grep -q "201" curl_out
- name: Trigger liboqs-python CI
run: |
curl --silent \
--write-out "\n%{response_code}\n" \
--request POST \
--header "Accept: application/vnd.github+json" \
--header "Authorization: Bearer $OQSBOT_GITHUB_ACTIONS" \
--header "X-GitHub-Api-Version: 2022-11-28" \
--data '{"event_type":"liboqs-upstream-trigger"}' \
https://api.github.com/repos/open-quantum-safe/liboqs-python/dispatches | tee curl_out \
&& grep -q "204" curl_out
Loading
Loading