Skip to content

Commit

Permalink
Fix bug where wrong dockerfile being used in upload to docker hub
Browse files Browse the repository at this point in the history
  • Loading branch information
shayaantx committed Jan 24, 2021
1 parent df6097e commit 2d1f07a
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -115,21 +115,6 @@ pipeline {
}
steps {
script {
def dockerFileImage = """
FROM centos:7
RUN yum update; yum clean all; yum -y install java-1.8.0-openjdk-devel.x86_64;
ENV JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk
ENV PATH=$PATH:$JAVA_HOME/bin
RUN mkdir -p /home/botdarr
ADD target/botdarr-release.jar /home/botdarr
WORKDIR /home/botdarr
RUN java -version
ENTRYPOINT ["java", "-jar", "botdarr-release.jar"]
""";
fileOperations([fileCreateOperation(fileContent: "${dockerFileImage}", fileName: './DockerfileUpload')]);
def releaseTag = "latest";
def imageWithReleaseTag = docker.build("${username}/botdarr:${releaseTag}", "-f ./DockerfileUpload .");
withDockerRegistry(credentialsId: 'docker-credentials') {
Expand Down

0 comments on commit 2d1f07a

Please sign in to comment.