Skip to content

update_job_status() now has option to ignore runtime errors #51

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

Merged
merged 20 commits into from
Jul 23, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
Prev Previous commit
Next Next commit
Added script to add qiita root-ca to environment.
Added script to add the root-ca used to sign Qiita's server.crt to
qiita_client's environment. The functionality in this small script may
be more useful if it becomes part of qiita_client itself.
  • Loading branch information
charles-cowart committed Jul 17, 2024
commit 2a8138bd109a9b3f491b950a9803477e2d0c6bc4
9 changes: 7 additions & 2 deletions .github/workflows/qiita-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ on:
jobs:
# derived from https://github.com/actions/example-services/blob/master/.github/workflows/postgres-service.yml
main:
# 7/16/24: confirm current ubuntu-latest is still 22.04.
runs-on: ubuntu-latest

strategy:
Expand Down Expand Up @@ -84,7 +85,6 @@ jobs:

export QIITA_SERVER_CERT=`pwd`/qiita-dev/qiita_core/support_files/ci_server.crt
export QIITA_CONFIG_FP=`pwd`/qiita-dev/qiita_core/support_files/config_test_local.cfg
pip --quiet install -U pip

pip --quiet install https://github.com/qiita-spots/qtp-job-output-folder/archive/refs/heads/main.zip

Expand Down Expand Up @@ -136,9 +136,14 @@ jobs:
run: |
conda activate qiita_client
export QIITA_SERVER_CERT=`pwd`/qiita-dev/qiita_core/support_files/ci_server.crt
export QIITA_ROOT_CA=`pwd`/qiita-dev/qiita_core/support_files/ci_rootca.crt
export QIITA_CONFIG_FP=`pwd`/qiita-dev/qiita_core/support_files/config_test_local.cfg
export QP_KLP_CONFIG_FP=`pwd`/configuration.json
export PYTHONWARNINGS="ignore:Certificate for localhost has no \`subjectAltName\`"

# before starting nosetests, add the root ca used to sign qiita's ci_server.crt file
# to the environment's certifi store. This will prevent CERTIFICATE_VERIFY_FAILED
# errors.
python rootca_insert.py $QIITA_ROOT_CA
nosetests --with-doctest --with-coverage -v --cover-package=qiita_client
- uses: codecov/codecov-action@v3
with:
Expand Down
18 changes: 18 additions & 0 deletions rootca_insert.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
import certifi
from sys import argv


def main(ca_fp):
with open(ca_fp, 'rb') as f:
my_ca = f.read()

ca_file = certifi.where()

with open(ca_file, 'ab') as f:
f.write(my_ca)

print("%s updated" % ca_file)


if __name__ == '__main__':
main(argv[1])