Skip to content

Commit 1b7f0cc

Browse files
Remove git describe code in Dockerfile
1 parent 6f966ca commit 1b7f0cc

File tree

1 file changed

+2
-16
lines changed

1 file changed

+2
-16
lines changed

Dockerfile

Lines changed: 2 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -20,34 +20,20 @@ ENV PATH="/opt/gradle/latest/bin:${PATH}"
2020
# Copy the project files
2121
COPY . .
2222

23-
# Copy the git directory for git describe to work
24-
COPY .git .git
25-
26-
# Initialize git and create a commit
27-
# RUN git init && \
28-
# git config --global user.email "[email protected]" && \
29-
# git config --global user.name "Docker Build" && \
30-
# git add . && \
31-
# git commit -m "Initial commit" && \
32-
# # Create a tag to ensure git describe works
33-
# git tag -a v1.0.0 -m "Version 1.0.0"
34-
3523
# Run gradle build with more verbose output
3624
RUN gradle build
3725

3826
# Run gradle shadowJar
3927
RUN gradle shadowJar
4028

4129
# Move the built jar, which is named by git describe, to r5.jar
42-
RUN GIT_DESCRIBE=$(git describe) && \
43-
mv build/libs/r5-${GIT_DESCRIBE}-all.jar r5.jar
30+
RUN mv build/libs/r5-*-all.jar r5.jar
4431

4532

4633
FROM base AS runner
4734
WORKDIR /app
48-
COPY --from=builder /app/build/libs/r5.jar r5.jar
35+
COPY --from=builder /app/r5.jar r5.jar
4936
COPY analysis.properties.docker analysis.properties
50-
RUN mkdir cache
5137

5238
EXPOSE 7070
5339
CMD java -Xmx16g -cp r5.jar com.conveyal.analysis.BackendMain

0 commit comments

Comments
 (0)