-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: Merge branch 'release/4.13.0'
- Loading branch information
Showing
215 changed files
with
6,216 additions
and
4,261 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,139 @@ | ||
--- | ||
name: RHEL | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
toolchain: | ||
required: true | ||
type: string | ||
commands: | ||
required: true | ||
type: string | ||
archive-name: | ||
required: true | ||
type: string | ||
artifacts: | ||
required: true | ||
type: string | ||
|
||
env: | ||
OPENSSL_DIR: /usr/local/openssl | ||
|
||
jobs: | ||
rhel9-tests: | ||
services: | ||
# Label used to access the service container | ||
postgres: | ||
# Docker Hub image | ||
image: postgres | ||
# Provide the password for postgres | ||
env: | ||
POSTGRES_USER: kms | ||
PGUSER: kms | ||
POSTGRES_PASSWORD: kms | ||
POSTGRES_DB: kms | ||
# Set health checks to wait until postgres has started | ||
options: >- | ||
--health-cmd pg_isready | ||
--health-interval 10s | ||
--health-timeout 5s | ||
--health-retries 5 | ||
mariadb: | ||
image: mariadb | ||
env: | ||
MYSQL_DATABASE: kms | ||
MYSQL_ROOT_PASSWORD: kms | ||
|
||
redis: | ||
image: redis | ||
options: >- | ||
--health-cmd "redis-cli ping" | ||
--health-interval 10s | ||
--health-timeout 5s | ||
--health-retries 5 | ||
ports: | ||
- 6379:6379 | ||
|
||
runs-on: ubuntu-22.04 | ||
name: ${{ inputs.archive-name }} | ||
container: | ||
image: alvistack/rhel-9 | ||
|
||
steps: | ||
- name: Display cpuinfo | ||
run: cat /proc/cpuinfo | ||
|
||
- uses: actions/checkout@v3 | ||
|
||
- name: RHEL 9 prerequisites | ||
run: | | ||
set -x | ||
# Disable subscription manager | ||
sed -i "s/enabled=1/enabled=0/g" /etc/yum/pluginconf.d/subscription-manager.conf | ||
rm -rfv /var/cache/yum/* | ||
yum clean all | ||
yum -y install curl wget | ||
yum -y install perl-IPC-Cmd perl-Digest-SHA1 perl-CPAN perl-devel | ||
- uses: dtolnay/rust-toolchain@master | ||
with: | ||
toolchain: ${{ inputs.toolchain }} | ||
components: rustfmt, clippy | ||
|
||
- name: Local OpenSSL FIPS Install | ||
run: | | ||
bash ./scripts/local_ossl_instl.sh ${{ env.OPENSSL_DIR }} | ||
- name: Pre-cleanup | ||
run: | | ||
set -x | ||
rm -rf /tmp/sqlite-data /tmp/tmp.json | ||
- name: Build and tests | ||
run: | | ||
set -x | ||
${{ inputs.commands }} | ||
env: | ||
OPENSSL_DIR: ${{ env.OPENSSL_DIR }} | ||
RUST_LOG: cosmian_kms_server=trace | ||
|
||
POSTGRES_USER: kms | ||
PGUSER: kms | ||
POSTGRES_PASSWORD: kms | ||
POSTGRES_DB: kms | ||
KMS_POSTGRES_URL: postgres://kms:kms@postgres/kms | ||
|
||
MYSQL_DATABASE: kms | ||
MYSQL_ROOT_PASSWORD: kms | ||
KMS_MYSQL_URL: mysql://root:kms@mariadb/kms | ||
|
||
KMS_ENCLAVE_DIR_PATH: data/public | ||
KMS_SQLITE_PATH: data/shared | ||
KMS_CERTBOT_SSL_PATH: data/private | ||
|
||
REDIS_HOST: redis | ||
|
||
# Google variables | ||
TEST_GOOGLE_OAUTH_CLIENT_ID: ${{ secrets.TEST_GOOGLE_OAUTH_CLIENT_ID }} | ||
TEST_GOOGLE_OAUTH_CLIENT_SECRET: ${{ secrets.TEST_GOOGLE_OAUTH_CLIENT_SECRET }} | ||
TEST_GOOGLE_OAUTH_REFRESH_TOKEN: ${{ secrets.TEST_GOOGLE_OAUTH_REFRESH_TOKEN }} | ||
|
||
# Speeds up Ristretto 25519 multiplication x 2 | ||
RUSTFLAGS: --cfg curve25519_dalek_backend="simd" -C target-cpu=native | ||
|
||
- name: Remove large files before saving cache | ||
run: | | ||
find target/ -type f -size +40M -delete | ||
- name: Upload KMS for RHEL 9 | ||
if: inputs.artifacts != '' | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: ${{ inputs.archive-name }} | ||
path: ${{ inputs.artifacts }} | ||
retention-days: 1 | ||
if-no-files-found: error |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.