Merge "gerrit: copy static files directly into container image"
This commit is contained in:
commit
64d0939da2
@ -22,6 +22,7 @@ RUN mkdir /var/gerrit/plugins && \
|
|||||||
unzip -jo /var/gerrit/bin/gerrit.war WEB-INF/plugins/* -d /var/gerrit/plugins
|
unzip -jo /var/gerrit/bin/gerrit.war WEB-INF/plugins/* -d /var/gerrit/plugins
|
||||||
|
|
||||||
# NOTE(ianw) : copied into build context by playbooks/zuul/gerrit/run.yaml
|
# NOTE(ianw) : copied into build context by playbooks/zuul/gerrit/run.yaml
|
||||||
COPY opendevtheme.html /var/gerrit/plugins/opendevtheme.html
|
COPY plugins/opendevtheme.html /var/gerrit/plugins/opendevtheme.html
|
||||||
|
COPY static/ /var/gerrit/
|
||||||
|
|
||||||
COPY bazel-bin/plugins/zuul-results-summary/zuul-results-summary.jar /var/gerrit/plugins/zuul-results-summary.jar
|
COPY bazel-bin/plugins/zuul-results-summary/zuul-results-summary.jar /var/gerrit/plugins/zuul-results-summary.jar
|
||||||
|
@ -17,7 +17,6 @@ gerrit_container_volumes:
|
|||||||
- /home/gerrit2/review_site/hooks:/var/gerrit/hooks
|
- /home/gerrit2/review_site/hooks:/var/gerrit/hooks
|
||||||
- /home/gerrit2/review_site/index:/var/gerrit/index
|
- /home/gerrit2/review_site/index:/var/gerrit/index
|
||||||
- /home/gerrit2/review_site/logs:/var/log/gerrit
|
- /home/gerrit2/review_site/logs:/var/log/gerrit
|
||||||
- /home/gerrit2/review_site/static:/var/gerrit/static
|
|
||||||
- /home/gerrit2/review_site/tmp:/var/gerrit/tmp
|
- /home/gerrit2/review_site/tmp:/var/gerrit/tmp
|
||||||
- /opt/project-config/gerrit/projects.yaml:/var/gerrit/etc/projects.yaml
|
- /opt/project-config/gerrit/projects.yaml:/var/gerrit/etc/projects.yaml
|
||||||
- /opt/project-config/gerrit/projects.ini:/var/gerrit/etc/projects.ini
|
- /opt/project-config/gerrit/projects.ini:/var/gerrit/etc/projects.ini
|
||||||
|
@ -59,7 +59,6 @@
|
|||||||
- hooks
|
- hooks
|
||||||
- index
|
- index
|
||||||
- logs
|
- logs
|
||||||
- static
|
|
||||||
- tmp
|
- tmp
|
||||||
|
|
||||||
- name: Write Gerrit config file
|
- name: Write Gerrit config file
|
||||||
@ -207,20 +206,6 @@
|
|||||||
- change-abandoned
|
- change-abandoned
|
||||||
- patchset-created
|
- patchset-created
|
||||||
|
|
||||||
# TODO(mordred) These things should really go into the image instead.
|
|
||||||
- name: Copy static and etc
|
|
||||||
copy:
|
|
||||||
src: "{{ item }}"
|
|
||||||
dest: "{{ gerrit_site_dir }}/{{ item }}"
|
|
||||||
owner: "{{ gerrit_user_name }}"
|
|
||||||
group: "{{ gerrit_user_name }}"
|
|
||||||
mode: preserve
|
|
||||||
loop:
|
|
||||||
- static/cla.html
|
|
||||||
- static/robots.txt
|
|
||||||
- static/system-cla.html
|
|
||||||
- static/usg-cla.html
|
|
||||||
|
|
||||||
- name: Write manage-projects script
|
- name: Write manage-projects script
|
||||||
template:
|
template:
|
||||||
src: "manage-projects.j2"
|
src: "manage-projects.j2"
|
||||||
|
@ -34,10 +34,25 @@
|
|||||||
mv $target bazel-bin
|
mv $target bazel-bin
|
||||||
chdir: /home/zuul/src/gerrit.googlesource.com/gerrit
|
chdir: /home/zuul/src/gerrit.googlesource.com/gerrit
|
||||||
|
|
||||||
- name: Install OpenDev theme plugin
|
- name: Install static files to container build context
|
||||||
copy:
|
block:
|
||||||
src: plugins/opendevtheme.html
|
- name: Ensure directories
|
||||||
dest: /home/zuul/src/gerrit.googlesource.com/gerrit/opendevtheme.html
|
file:
|
||||||
|
path: '/home/zuul/src/gerrit.googlesource.com/gerrit/{{ item }}'
|
||||||
|
state: directory
|
||||||
|
loop:
|
||||||
|
- plugins
|
||||||
|
- static
|
||||||
|
- name: Copy static files
|
||||||
|
copy:
|
||||||
|
src: '{{ item }}'
|
||||||
|
dest: '/home/zuul/src/gerrit.googlesource.com/gerrit/{{ item }}'
|
||||||
|
loop:
|
||||||
|
- static/cla.html
|
||||||
|
- static/robots.txt
|
||||||
|
- static/system-cla.html
|
||||||
|
- static/usg-cla.html
|
||||||
|
- plugins/opendevtheme.html
|
||||||
|
|
||||||
- name: Build docker image
|
- name: Build docker image
|
||||||
include_role:
|
include_role:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user