Merge branch 'feature/gitlab-ci' into 'master'

GitLab CI and sync with GitHub

This change adds GitLab CI support. Currently we pull latest version of esp-idf-template project from Github and try to compile it with esp-idf version in question.
Additional test steps will be added in the future.

This change also adds automatic push to GitHub for master branch only, if CI has passed.

To implement CI builds, I created a docker image, espressif/esp32-ci-env. I will make its Dockerfile available on Github as well.

See merge request !12
pull/2/merge
Ivan Grokhotkov 2016-08-23 11:22:15 +08:00
commit 5c452c033f
2 zmienionych plików z 38 dodań i 1 usunięć

37
.gitlab-ci.yml 100644
Wyświetl plik

@ -0,0 +1,37 @@
stages:
- build
# - test
- deploy
build_template_app:
stage: build
image: espressif/esp32-ci-env
variables:
SDK_PATH: "$CI_PROJECT_DIR"
IDF_PATH: "$CI_PROJECT_DIR"
GIT_STRATEGY: clone
script:
- git clone https://github.com/espressif/esp-idf-template.git
- cd esp-idf-template
- make all
push_master_to_github:
stage: deploy
only:
- master
when: on_success
image: espressif/esp32-ci-env
variables:
GIT_STRATEGY: clone
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 add github git@github.com:espressif/esp-idf.git
- git push github HEAD:master

2
.gitmodules vendored
Wyświetl plik

@ -1,3 +1,3 @@
[submodule "components/esp32/lib"]
path = components/esp32/lib
url = ssh://git@github.com:espressif/esp32-wifi-lib.git
url = https://github.com/espressif/esp32-wifi-lib.git