Skip to content

Commit e46ff8a

Browse files
author
Anuraag Agrawal
committed
Add main.yml
1 parent 51c3781 commit e46ff8a

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed

.github/workflows-main-build

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
on:
2+
push:
3+
branches:
4+
- main
5+
6+
jobs:
7+
build:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- uses: actions/checkout@v2
11+
- uses: actions/setup-java@v1
12+
with:
13+
java-version: 14
14+
- uses: gradle/wrapper-validation-action@v1
15+
- name: Login to GitHub Package Registry
16+
run: echo ${{ secrets.CONTAINER_REGISTRY_TOKEN }} | docker login ghcr.io -u anuraaga --password-stdin
17+
- name: Build snapshot with Gradle
18+
uses: burrunan/gradle-cache-action@v1
19+
with:
20+
arguments: build snapshot --stacktrace -PenableCoverage=true
21+
env:
22+
PUBLISH_USERNAME: ${{ github.actor }}
23+
PUBLISH_PASSWORD: ${{ secrets.GITHUB_TOKEN }}
24+
- name: Upload to GitHub Actions
25+
uses: actions/upload-artifact@v2
26+
with:
27+
name: aws-opentelemetry-agent.jar
28+
path: otelagent/build/libs/aws-opentelemetry-agent-*.jar
29+
- name: Build and push agent docker image with Gradle
30+
uses: burrunan/gradle-cache-action@v1
31+
with:
32+
arguments: :otelagent:jib
33+
- name: Build and push spring-boot smoke-tests
34+
uses: burrunan/gradle-cache-action@v1
35+
with:
36+
arguments: :smoke-tests:spring-boot:jib
37+
- uses: codecov/codecov-action@v1
38+

0 commit comments

Comments
 (0)