diff options
Diffstat (limited to 'vendor/gitlab-ci-yml')
-rw-r--r-- | vendor/gitlab-ci-yml/.gitlab-ci.yml | 4 | ||||
-rw-r--r-- | vendor/gitlab-ci-yml/Docker.gitlab-ci.yml | 7 | ||||
-rw-r--r-- | vendor/gitlab-ci-yml/Gradle.gitlab-ci.yml | 34 | ||||
-rw-r--r-- | vendor/gitlab-ci-yml/Julia.gitlab-ci.yml | 54 | ||||
-rw-r--r-- | vendor/gitlab-ci-yml/Ruby.gitlab-ci.yml | 9 | ||||
-rw-r--r-- | vendor/gitlab-ci-yml/Swift.gitlab-ci.yml | 30 |
6 files changed, 137 insertions, 1 deletions
diff --git a/vendor/gitlab-ci-yml/.gitlab-ci.yml b/vendor/gitlab-ci-yml/.gitlab-ci.yml new file mode 100644 index 00000000000..18b14554887 --- /dev/null +++ b/vendor/gitlab-ci-yml/.gitlab-ci.yml @@ -0,0 +1,4 @@ +image: ruby:2.3-alpine + +test: + script: ruby verify_templates.rb diff --git a/vendor/gitlab-ci-yml/Docker.gitlab-ci.yml b/vendor/gitlab-ci-yml/Docker.gitlab-ci.yml index 396d3f1b042..f3fa3949656 100644 --- a/vendor/gitlab-ci-yml/Docker.gitlab-ci.yml +++ b/vendor/gitlab-ci-yml/Docker.gitlab-ci.yml @@ -1,7 +1,12 @@ # Official docker image. image: docker:latest +services: + - docker:dind + build: stage: build script: - - docker build -t test . + - docker login -u "gitlab-ci-token" -p "$CI_BUILD_TOKEN" $CI_REGISTRY + - docker build --pull -t "$CI_REGISTRY_IMAGE:$CI_BUILD_REF_NAME" . + - docker push "$CI_REGISTRY_IMAGE:$CI_BUILD_REF_NAME" diff --git a/vendor/gitlab-ci-yml/Gradle.gitlab-ci.yml b/vendor/gitlab-ci-yml/Gradle.gitlab-ci.yml new file mode 100644 index 00000000000..263c4c19999 --- /dev/null +++ b/vendor/gitlab-ci-yml/Gradle.gitlab-ci.yml @@ -0,0 +1,34 @@ +# This template uses the java:8 docker image because there isn't any +# official Gradle image at this moment +# +# This is the Gradle build system for JVM applications +# https://gradle.org/ +# https://github.com/gradle/gradle +image: java:8 + +# Make the gradle wrapper executable. This essentially downloads a copy of +# Gradle to build the project with. +# https://docs.gradle.org/current/userguide/gradle_wrapper.html +# It is expected that any modern gradle project has a wrapper +before_script: + - chmod +x gradlew + +# We redirect the gradle user home using -g so that it caches the +# wrapper and dependencies. +# https://docs.gradle.org/current/userguide/gradle_command_line.html +# +# Unfortunately it also caches the build output so +# cleaning removes reminants of any cached builds. +# The assemble task actually builds the project. +# If it fails here, the tests can't run. +build: + stage: build + script: + - ./gradlew -g /cache/.gradle clean assemble + allow_failure: false + +# Use the generated build output to run the tests. +test: + stage: test + script: + - ./gradlew -g /cache./gradle check diff --git a/vendor/gitlab-ci-yml/Julia.gitlab-ci.yml b/vendor/gitlab-ci-yml/Julia.gitlab-ci.yml new file mode 100644 index 00000000000..140cb4635f3 --- /dev/null +++ b/vendor/gitlab-ci-yml/Julia.gitlab-ci.yml @@ -0,0 +1,54 @@ +# An example .gitlab-ci.yml file to test (and optionally report the coverage +# results of) your [Julia][1] packages. Please refer to the [documentation][2] +# for more information about package development in Julia. +# +# Here, it is assumed that your Julia package is named `MyPackage`. Change it to +# whatever name you have given to your package. +# +# [1]: http://julialang.org/ +# [2]: http://julia.readthedocs.org/ + +# Below is the template to run your tests in Julia +.test_template: &test_definition + # Uncomment below if you would like to run the tests on specific references + # only, such as the branches `master`, `development`, etc. + # only: + # - master + # - development + script: + # Let's run the tests. Substitute `coverage = false` below, if you do not + # want coverage results. + - /opt/julia/bin/julia -e 'Pkg.clone(pwd()); Pkg.test("MyPackage", + coverage = true)' + # Comment out below if you do not want coverage results. + - /opt/julia/bin/julia -e 'Pkg.add("Coverage"); cd(Pkg.dir("MyPackage")); + using Coverage; cl, tl = get_summary(process_folder()); + println("(", cl/tl*100, "%) covered")' + +# Name a test and select an appropriate image. +test:0.4.6: + image: julialang/julia:v0.4.6 + <<: *test_definition + +# Maybe you would like to test your package against the development branch: +test:0.5.0-dev: + image: julialang/julia:v0.5.0-dev + # ... allowing for failures, since we are testing against the development + # branch: + allow_failure: true + <<: *test_definition + +# REMARK: Do not forget to enable the coverage feature for your project, if you +# are using code coverage reporting above. This can be done by +# +# - Navigating to the `CI/CD Pipelines` settings of your project, +# - Copying and pasting the default `Simplecov` regex example provided, i.e., +# `\(\d+.\d+\%\) covered` in the `test coverage parsing` textfield. +# +# WARNING: This template is using the `julialang/julia` images from [Docker +# Hub][3]. One can use custom Julia images and/or the official ones found +# in the same place. However, care must be taken to correctly locate the binary +# file (`/opt/julia/bin/julia` above), which is usually given on the image's +# description page. +# +# [3]: http://hub.docker.com/ diff --git a/vendor/gitlab-ci-yml/Ruby.gitlab-ci.yml b/vendor/gitlab-ci-yml/Ruby.gitlab-ci.yml index 166f146ee05..08b57c8c0ac 100644 --- a/vendor/gitlab-ci-yml/Ruby.gitlab-ci.yml +++ b/vendor/gitlab-ci-yml/Ruby.gitlab-ci.yml @@ -43,3 +43,12 @@ rails: - bundle exec rake db:migrate - bundle exec rake db:seed - bundle exec rake test + +# This deploy job uses a simple deploy flow to Heroku, other providers, e.g. AWS Elastic Beanstalk +# are supported too: https://github.com/travis-ci/dpl +deploy: + type: deploy + environment: production + script: + - gem install dpl + - dpl --provider=heroku --app=$HEROKU_APP_NAME --api-key=$HEROKU_PRODUCTION_KEY diff --git a/vendor/gitlab-ci-yml/Swift.gitlab-ci.yml b/vendor/gitlab-ci-yml/Swift.gitlab-ci.yml new file mode 100644 index 00000000000..c9c35906d1c --- /dev/null +++ b/vendor/gitlab-ci-yml/Swift.gitlab-ci.yml @@ -0,0 +1,30 @@ +# Lifted from: https://about.gitlab.com/2016/03/10/setting-up-gitlab-ci-for-ios-projects/ +# This file assumes an own GitLab CI runner, setup on an OS X system. +stages: + - build + - archive + +build_project: + stage: build + script: + - xcodebuild clean -project ProjectName.xcodeproj -scheme SchemeName | xcpretty + - xcodebuild test -project ProjectName.xcodeproj -scheme SchemeName -destination 'platform=iOS Simulator,name=iPhone 6s,OS=9.2' | xcpretty -s + tags: + - ios_9-2 + - xcode_7-2 + - osx_10-11 + +archive_project: + stage: archive + script: + - xcodebuild clean archive -archivePath build/ProjectName -scheme SchemeName + - xcodebuild -exportArchive -exportFormat ipa -archivePath "build/ProjectName.xcarchive" -exportPath "build/ProjectName.ipa" -exportProvisioningProfile "ProvisioningProfileName" + only: + - master + artifacts: + paths: + - build/ProjectName.ipa + tags: + - ios_9-2 + - xcode_7-2 + - osx_10-11 |