Skip to content

Instantly share code, notes, and snippets.

@NaveenBandarage
Created May 7, 2020 10:39
Show Gist options
  • Save NaveenBandarage/0c76dcd474a0b83cff005beb1516ffcd to your computer and use it in GitHub Desktop.
Save NaveenBandarage/0c76dcd474a0b83cff005beb1516ffcd to your computer and use it in GitHub Desktop.
# stages:
# - Build
# - Test
# - Deploy
# build:
# stage: Build
# tags:
# - Shell
# script:
# - echo "static analysis"
# - exit 1
# allow_failure: true
# unittest:
# stage: Test
# tags:
# - Shell
# script:
# - echo "test"
# - exit 1
# allow_failure: true
# deploy:
# stage: Deploy
# tags:
# - Shell
# script:
# - echo "deploy"
# - exit 1
# allow_failure: true
image: java:latest
stages:
- build
- execute
build:
stage: build
script: /usr/lib/jvm/java-8-openjdk-amd64/bin/javac HelloWorld.java
artifacts:
paths:
- HelloWorld.*
execute:
stage: execute
script: /usr/lib/jvm/java-8-openjdk-amd64/bin/java HelloWorld
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment