LAST233 commited on
Commit
166ab5f
·
verified ·
1 Parent(s): 1257b3a

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +3 -3
Dockerfile CHANGED
@@ -27,8 +27,11 @@ COPY cph-ng-0.5.5.vsix /home/coder/
27
  COPY vscode-luogu.vsix /home/coder/
28
  RUN chmod +x /home/coder/create_languagepacks.sh
29
 
 
30
  COPY autocommit.sh /usr/coder/scripts/autocommit.sh
31
  RUN chmod +x /usr/coder/scripts/autocommit.sh
 
 
32
 
33
  # 将 /home/coder 下所有文件的所有权移交给 coder 用户
34
  RUN chown -R coder:coder /home/coder
@@ -57,9 +60,6 @@ RUN --mount=type=secret,id=GH_TOKEN,mode=0444,required=true \
57
  git config --global user.email $(cat /run/secrets/GH_EMAIL) && \
58
  git clone https://$(cat /run/secrets/GH_TOKEN)@github.com/$(cat /run/secrets/GH_USERNAME)/$(cat /run/secrets/REPO_NAME).git /home/coder/cpp_competition
59
 
60
- # 配置git自动提交
61
- RUN echo "30 2 */2 * * coder /bin/bash /usr/coder/scripts/autocommit.sh" > /etc/cron.d/autocommit-cron
62
- RUN chmod 0644 /etc/cron.d/autocommit-cron
63
 
64
  # 暴露端口
65
  EXPOSE 8080
 
27
  COPY vscode-luogu.vsix /home/coder/
28
  RUN chmod +x /home/coder/create_languagepacks.sh
29
 
30
+ # 配置git自动提交
31
  COPY autocommit.sh /usr/coder/scripts/autocommit.sh
32
  RUN chmod +x /usr/coder/scripts/autocommit.sh
33
+ RUN echo "30 2 */2 * * root /bin/bash /usr/coder/scripts/autocommit.sh" > /etc/cron.d/autocommit-cron
34
+ RUN chmod 0644 /etc/cron.d/autocommit-cron
35
 
36
  # 将 /home/coder 下所有文件的所有权移交给 coder 用户
37
  RUN chown -R coder:coder /home/coder
 
60
  git config --global user.email $(cat /run/secrets/GH_EMAIL) && \
61
  git clone https://$(cat /run/secrets/GH_TOKEN)@github.com/$(cat /run/secrets/GH_USERNAME)/$(cat /run/secrets/REPO_NAME).git /home/coder/cpp_competition
62
 
 
 
 
63
 
64
  # 暴露端口
65
  EXPOSE 8080