diff options
author | Gerald Combs <gerald@wireshark.org> | 2020-12-21 12:09:55 -0800 |
---|---|---|
committer | Gerald Combs <gerald@wireshark.org> | 2020-12-21 14:25:11 -0800 |
commit | c971d7f10c8e55cd3f8cd9302e5ef0b134abc8d5 (patch) | |
tree | 7b7745b919d34576dfc599791d22255afb594fae /.gitlab-ci.yml | |
parent | e2593e20227e2482268f1e69e66537d8de4a6712 (diff) |
GitLab CI: Copy the dist (tarball) build.
Copy it to an S3 bucket if the appropriate environment variables are set
and add it as an artifact.
Diffstat (limited to '.gitlab-ci.yml')
-rw-r--r-- | .gitlab-ci.yml | 25 |
1 files changed, 11 insertions, 14 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 5f2b26b006..49e6e53ad0 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -50,6 +50,8 @@ # setcap restricts our library paths - CFLAGS=-Wl,-rpath=$(pwd)/run CXXFLAGS=-Wl,-rpath=$(pwd)/run cmake -GNinja $CMAKE_ARGS .. - ninja + - ninja install + - ninja shellcheck - ninja test-programs - chown -R user . - if [ -f run/dumpcap ]; then setcap cap_net_raw,cap_net_admin+eip run/dumpcap; fi @@ -75,21 +77,16 @@ build:ubuntu-dist: script: - perl ../tools/make-version.pl --set-release || ../perl make-version.pl --set-release - cmake -G Ninja $CMAKE_ARGS -DENABLE_CCACHE=ON .. - - ninja install - # - XXX The master Buildbot config built and copied the API reference - packaging/source/git-export-release.sh -d . - - for digest in sha256 rmd160 sha1 ; do openssl $digest wireshark-*.tar.xz ; done - # XXX Should these be in test:ubuntu? - # - ninja test-programs - # - chown -R user . - # - if [ -f run/dumpcap ]; then setcap cap_net_raw,cap_net_admin+eip run/dumpcap; fi - # - su user -c pytest-3 - - ninja shellcheck - # We're still building tarballs on Buildbot. Leave this disabled for now - # in order to avoid confusion. - # artifacts: - # paths: - # - wireshark-*.tar.xz + - mv -v wireshark-*.tar.* "$CI_PROJECT_DIR"/ + after_script: + - ccache --max-size $( du --summarize --block-size=1M "$CI_PROJECT_DIR/build" | awk '{printf ("%dM", $1 * 1.5)}' ) + - for digest in sha256 rmd160 sha1 ; do openssl $digest wireshark-*.tar.* ; done + # This will break if we produce multiple tarballs, which is arguably a good thing. + - if [ -n "$AWS_ACCESS_KEY_ID" ] && [ -n "$AWS_SECRET_ACCESS_KEY" ] && [ -n "$S3_DESTINATION_DIST" ] ; then aws s3 cp wireshark-*.tar.* "$S3_DESTINATION_DIST/" ; fi + artifacts: + paths: + - wireshark-*.tar.* # The custom CentOS 7 image pre-installs dependencies and compilers to speed up the build: # https://hub.docker.com/r/wireshark/wireshark-centos-7-dev |