Commit 529af251 authored by nimrod's avatar nimrod
Browse files

WebDAV image.

parent 20584f79
Loading
Loading
Loading
Loading
Loading
+16 −0
Original line number Diff line number Diff line
@@ -116,3 +116,19 @@ push-sleep:
  needs:
    - job: build-sleep
      artifacts: true

# webdav image:

build-webdav:
  extends: .container-build
  variables:
    CONTEXT: webdav

push-webdav:
  extends: .container-push
  variables:
    CONTEXT: webdav
    IMAGE: webdav
  needs:
    - job: build-webdav
      artifacts: true

webdav/.dockerignore

0 → 100644
+3 −0
Original line number Diff line number Diff line
*
!webdav.conf
!webdav-readonly.conf

webdav/Dockerfile

0 → 100644
+11 −0
Original line number Diff line number Diff line
FROM registry.shore.co.il/httpd:bullseye
USER root
RUN a2enmod dav && \
    a2enmod dav_fs && \
    a2enmod dav_lock && \
    install -d -m 750 -o root -g www-data /var/www/webdav && \
    rm -rf /tmp/* /var/tmp/*
COPY --chown=root:root webdav.conf /etc/apache2/conf-enabled/
COPY --chown=root:root webdav-readonly.conf /etc/apache2/conf-enabled/
USER www-data
RUN apache2 -t

webdav/README.md

0 → 100644
+22 −0
Original line number Diff line number Diff line
# WebDAV container image

Apache2 with WebDAV enabled and configured.

## Usage

The directory that is shared is `/var/www/webdav`, so mount something there.

```
docker run -v '/mnt/foo:/var/www/webdav' -p 80:80 registry.shore.co.il/webdav
```

This image allows read-only access by default. If you want to change that build
your own image and delete `/etc/apache2/conf-enabled/webdav-readonly.conf` like
so:

```
FROM registry.shore.co.il/webdav
USER root
RUN rm /etc/apache2/conf-enabled/webdav-readonly.conf
USER www-data
```
+4 −0
Original line number Diff line number Diff line
# vim: ft=apache
<Directory /var/www/webdav>
    Require method GET OPTIONS PROPFIND
</Directory>
Loading