kenken999 commited on
Commit
dc5e94d
·
verified ·
1 Parent(s): 07c3cdd

Fix: Simplify Dockerfile and remove problematic COPY commands

Browse files
Files changed (1) hide show
  1. Dockerfile +8 -24
Dockerfile CHANGED
@@ -11,7 +11,6 @@ RUN apt-get update && apt-get install -y \
11
  libzip-dev \
12
  libxml2-dev \
13
  libcurl4-openssl-dev \
14
- libmcrypt-dev \
15
  unzip \
16
  wget \
17
  git \
@@ -23,7 +22,6 @@ RUN apt-get update && apt-get install -y \
23
  pdo_mysql \
24
  zip \
25
  soap \
26
- curl \
27
  xml \
28
  mbstring \
29
  && a2enmod rewrite expires headers \
@@ -35,22 +33,15 @@ RUN sed -i 's/80/7860/g' /etc/apache2/sites-available/000-default.conf /etc/apac
35
  # Set ServerName
36
  RUN echo "ServerName localhost" >> /etc/apache2/apache2.conf
37
 
38
- # Download and extract ProcessMaker
39
- WORKDIR /tmp
40
- RUN wget https://huggingface.co/spaces/kenken999/processmaker-runner/resolve/main/processmaker-3.2.3-community.tar.gz -O processmaker.tar.gz || \
41
- echo "Will use existing tar.gz from base image"
42
-
43
- # Extract ProcessMaker to Apache DocumentRoot
44
- RUN if [ -f /tmp/processmaker.tar.gz ]; then \
45
- tar -xzf /tmp/processmaker.tar.gz -C /tmp && \
46
- if [ -d /tmp/processmaker ]; then \
47
- cp -r /tmp/processmaker/* /var/www/html/ && \
48
- rm -rf /tmp/processmaker /tmp/processmaker.tar.gz; \
49
- fi; \
50
- fi
51
 
52
- # Copy ProcessMaker files (if provided locally)
53
- COPY processmaker-files/ /var/www/html/ 2>/dev/null || true
54
 
55
  # Set permissions
56
  RUN chown -R www-data:www-data /var/www/html \
@@ -61,13 +52,6 @@ RUN if [ -d /var/www/html/workflow/public_html ]; then \
61
  sed -i 's|DocumentRoot /var/www/html|DocumentRoot /var/www/html/workflow/public_html|' /etc/apache2/sites-available/000-default.conf; \
62
  fi
63
 
64
- # Environment variables for database (will use Hugging Face Secrets)
65
- ENV DB_HOST=${DB_HOST:-localhost}
66
- ENV DB_PORT=${DB_PORT:-3306}
67
- ENV DB_NAME=${DB_NAME:-processmaker}
68
- ENV DB_USER=${DB_USER:-root}
69
- ENV DB_PASS=${DB_PASS:-}
70
-
71
  # Copy entrypoint script
72
  COPY entrypoint.sh /entrypoint.sh
73
  RUN chmod +x /entrypoint.sh
 
11
  libzip-dev \
12
  libxml2-dev \
13
  libcurl4-openssl-dev \
 
14
  unzip \
15
  wget \
16
  git \
 
22
  pdo_mysql \
23
  zip \
24
  soap \
 
25
  xml \
26
  mbstring \
27
  && a2enmod rewrite expires headers \
 
33
  # Set ServerName
34
  RUN echo "ServerName localhost" >> /etc/apache2/apache2.conf
35
 
36
+ # Environment variables for database (will use Hugging Face Secrets)
37
+ ENV DB_HOST=${DB_HOST:-localhost}
38
+ ENV DB_PORT=${DB_PORT:-3306}
39
+ ENV DB_NAME=${DB_NAME:-processmaker}
40
+ ENV DB_USER=${DB_USER:-root}
41
+ ENV DB_PASS=${DB_PASS:-}
 
 
 
 
 
 
 
42
 
43
+ # Copy ProcessMaker files
44
+ COPY processmaker-files/ /var/www/html/
45
 
46
  # Set permissions
47
  RUN chown -R www-data:www-data /var/www/html \
 
52
  sed -i 's|DocumentRoot /var/www/html|DocumentRoot /var/www/html/workflow/public_html|' /etc/apache2/sites-available/000-default.conf; \
53
  fi
54
 
 
 
 
 
 
 
 
55
  # Copy entrypoint script
56
  COPY entrypoint.sh /entrypoint.sh
57
  RUN chmod +x /entrypoint.sh