1
0
Fork 0
mirror of https://github.com/24eme/signaturepdf synced 2024-05-02 22:13:11 +02:00
Go to file
2022-04-01 17:34:35 +02:00
.github/workflows ci: dockerize and push with gh-actions 2022-01-28 17:23:51 +01:00
config Storage path of the pdf in config and disabled in the interface if not defined 2022-04-01 17:34:35 +02:00
public Formatting of the signature counter 2022-04-01 16:54:50 +02:00
templates Storage path of the pdf in config and disabled in the interface if not defined 2022-04-01 17:34:35 +02:00
tests L'ajout de texte avec accent est possible maintenant 2022-01-04 09:37:53 +01:00
vendor/fatfree Fatfree core lib only 2022-03-26 23:40:57 +01:00
.editorconfig Définition des normes d'édition 2021-10-12 01:02:40 +02:00
.gitignore Storage path of the pdf in config and disabled in the interface if not defined 2022-04-01 17:34:35 +02:00
apache.conf ci: dockerize and push with gh-actions 2022-01-28 17:23:51 +01:00
app.php Storage path of the pdf in config and disabled in the interface if not defined 2022-04-01 17:34:35 +02:00
Dockerfile chore: config php.ini with env 2022-01-28 18:23:43 +01:00
LICENSE License AGPLV3 2021-05-04 00:58:47 +02:00
Makefile Testes fonctionnels de la signature d'un pdf avec jest et puppeteer 2021-10-24 01:38:57 +02:00
php.ini chore: config php.ini with env 2022-01-28 18:23:43 +01:00
README.md docs: fix README 2022-01-30 20:49:44 +01:00

Signature de PDF

Logiciel web libre permettant de signer un PDF.

Instances

Liste des instances permettant d'utiliser ce logiciel :

License

Logiciel libre sous license AGPL V3

Installation

Dépendances :

  • php >= 5.6
  • rsvg-convert
  • pdftk
  • imagemagick
  • potrace

Sur debian :

sudo aptitude install php librsvg2-bin pdftk imagemagick potrace

Récupération des sources :

git clone https://github.com/24eme/signaturepdf.git

Pour le lancer :

php -S localhost:8000 -t public

Configuration de PHP

upload_max_filesize = 24M # Taille maximum du fichier PDF à signer
post_max_size = 24M # Taille maximum du fichier PDF à signer
max_file_uploads = 201 # Nombre de pages maximum du PDF, ici 200 pages + le PDF d'origine

Déployer avec apache

DocumentRoot /path/to/signaturepdf/public

<Directory /path/to/signaturepdf/public>
    Require all granted
    FallbackResource /index.php
    php_value max_file_uploads 201
    php_value upload_max_filesize 24M
    php_value post_max_size 24M
</Directory>

Déployer avec docker

Construction de l'image

docker build -t signaturepdf .

Lancement d'un conteneur

docker run -d --name=signaturepdf -p 8080:80 signaturepdf

localhost:8080

Configuration

Les variables suivantes permettent de configurer le déployement :

Variable description exemple defaut
SERVERNAME url de déploiement pdf.24eme.fr localhost
UPLOAD_MAX_FILESIZE Taille maximum du fichier PDF à signer 48M 24M
POST_MAX_SIZE Taille maximum du fichier PDF à signer 48M 24M
MAX_FILE_UPLOADS Nombre de pages maximum du PDF, ici 200 pages + le PDF d'origine 401 201
docker run -d --name=signaturepdf -p 8080:80 -e SERVERNAME=pdf.example.org -e UPLOAD_MAX_FILESIZE=48M -e POST_MAX_SIZE=48M -e MAX_FILE_UPLOADS=401 signaturepdf

Tests

Pour exécuter les tests fonctionnels :

make test

Les tests sont réalisés avec puppeteer et jest.

Pour lancer les tests et voir le navigateur (en mode debug) :

DEBUG=1 make test

Librairies utilisées

Pour les tests :