Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Verified Commit add1c818 authored by Nicolas Gelot's avatar Nicolas Gelot
Browse files

chore: using apps from gitlab registry

parent 4538e0ea
Loading
Loading
Loading
Loading
+30 −74
Original line number Diff line number Diff line
@@ -3,91 +3,47 @@ FROM nextcloud:29.0.14-fpm
ARG BASE_DIR="/usr/src/nextcloud"
ARG TMP_PATCH_DIR="/tmp/build_patches"

ARG NOTES_VERSION="4.11.0"
ARG CONTACTS_JOB_ID="881946"
ARG CALENDAR_JOB_ID="991372"
ARG THEME_HELPER_JOB_ID="1168069"
ARG THEME_VERSION="28.0.2"
ARG LAUNCHER_JOB_ID="1168135"
ARG DASHBOARD_JOB_ID="1168115"
ARG CONTACTS_URL="https://gitlab.e.foundation/api/v4/projects/1238/packages/generic/contacts/v5.5.3+murena-20250822/contacts-v5.5.3+murena-20250822.tar.gz"
ARG CALENDAR_URL="https://gitlab.e.foundation/api/v4/projects/1199/packages/generic/calendar/v4.7.13+murena-20250822/calendar-v4.7.13+murena-20250822.tar.gz"
ARG THEME_HELPER_URL="https://gitlab.e.foundation/api/v4/projects/952/packages/generic/ecloud-theme-helper/v7.0.3/ecloud-theme-helper-v7.0.3.tar.gz"
ARG LAUNCHER_URL="https://gitlab.e.foundation/api/v4/projects/927/packages/generic/murena_launcher/v7.0.3/murena_launcher-v7.0.3.tar.gz"
ARG DASHBOARD_URL="https://gitlab.e.foundation/api/v4/projects/1195/packages/generic/murena-dashboard/v7.1.2/murena-dashboard-v7.1.2.tar.gz"
ARG SNAPPY_URL="https://gitlab.e.foundation/api/v4/projects/1367/packages/generic/snappymail/v2.38.2+murena-20250822/snappymail-v2.38.2+murena-20250822.tar.gz"

ARG NOTES_URL="https://github.com/nextcloud-releases/notes/releases/download/v4.11.0/notes-v4.11.0.tar.gz"
ARG TASKS_URL="https://github.com/nextcloud/tasks/releases/download/v0.16.1/tasks.tar.gz"
ARG SENTRY_URL="https://github.com/ChristophWurst/nextcloud_sentry/releases/download/v8.15.0/sentry-v8.15.0.tar.gz"
ARG SNAPPY_VERSION="2.37.2"
ARG SNAPPY_THEME_VERSION="4.0.1"

ARG THEME_VERSION="https://gitlab.e.foundation/api/v4/projects/315/packages/generic/eCloud/v29.0.18/eCloud-v29.0.18.tar.gz"
ARG SNAPPY_THEME_VERSION="https://gitlab.e.foundation/api/v4/projects/1377/packages/generic/snappymail/v4.0.5/snappymail-v4.0.5.tar.gz"

COPY custom_entrypoint.sh /
COPY hooks.d/post-installation/ /docker-entrypoint-hooks.d/post-installation/

