fixing permissions
Deploy / deploy (push) Successful in 8s

This commit is contained in:
2026-05-06 12:05:09 +02:00
parent 4565678c5a
commit c940864c60
3 changed files with 12 additions and 2 deletions
+6 -1
View File
@@ -12,4 +12,9 @@ COPY composer.json /app/composer.json
RUN composer install --no-dev --no-interaction 2>/dev/null || true
COPY . /app
RUN composer dump-autoload --no-dev --no-interaction 2>/dev/null || true
RUN composer dump-autoload --no-dev --no-interaction 2>/dev/null || true
COPY docker/entrypoint-api.sh /usr/local/bin/entrypoint-api.sh
RUN chmod +x /usr/local/bin/entrypoint-api.sh
ENTRYPOINT ["/usr/local/bin/entrypoint-api.sh"]
CMD ["php-fpm"]
+4
View File
@@ -0,0 +1,4 @@
#!/bin/sh
mkdir -p /app/data
chown -R www-data:www-data /app/data 2>/dev/null || chmod -R 777 /app/data 2>/dev/null || true
exec docker-php-entrypoint "$@"
+2 -1
View File
@@ -10,8 +10,9 @@ class Database
{
$dir = dirname($path);
if (!is_dir($dir)) {
mkdir($dir, 0755, true);
@mkdir($dir, 0777, true);
}
@chmod($dir, 0777);
$this->pdo = new \PDO("sqlite:$path");
$this->pdo->setAttribute(\PDO::ATTR_ERRMODE, \PDO::ERRMODE_EXCEPTION);