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

Add CI_CERT_KEY_VERSION environment variable #3640

Merged
merged 3 commits into from
Apr 27, 2022

Conversation

arcusfelis
Copy link
Contributor

This PR addresses "There is no easy way to reset cache without making new changes into the code. And sometimes cache breaks, because a committer did something wrong".

Proposed changes include:

  • Use CI_CERT_KEY_VERSION env variable to change the key externally.
  • Avoid caching invalid certificate data. It should make fixing bugs with certificates a bit easier.

@codecov
Copy link

codecov bot commented Apr 27, 2022

Codecov Report

Merging #3640 (7417601) into master (0d956f2) will increase coverage by 0.00%.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master    #3640   +/-   ##
=======================================
  Coverage   81.01%   81.02%           
=======================================
  Files         428      428           
  Lines       31942    31942           
=======================================
+ Hits        25879    25882    +3     
+ Misses       6063     6060    -3     
Impacted Files Coverage Δ
src/logger/mongoose_log_filter.erl 78.08% <0.00%> (-1.37%) ⬇️
src/rdbms/mongoose_rdbms.erl 63.63% <0.00%> (-0.73%) ⬇️
src/pubsub/mod_pubsub.erl 72.94% <0.00%> (+0.06%) ⬆️
src/ejabberd_c2s.erl 88.72% <0.00%> (+0.07%) ⬆️
src/mod_muc_room.erl 76.87% <0.00%> (+0.17%) ⬆️
src/mam/mod_mam_muc_rdbms_arch_async.erl 85.71% <0.00%> (+2.85%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0d956f2...7417601. Read the comment docs.

@mongoose-im
Copy link
Collaborator

mongoose-im commented Apr 27, 2022

small_tests_24 / small_tests / 2ba29d7
Reports root / small


small_tests_23 / small_tests / 2ba29d7
Reports root / small


dynamic_domains_pgsql_mnesia_23 / pgsql_mnesia / 2ba29d7
Reports root/ big
OK: 2860 / Failed: 0 / User-skipped: 133 / Auto-skipped: 0


dynamic_domains_mysql_redis_24 / mysql_redis / 2ba29d7
Reports root/ big
OK: 2843 / Failed: 0 / User-skipped: 150 / Auto-skipped: 0


dynamic_domains_mssql_mnesia_24 / odbc_mssql_mnesia / 2ba29d7
Reports root/ big
OK: 2860 / Failed: 0 / User-skipped: 133 / Auto-skipped: 0


ldap_mnesia_23 / ldap_mnesia / 2ba29d7
Reports root/ big
OK: 1524 / Failed: 1 / User-skipped: 401 / Auto-skipped: 0

pubsub_SUITE:dag+basic:create_delete_node_test
{error,{{badmatch,false},
    [{pubsub_tools,check_response,2,
             [{file,"/home/circleci/project/big_tests/tests/pubsub_tools.erl"},
            {line,491}]},
     {pubsub_tools,receive_response,3,
             [{file,"/home/circleci/project/big_tests/tests/pubsub_tools.erl"},
            {line,481}]},
     {pubsub_tools,receive_and_check_response,4,
             [{file,"/home/circleci/project/big_tests/tests/pubsub_tools.erl"},
            {line,471}]},
     {escalus_story,story,4,
            [{file,"/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_story.erl"},
             {line,72}]},
     {test_server,ts_tc,3,[{file,"test_server.erl"},{line,1754}]},
     {test_server,run_test_case_eval1,6,
            [{file,"test_server.erl"},{line,1263}]},
     {test_server,run_test_case_eval,9,
            [{file,"test_server.erl"},{line,1195}]}]}}

Report log


ldap_mnesia_24 / ldap_mnesia / 2ba29d7
Reports root/ big
OK: 1506 / Failed: 0 / User-skipped: 401 / Auto-skipped: 0


internal_mnesia_24 / internal_mnesia / 2ba29d7
Reports root/ big
OK: 1547 / Failed: 0 / User-skipped: 360 / Auto-skipped: 0


pgsql_mnesia_23 / pgsql_mnesia / 2ba29d7
Reports root/ big
OK: 3234 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0


pgsql_mnesia_24 / pgsql_mnesia / 2ba29d7
Reports root/ big
OK: 3234 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0


elasticsearch_and_cassandra_24 / elasticsearch_and_cassandra_mnesia / 2ba29d7
Reports root/ big
OK: 1854 / Failed: 0 / User-skipped: 368 / Auto-skipped: 0


mysql_redis_24 / mysql_redis / 2ba29d7
Reports root/ big
OK: 3229 / Failed: 0 / User-skipped: 147 / Auto-skipped: 0


mssql_mnesia_24 / odbc_mssql_mnesia / 2ba29d7
Reports root/ big
OK: 3234 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0


riak_mnesia_24 / riak_mnesia / 2ba29d7
Reports root/ big
OK: 1697 / Failed: 0 / User-skipped: 367 / Auto-skipped: 0

Copy link
Collaborator

@NelsonVides NelsonVides left a comment

Choose a reason for hiding this comment

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

LGTM 👌🏽

Copy link
Member

@chrzaszcz chrzaszcz left a comment

Choose a reason for hiding this comment

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

Looks good, I have one comment

@@ -41,6 +41,9 @@ commands:
- run:
name: Print cert hashes for debugging
command: find tools/ssl -type f -exec md5sum {} \; | sort
- run:
name: Continue if certificate data is valid
Copy link
Member

Choose a reason for hiding this comment

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

The name is a bit misleading as we only check if it exists.

Suggested change
name: Continue if certificate data is valid
name: Continue if certificate exists

@arcusfelis arcusfelis force-pushed the mu-fix-cert-cache-from-ci-interface branch from 2ba29d7 to 7417601 Compare April 27, 2022 11:23
@mongoose-im
Copy link
Collaborator

mongoose-im commented Apr 27, 2022

small_tests_24 / small_tests / 7417601
Reports root / small


small_tests_23 / small_tests / 7417601
Reports root / small


dynamic_domains_pgsql_mnesia_23 / pgsql_mnesia / 7417601
Reports root/ big
OK: 2860 / Failed: 0 / User-skipped: 133 / Auto-skipped: 0


dynamic_domains_pgsql_mnesia_24 / pgsql_mnesia / 7417601
Reports root/ big
OK: 2860 / Failed: 0 / User-skipped: 133 / Auto-skipped: 0


dynamic_domains_mysql_redis_24 / mysql_redis / 7417601
Reports root/ big
OK: 2843 / Failed: 0 / User-skipped: 150 / Auto-skipped: 0


ldap_mnesia_23 / ldap_mnesia / 7417601
Reports root/ big
OK: 1506 / Failed: 0 / User-skipped: 401 / Auto-skipped: 0


dynamic_domains_mssql_mnesia_24 / odbc_mssql_mnesia / 7417601
Reports root/ big
OK: 2860 / Failed: 0 / User-skipped: 133 / Auto-skipped: 0


ldap_mnesia_24 / ldap_mnesia / 7417601
Reports root/ big
OK: 1506 / Failed: 0 / User-skipped: 401 / Auto-skipped: 0


internal_mnesia_24 / internal_mnesia / 7417601
Reports root/ big
OK: 1547 / Failed: 0 / User-skipped: 360 / Auto-skipped: 0


elasticsearch_and_cassandra_24 / elasticsearch_and_cassandra_mnesia / 7417601
Reports root/ big
OK: 1854 / Failed: 0 / User-skipped: 368 / Auto-skipped: 0


pgsql_mnesia_24 / pgsql_mnesia / 7417601
Reports root/ big
OK: 3234 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0


mysql_redis_24 / mysql_redis / 7417601
Reports root/ big
OK: 3229 / Failed: 0 / User-skipped: 147 / Auto-skipped: 0


pgsql_mnesia_23 / pgsql_mnesia / 7417601
Reports root/ big
OK: 3234 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0


mssql_mnesia_24 / odbc_mssql_mnesia / 7417601
Reports root/ big
OK: 3234 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0


riak_mnesia_24 / riak_mnesia / 7417601
Reports root/ big
OK: 1697 / Failed: 0 / User-skipped: 367 / Auto-skipped: 0

@NelsonVides NelsonVides merged commit d4cba78 into master Apr 27, 2022
@NelsonVides NelsonVides deleted the mu-fix-cert-cache-from-ci-interface branch April 27, 2022 12:02
@Premwoik Premwoik added this to the 5.1.0 milestone May 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants