代码拉取完成,页面将自动刷新
同步操作将从 乐鑫开源/esp-skainet 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
stages:
- build
- target_test
- deploy
variables:
SKAINET_PATH: "$CI_PROJECT_DIR"
BATCH_BUILD: "1"
V: "0"
IDF_CI_BUILD: "1"
DOCKER_TARGET_TEST_v5_0_ENV_IMAGE: "$CI_DOCKER_REGISTRY/target-test-env-v5.0:3"
before_script:
# add gitlab ssh key
- mkdir -p ~/.ssh
- chmod 700 ~/.ssh
- echo -n $GITLAB_KEY > ~/.ssh/id_rsa_base64
- base64 --decode --ignore-garbage ~/.ssh/id_rsa_base64 > ~/.ssh/id_rsa
- chmod 600 ~/.ssh/id_rsa
- echo -e "Host gitlab.espressif.cn\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
- git --version
- git submodule update --init --recursive --force
- pip install idf_build_apps
- pip install -r tools/ci/requirements.txt
.build_all_examples_script: &build_all_examples_script
- python -m idf_build_apps build -p $EXAMPLES_PATH --recursive --manifest-file $EXAMPLES_PATH/$MANIFEST_FILE -t all
.build_test_script: &build_test_script
- python ./tools/ci/build_apps.py $EXAMPLES_PATH -t all
.build_examples_template:
stage: build
tags:
- build
variables:
EXAMPLES_PATH: "examples"
MANIFEST_FILE: ".build-test-rules.yml"
script:
- *build_all_examples_script
.build_test_template:
stage: build
tags:
- build
artifacts:
when: always
paths:
- "**/build*/size.json"
- "**/build*/build_log.txt"
- "**/build*/*.bin"
# upload to s3 server to save the artifacts size
- "**/build*/*.map"
- "**/build*/*.elf"
- "**/build*/flasher_args.json"
- "**/build*/flash_project_args"
- "**/build*/config/sdkconfig.json"
- "**/build*/bootloader/*.bin"
- "**/build*/bootloader/*.elf"
- "**/build*/partition_table/*.bin"
- "**/build*/srmodels/*.bin"
- size_info.txt
expire_in: 1 week
variables:
EXAMPLES_PATH: "test"
script:
- *build_test_script
.test_template: &test_template
image: DOCKER_TARGET_TEST_v5_0_ENV_IMAGE
stage: target_test
timeout: 10 hour
variables:
GIT_DEPTH: 1
SUBMODULES_TO_FETCH: "none"
cache:
# Usually do not need submodule-cache in target_test
- key: pip-cache
paths:
- .cache/pip
policy: pull
.pytest_template:
<<: *test_template
artifacts:
when: always
paths:
- XUNIT_RESULT.xml
- pytest_log/
reports:
junit: XUNIT_RESULT.xml
expire_in: 4 days
variables:
TEST_TARGET: 'esp32s3'
TEST_FOLDER: './test'
TEST_ENV: 'korvo-2'
script:
- pytest ${TEST_FOLDER} --target ${TEST_TARGET} --env ${TEST_ENV} --config ${MODEL} --noise ${NOISE} --snr ${SNR} --junitxml=XUNIT_RESULT.xml
.if-protected: &if-protected
if: '($CI_COMMIT_REF_NAME == "master" || $CI_COMMIT_BRANCH =~ /^release\/v/ || $CI_COMMIT_TAG =~ /^v\d+\.\d+(\.\d+)?($|-)/)'
.if-wakenet_test: &if-wakenet_test
if: '($CI_COMMIT_BRANCH =~ /^test\/wn/)'
.patterns-test_wakenet: &patterns-test_wakenet
- "components/esp-sr/lib/**/*"
- "components/esp-sr/include/**/*"
- "components/esp-sr/src/**/*"
- "components/esp-sr/model/wakenet_model/**/*"
- "test/wakenet/**/*"
build_idf_v4.4:
extends: .build_examples_template
image: espressif/idf:release-v4.4
build_idf_v5.0:
extends: .build_examples_template
image: espressif/idf:release-v5.0
# Rules to trigger wakenet test
.rules:test:test_wakenet:
rules:
- <<: *if-protected
changes: *patterns-test_wakenet
- <<: *if-wakenet_test
build_wakenet_test:
extends:
- .build_test_template
- .rules:test:test_wakenet
image: espressif/idf:release-v5.0
variables:
EXAMPLES_PATH: "test/wakenet"
test_wakenet:
extends:
- .pytest_template
- .rules:test:test_wakenet
needs:
- job: "build_wakenet_test"
artifacts: true
optional: true
tags:
- 'korvo-2'
image: $DOCKER_TARGET_TEST_v5_0_ENV_IMAGE
variables:
TEST_TARGET: 'esp32s3'
TEST_FOLDER: './test/wakenet'
TEST_ENV: 'korvo-2'
IDF_VERSION: "5.0"
parallel:
matrix:
- MODEL: ["hilexin", "hiesp"]
NOISE: ["pink", "pub"]
SNR: ["0", "5"]
.patterns-test_multinet6: &patterns-test_multinet6
- "components/esp-sr/lib/**/*"
- "components/esp-sr/include/**/*"
- "components/esp-sr/src/**/*"
- "components/esp-sr/model/multinet_model/mn6*/*"
- "test/multinet/main/*"
- "test/multinet/pytest_multinet6.py"
- "test/multinet/*mn6*"
.if-multinet_test6: &if-multinet_test6
if: '($CI_COMMIT_BRANCH =~ /^test\/mn6/)'
# Rules to trigger multinet test
.rules:test:test_multinet6:
rules:
- <<: *if-protected
changes: *patterns-test_multinet6
- <<: *if-multinet_test6
build_multinet_test:
extends:
- .build_test_template
- .rules:test:test_multinet6
image: espressif/idf:release-v5.0
variables:
EXAMPLES_PATH: "test/multinet"
test_multinet6:
extends:
- .pytest_template
- .rules:test:test_multinet6
needs:
- job: "build_multinet_test"
artifacts: true
optional: true
tags:
- 'korvo-2'
image: $DOCKER_TARGET_TEST_v5_0_ENV_IMAGE
variables:
TEST_TARGET: 'esp32s3'
TEST_FOLDER: './test/multinet/pytest_multinet6.py'
TEST_ENV: 'korvo-2'
IDF_VERSION: "5.0"
parallel:
matrix:
- MODEL: ["hiesp_mn6_en", "hilexin_mn6_cn", "hilexin_mn6_cn_ac"]
NOISE: ["pink", "pub", "none"]
SNR: ["5", "10"]
push_to_github:
stage: deploy
image: $CI_DOCKER_REGISTRY/esp-env-v4.4:1
tags:
- deploy
when: on_success
only:
- master
- /^release\/v/
variables:
GIT_STRATEGY: clone
before_script:
- echo "skip default before_script"
script:
- mkdir -p ~/.ssh
- chmod 700 ~/.ssh
- echo -n $GH_PUSH_KEY > ~/.ssh/id_rsa_base64
- base64 --decode --ignore-garbage ~/.ssh/id_rsa_base64 > ~/.ssh/id_rsa
- chmod 600 ~/.ssh/id_rsa
- echo -e "Host github.com\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
- git remote remove github &>/dev/null || true
- git remote add github git@github.com:espressif/esp-skainet.git
- ${SKAINET_PATH}/tools/ci/push_to_github.sh
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。