Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Develop #44

Merged
merged 10 commits into from
Jun 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:
id: setup
uses: actions/setup-go@v3
with:
go-version: '^1.19.1'
go-version: '1.19.9'

- name: Go Linter
id: linter
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: '^1.19.1'
go-version: '1.19.9'

- name: Go Linter
uses: golangci/golangci-lint-action@v3
Expand Down Expand Up @@ -91,7 +91,7 @@ jobs:
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: '^1.19.1'
go-version: '1.19.9'

- name: Get Date
run: 'echo "BUILD_DATE=`date +%FT%T%z`" >> $GITHUB_ENV'
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
FROM alpine:3.16.2

LABEL maintainer="Andrei Varabyeu <andrei_varabyeu@epam.com>"
LABEL version=5.7.3
LABEL version=5.8.0

ENV APP_DOWNLOAD_URL https://github.com/reportportal/service-index/releases/download/v5.7.3/service-index_linux_amd64
ENV APP_DOWNLOAD_URL https://github.com/reportportal/service-index/releases/download/v5.8.0/service-index_linux_amd64
RUN apk --no-cache add --upgrade apk-tools

ADD ${APP_DOWNLOAD_URL} /service-index
Expand Down
14 changes: 5 additions & 9 deletions Jenkinsfile.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ node {
checkout scm
}

docker.withServer("$DOCKER_HOST") {
stage('Build Docker Image') {
sh """
MAJOR_VER=\$(cat VERSION)
Expand All @@ -20,29 +19,26 @@ node {
}

stage('Deploy container') {
sh "docker-compose -p reportportal -f $COMPOSE_FILE_RP up -d --force-recreate index"
stage('Push to ECR') {
withEnv(["AWS_URI=${AWS_URI}", "AWS_REGION=${AWS_REGION}"]) {
sh 'docker tag reportportal-dev/service-index ${AWS_URI}/service-index'
def image = env.AWS_URI + '/service-index'
sh 'docker tag reportportal-dev/service-index ${AWS_URI}/service-index:SNAPSHOT-${BUILD_NUMBER}'
def image = env.AWS_URI + '/service-index' + ':SNAPSHOT-' + env.BUILD_NUMBER
def url = 'https://' + env.AWS_URI
def credentials = 'ecr:' + env.AWS_REGION + ':aws_credentials'
echo image
docker.withRegistry(url, credentials) {
docker.image(image).push('SNAPSHOT-${BUILD_NUMBER}')
docker.image(image).push()
}
}
}
}

stage('Cleanup') {
docker.withServer("$DOCKER_HOST") {
withEnv(["AWS_URI=${AWS_URI}"]) {
sh 'docker rmi ${AWS_URI}/service-index:SNAPSHOT-${BUILD_NUMBER}'
sh 'docker rmi ${AWS_URI}/service-index:latest'
}
sh 'docker rmi reportportal-dev/service-index:latest'
}
}
}

}
}
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
5.7.4-SNAPSHOT
5.8.1-SNAPSHOT