RUN sed -i 's/29,0,14,1/29,0,14,2/' ${BASE_DIR}/version.php
RUN rm -rf ${BASE_DIR}/core/skeleton/* \
RUN rm -rf ${BASE_DIR}/core/skeleton/* ${BASE_DIR}/themes/example \
 && mkdir -p ${BASE_DIR}/core/skeleton/Documents \
 && mkdir -p ${BASE_DIR}/core/skeleton/Images
 && mkdir -p ${BASE_DIR}/core/skeleton/Images \
 && mkdir -p ${BASE_DIR}/themes/Murena

# Install unzip for unzipping artifacts
RUN apt-get update && apt-get install -y unzip ffmpeg syslog-ng

RUN curl -fsSL -o notes.tar.gz \
  "https://github.com/nextcloud-releases/notes/releases/download/v${NOTES_VERSION}/notes-v${NOTES_VERSION}.tar.gz" && \
  tar -xf notes.tar.gz -C ${BASE_DIR}/custom_apps/ && \
  rm notes.tar.gz;

# custom Contact
RUN curl -fsSL -o contacts.zip \
  "https://gitlab.e.foundation/e/infra/ecloud/nextcloud-apps/contacts/-/jobs/${CONTACTS_JOB_ID}/artifacts/download" && \
  unzip contacts.zip && \
  mv dist/contacts ${BASE_DIR}/custom_apps/ && \
  rm contacts.zip;

RUN curl -fsSL -o calendar.zip \
  "https://gitlab.e.foundation/e/infra/ecloud/nextcloud-apps/calendar/-/jobs/${CALENDAR_JOB_ID}/artifacts/download" && \
  unzip calendar.zip && \
  mv dist/calendar ${BASE_DIR}/custom_apps/ && \
  rm calendar.zip;

RUN curl -fsSL -o ecloud-theme-helper.zip \
  "https://gitlab.e.foundation/e/infra/ecloud/nextcloud-apps/ecloud-theme-helper/-/jobs/${THEME_HELPER_JOB_ID}/artifacts/download" && \
  unzip ecloud-theme-helper.zip && \
  mv dist/ecloud-theme-helper ${BASE_DIR}/custom_apps/ && \
  rm ecloud-theme-helper.zip;

# Custom theme
RUN rm -rf ${BASE_DIR}/themes/eCloud && \
  curl -fsSL -o eCloud-theme.tar.gz \
  "https://gitlab.e.foundation/e/infra/ecloud/nextcloud-apps/nextcloud-theme/-/archive/${THEME_VERSION}/nextcloud-theme-${THEME_VERSION}.tar.gz" && \
  tar -xf eCloud-theme.tar.gz -C /tmp/ && \
  mv /tmp/nextcloud-theme-${THEME_VERSION}/ ${BASE_DIR}/themes/eCloud && \
  chown -R www-data:www-data ${BASE_DIR}/themes/eCloud/ && \
  rm -rf eCloud-theme.tar.gz ${BASE_DIR}/themes/example/

RUN curl -fsSL -o murena_launcher.zip \
  "https://gitlab.e.foundation/e/infra/ecloud/nextcloud-apps/launcher/-/jobs/${LAUNCHER_JOB_ID}/artifacts/download" && \
  unzip murena_launcher.zip && \
  mv dist/murena_launcher ${BASE_DIR}/custom_apps/ && \
  rm murena_launcher.zip;

RUN curl -fsSL -o ecloud-dashboard.zip \
  "https://gitlab.e.foundation/e/infra/ecloud/nextcloud-apps/murena-dashboard/-/jobs/${DASHBOARD_JOB_ID}/artifacts/download" && \
  unzip ecloud-dashboard.zip && \
  mv dist/murena-dashboard ${BASE_DIR}/custom_apps/ && \
  rm ecloud-dashboard.zip;

RUN curl -fsSL -o snappymail.tar.gz \
  "https://snappymail.eu/repository/nextcloud/snappymail-${SNAPPY_VERSION}-nextcloud.tar.gz" && \
  tar -xf snappymail.tar.gz -C ${BASE_DIR}/custom_apps/ && \
  rm snappymail.tar.gz;

# Snappy theme
RUN curl -fsSL -o Murena-snappymail-theme.tar.gz \
  "https://gitlab.e.foundation/e/infra/ecloud/nextcloud-apps/snappymail-theme/-/archive/${SNAPPY_THEME_VERSION}/snappymail-theme-${SNAPPY_THEME_VERSION}.tar.gz" && \
  tar -xf Murena-snappymail-theme.tar.gz -C /tmp/ && \
  mkdir -p ${BASE_DIR}/themes/Murena && \
  mv /tmp/snappymail-theme-${SNAPPY_THEME_VERSION}/ ${BASE_DIR}/themes/Murena/snappymail && \
  chown -R www-data:www-data ${BASE_DIR}/themes/Murena/ && \
  rm -rf Murena-snappymail-theme.tar.gz

RUN bash -c "curl -sL ${TASKS_URL} | tar xzf - -C ${BASE_DIR}/custom_apps"
RUN bash -c "curl -sL ${SENTRY_URL} | tar xzf - -C ${BASE_DIR}/custom_apps"

# Murena apps
RUN curl -sL ${CONTACTS_URL} | tar xzf - -C ${BASE_DIR}/custom_apps
RUN curl -sL ${CALENDAR_URL} | tar xzf - -C ${BASE_DIR}/custom_apps
RUN curl -sL ${THEME_HELPER_URL} | tar xzf - -C ${BASE_DIR}/custom_apps
RUN curl -sL ${LAUNCHER_URL} | tar xzf - -C ${BASE_DIR}/custom_apps
RUN curl -sL ${DASHBOARD_URL} | tar xzf - -C ${BASE_DIR}/custom_apps
RUN curl -sL ${SNAPPY_URL} | tar xzf - -C ${BASE_DIR}/custom_apps

# External apps
RUN curl -sL ${NOTES_URL} | tar xzf - -C ${BASE_DIR}/custom_apps
RUN curl -sL ${TASKS_URL} | tar xzf - -C ${BASE_DIR}/custom_apps
RUN curl -sL ${SENTRY_URL} | tar xzf - -C ${BASE_DIR}/custom_apps

# Murena theme
RUN curl -sL ${THEME_VERSION} | tar xzf - -C ${BASE_DIR}/themes
RUN curl -sL ${SNAPPY_THEME_VERSION} | tar xzf - -C ${BASE_DIR}/themes/Murena/

# Patches
COPY patches/ ${TMP_PATCH_DIR}/