代码拉取完成,页面将自动刷新
同步操作将从 随遇而安/esp32-web-camera 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
stages:
- build
- deploy
variables:
# System environment
# Common parameters for the 'make' during CI tests
MAKEFLAGS: "-j5 --no-keep-going"
# GitLab-CI environment
# more attempts for more robust
GET_SOURCES_ATTEMPTS: "10"
ARTIFACT_DOWNLOAD_ATTEMPTS: "10"
# We use get_sources.sh script to fetch the submodules and/or re-fetch the repo
# if it was corrupted (if submodule update fails this can happen)
GIT_STRATEGY: clone
GIT_SUBMODULE_STRATEGY: none
IDF_PATH: "$CI_PROJECT_DIR/esp-idf"
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
# replace submodule esp-idf to internal repository to speedup cloning
- sed -i "s%https://github.com/espressif/esp-idf%${GITLAB_SSH_SERVER}/idf/esp-idf.git%" .gitmodules
- sed -i "s%https://github.com/espressif/esp-face%${GITLAB_SSH_SERVER}/face-recognition-framework/esp-face.git%" .gitmodules
- git submodule update --init
# (the same regular expressions are used to set these are used in 'only:' sections below
- source esp-idf/tools/ci/configure_ci_environment.sh
# fetch the submodules (& if necessary re-fetch repo) from gitlab
- time git submodule update --init --recursive
- ./esp-idf/install.sh
- . ./esp-idf/export.sh
.add_gitlab_key_before:
before_script: &add_gitlab_key_before
- echo "Not fetching submodules"
- source ${IDF_PATH}/tools/ci/configure_ci_environment.sh
# add gitlab ssh key
- mkdir -p ~/.ssh
- chmod 700 ~/.ssh
- echo -n $AUTO_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
.build_template: &build_template
stage: build
image: $CI_DOCKER_REGISTRY/esp32-ci-env$BOT_DOCKER_IMAGE_TAG
tags:
- build
variables:
BATCH_BUILD: "1"
V: "0"
.build_examples_make_template: &build_examples_make_template
<<: *build_template
retry: 1
artifacts:
when: always
paths:
- build_examples_make/*/*/build/*.bin
- build_examples_make/*/*/build/*.elf
- build_examples_make/*/*/build/*.map
- build_examples_make/*/*/build/bootloader/*.bin
- ${LOG_PATH}
- ${IDF_PATH}/tools/ci
expire_in: 1 week
variables:
LOG_PATH: "$CI_PROJECT_DIR/log_examples_make"
script:
# it's not possible to build 100% out-of-tree and have the "artifacts"
# mechanism work, but this is the next best thing
- rm -rf build_examples_make
- mkdir build_examples_make
- cd build_examples_make
- mkdir -p ${LOG_PATH}
- ${CI_PROJECT_DIR}/tools/ci/build_examples.sh
.build_examples_cmake_template: &build_examples_cmake_template
<<: *build_template
retry: 1
artifacts:
when: always
paths:
- build_examples_cmake/*/*/build/*.bin
- build_examples_cmake/*/*/build/*.elf
- build_examples_cmake/*/*/build/*.map
- build_examples_cmake/*/*/*/build/flasher_args.json
- build_examples_cmake/*/*/build/bootloader/*.bin
- build_examples_cmake/*/*/build/partition_table/*.bin
- ${LOG_PATH}
- ${IDF_PATH}/tools/ci
expire_in: 1 week
variables:
LOG_PATH: "$CI_PROJECT_DIR/log_examples_cmake"
script:
# it's not possible to build 100% out-of-tree and have the "artifacts"
# mechanism work, but this is the next best thing
- rm -rf build_examples_cmake
- mkdir build_examples_cmake
- cd build_examples_cmake
- mkdir -p ${LOG_PATH}
- ${CI_PROJECT_DIR}/tools/ci/build_examples_cmake.sh
build_examples_make_00:
<<: *build_examples_make_template
build_examples_make_01:
<<: *build_examples_make_template
build_examples_cmake_00:
<<: *build_examples_cmake_template
build_examples_cmake_01:
<<: *build_examples_cmake_template
push_to_github:
stage: deploy
image: $CI_DOCKER_REGISTRY/esp32-ci-env$BOT_DOCKER_IMAGE_TAG
tags:
- deploy
only:
- master
- /^release\/v/
when: on_success
dependencies:
- build_examples_make_00
- build_examples_make_01
- build_examples_cmake_00
- build_examples_cmake_01
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-who.git
- ${IDF_PATH}/tools/ci/push_to_github.sh
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。