Skip to content

Commit 361ba45

Browse files
committed
Maven
1 parent 43055a8 commit 361ba45

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

.gitpod.Dockerfile

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,13 @@ RUN wget https://services.gradle.org/distributions/gradle-${GRADLE_VERSION}-bin.
1717
unzip -d /opt/gradle /tmp/gradle-${GRADLE_VERSION}-bin.zip && \
1818
ln -s /opt/gradle/gradle-${GRADLE_VERSION}/bin/gradle /usr/bin/gradle
1919

20+
USER gitpod
21+
2022
# Ensure that Gradle saves all files in /workspace, because files outside that folder are not being backed up when a prebuild finishes or a workspace stops.
2123
ENV GRADLE_USER_HOME=/workspace/.gradle/
2224

23-
USER gitpod
25+
# Ensure that Maven dependencies are saved in /workspace, because files outside that folder are not being backed up when a prebuild finishes or a workspace stops.
26+
RUN mkdir /home/gitpod/.m2 && \
27+
printf '<settings>\n <localRepository>/workspace/m2-repository/</localRepository>\n</settings>\n' > /home/gitpod/.m2/settings.xml
28+
29+

0 commit comments

Comments
 (0)