From ca2dcf73e38e5e5202b600d926737f0591aa65f1 Mon Sep 17 00:00:00 2001 From: Witko Tamm Date: Mon, 11 Sep 2023 13:17:53 +0200 Subject: [PATCH 1/4] Refactored for use with docker and docker-compose --- .gitignore => app/.gitignore | 0 LICENSE => app/LICENSE | 0 README.md => app/README.md | 0 {actions => app/actions}/adminpagehandler.php | 0 {actions => app/actions}/codeprint.php | 0 {actions => app/actions}/csvcodesend.php | 0 .../actions}/electionadminpagehandler.php | 0 {actions => app/actions}/genlastresult.php | 0 {actions => app/actions}/pollRoundStatus.php | 0 .../actions}/useradminpagehandler.php | 0 .../actions}/usersessionhandler.php | 0 .../actions}/votingpagehandler.php | 0 {css => app/css}/bootstrap-theme.css | 0 {css => app/css}/bootstrap-theme.css.map | 0 {css => app/css}/bootstrap-theme.min.css | 0 {css => app/css}/bootstrap.css | 0 {css => app/css}/bootstrap.css.map | 0 {css => app/css}/bootstrap.min.css | 0 {css => app/css}/evote.css | 0 {data => app/data}/Dialogue.php | 0 {data => app/data}/RandomInfo.php | 0 {data => app/data}/code_instr.txt | 0 {data => app/data}/evote.php | 0 ecrypt.php => app/ecrypt.php | 0 evote_ascii.php => app/evote_ascii.php | 0 favicon.ico => app/favicon.ico | Bin .../fonts}/glyphicons-halflings-regular.eot | Bin .../fonts}/glyphicons-halflings-regular.svg | 0 .../fonts}/glyphicons-halflings-regular.ttf | Bin .../fonts}/glyphicons-halflings-regular.woff | Bin .../fonts}/glyphicons-halflings-regular.woff2 | Bin footer.php => app/footer.php | 0 {fpdf => app/fpdf}/FAQ.htm | 0 {fpdf => app/fpdf}/changelog.htm | 0 {fpdf => app/fpdf}/doc/__construct.htm | 0 {fpdf => app/fpdf}/doc/acceptpagebreak.htm | 0 {fpdf => app/fpdf}/doc/addfont.htm | 0 {fpdf => app/fpdf}/doc/addlink.htm | 0 {fpdf => app/fpdf}/doc/addpage.htm | 0 {fpdf => app/fpdf}/doc/aliasnbpages.htm | 0 {fpdf => app/fpdf}/doc/cell.htm | 0 {fpdf => app/fpdf}/doc/close.htm | 0 {fpdf => app/fpdf}/doc/error.htm | 0 {fpdf => app/fpdf}/doc/footer.htm | 0 {fpdf => app/fpdf}/doc/getpageheight.htm | 0 {fpdf => app/fpdf}/doc/getpagewidth.htm | 0 {fpdf => app/fpdf}/doc/getstringwidth.htm | 0 {fpdf => app/fpdf}/doc/getx.htm | 0 {fpdf => app/fpdf}/doc/gety.htm | 0 {fpdf => app/fpdf}/doc/header.htm | 0 {fpdf => app/fpdf}/doc/image.htm | 0 {fpdf => app/fpdf}/doc/index.htm | 0 {fpdf => app/fpdf}/doc/line.htm | 0 {fpdf => app/fpdf}/doc/link.htm | 0 {fpdf => app/fpdf}/doc/ln.htm | 0 {fpdf => app/fpdf}/doc/multicell.htm | 0 {fpdf => app/fpdf}/doc/output.htm | 0 {fpdf => app/fpdf}/doc/pageno.htm | 0 {fpdf => app/fpdf}/doc/rect.htm | 0 {fpdf => app/fpdf}/doc/setauthor.htm | 0 {fpdf => app/fpdf}/doc/setautopagebreak.htm | 0 {fpdf => app/fpdf}/doc/setcompression.htm | 0 {fpdf => app/fpdf}/doc/setcreator.htm | 0 {fpdf => app/fpdf}/doc/setdisplaymode.htm | 0 {fpdf => app/fpdf}/doc/setdrawcolor.htm | 0 {fpdf => app/fpdf}/doc/setfillcolor.htm | 0 {fpdf => app/fpdf}/doc/setfont.htm | 0 {fpdf => app/fpdf}/doc/setfontsize.htm | 0 {fpdf => app/fpdf}/doc/setkeywords.htm | 0 {fpdf => app/fpdf}/doc/setleftmargin.htm | 0 {fpdf => app/fpdf}/doc/setlinewidth.htm | 0 {fpdf => app/fpdf}/doc/setlink.htm | 0 {fpdf => app/fpdf}/doc/setmargins.htm | 0 {fpdf => app/fpdf}/doc/setrightmargin.htm | 0 {fpdf => app/fpdf}/doc/setsubject.htm | 0 {fpdf => app/fpdf}/doc/settextcolor.htm | 0 {fpdf => app/fpdf}/doc/settitle.htm | 0 {fpdf => app/fpdf}/doc/settopmargin.htm | 0 {fpdf => app/fpdf}/doc/setx.htm | 0 {fpdf => app/fpdf}/doc/setxy.htm | 0 {fpdf => app/fpdf}/doc/sety.htm | 0 {fpdf => app/fpdf}/doc/text.htm | 0 {fpdf => app/fpdf}/doc/write.htm | 0 {fpdf => app/fpdf}/font/courier.php | 0 {fpdf => app/fpdf}/font/courierb.php | 0 {fpdf => app/fpdf}/font/courierbi.php | 0 {fpdf => app/fpdf}/font/courieri.php | 0 {fpdf => app/fpdf}/font/helvetica.php | 0 {fpdf => app/fpdf}/font/helveticab.php | 0 {fpdf => app/fpdf}/font/helveticabi.php | 0 {fpdf => app/fpdf}/font/helveticai.php | 0 {fpdf => app/fpdf}/font/symbol.php | 0 {fpdf => app/fpdf}/font/times.php | 0 {fpdf => app/fpdf}/font/timesb.php | 0 {fpdf => app/fpdf}/font/timesbi.php | 0 {fpdf => app/fpdf}/font/timesi.php | 0 {fpdf => app/fpdf}/font/zapfdingbats.php | 0 {fpdf => app/fpdf}/fpdf.css | 0 {fpdf => app/fpdf}/fpdf.php | 0 {fpdf => app/fpdf}/install.txt | 0 {fpdf => app/fpdf}/license.txt | 0 {fpdf => app/fpdf}/makefont/cp1250.map | 0 {fpdf => app/fpdf}/makefont/cp1251.map | 0 {fpdf => app/fpdf}/makefont/cp1252.map | 0 {fpdf => app/fpdf}/makefont/cp1253.map | 0 {fpdf => app/fpdf}/makefont/cp1254.map | 0 {fpdf => app/fpdf}/makefont/cp1255.map | 0 {fpdf => app/fpdf}/makefont/cp1257.map | 0 {fpdf => app/fpdf}/makefont/cp1258.map | 0 {fpdf => app/fpdf}/makefont/cp874.map | 0 {fpdf => app/fpdf}/makefont/iso-8859-1.map | 0 {fpdf => app/fpdf}/makefont/iso-8859-11.map | 0 {fpdf => app/fpdf}/makefont/iso-8859-15.map | 0 {fpdf => app/fpdf}/makefont/iso-8859-16.map | 0 {fpdf => app/fpdf}/makefont/iso-8859-2.map | 0 {fpdf => app/fpdf}/makefont/iso-8859-4.map | 0 {fpdf => app/fpdf}/makefont/iso-8859-5.map | 0 {fpdf => app/fpdf}/makefont/iso-8859-7.map | 0 {fpdf => app/fpdf}/makefont/iso-8859-9.map | 0 {fpdf => app/fpdf}/makefont/koi8-r.map | 0 {fpdf => app/fpdf}/makefont/koi8-u.map | 0 {fpdf => app/fpdf}/makefont/makefont.php | 0 {fpdf => app/fpdf}/makefont/ttfparser.php | 0 {fpdf => app/fpdf}/tutorial/20k_c1.txt | 0 {fpdf => app/fpdf}/tutorial/20k_c2.txt | 0 {fpdf => app/fpdf}/tutorial/calligra.php | 0 {fpdf => app/fpdf}/tutorial/calligra.ttf | Bin {fpdf => app/fpdf}/tutorial/calligra.z | Bin {fpdf => app/fpdf}/tutorial/countries.txt | 0 {fpdf => app/fpdf}/tutorial/index.htm | 0 {fpdf => app/fpdf}/tutorial/logo.png | Bin {fpdf => app/fpdf}/tutorial/makefont.php | 0 {fpdf => app/fpdf}/tutorial/tuto1.htm | 0 {fpdf => app/fpdf}/tutorial/tuto1.php | 0 {fpdf => app/fpdf}/tutorial/tuto2.htm | 0 {fpdf => app/fpdf}/tutorial/tuto2.php | 0 {fpdf => app/fpdf}/tutorial/tuto3.htm | 0 {fpdf => app/fpdf}/tutorial/tuto3.php | 0 {fpdf => app/fpdf}/tutorial/tuto4.htm | 0 {fpdf => app/fpdf}/tutorial/tuto4.php | 0 {fpdf => app/fpdf}/tutorial/tuto5.htm | 0 {fpdf => app/fpdf}/tutorial/tuto5.php | 0 {fpdf => app/fpdf}/tutorial/tuto6.htm | 0 {fpdf => app/fpdf}/tutorial/tuto6.php | 0 {fpdf => app/fpdf}/tutorial/tuto7.htm | 0 {fpdf => app/fpdf}/tutorial/tuto7.php | 0 index.php => app/index.php | 0 {index => app/index}/adjust/adjustpanel.php | 0 {index => app/index}/adjust/stat.php | 0 .../index}/admin/electionControl.php | 0 {index => app/index}/admin/electionsinfo.php | 0 .../index}/classes/MenuGenerator.php | 0 .../index}/classes/TableGenerator.php | 0 {index => app/index}/clear.php | 0 .../electionadmin/electionadminpanel.php | 0 {index => app/index}/session/login.php | 0 {index => app/index}/session/logout.php | 0 .../index}/useradmin/changepassword.php | 0 {index => app/index}/useradmin/newuser.php | 0 .../index}/useradmin/useradminpanel.php | 0 {index => app/index}/vote/front.php | 0 {install => app/install}/evote.sql | 0 {install => app/install}/setup.php | 0 {js => app/js}/bootstrap.js | 0 {js => app/js}/bootstrap.min.js | 0 {js => app/js}/checkForNewRound.js | 0 {js => app/js}/checkIfRoundClosed.js | 0 {js => app/js}/countdown.js | 0 {js => app/js}/npm.js | 0 .../localization}/getLocalizedText.php | 0 .../localizedTextLookupTable.php | 0 logo.jpg => app/logo.jpg | Bin docker-compose.yml | 33 ++++++++++++++++++ dockerfiles/MYSQL.dockerfile | 3 ++ dockerfiles/NGINX.dockerfile | 6 ++++ dockerfiles/PHP.dockerfile | 3 ++ nginxconf/fastcgi_params | 25 +++++++++++++ nginxconf/nginx.conf | 23 ++++++++++++ nginxconf/php.conf | 4 +++ 179 files changed, 97 insertions(+) rename .gitignore => app/.gitignore (100%) rename LICENSE => app/LICENSE (100%) rename README.md => app/README.md (100%) rename {actions => app/actions}/adminpagehandler.php (100%) rename {actions => app/actions}/codeprint.php (100%) rename {actions => app/actions}/csvcodesend.php (100%) rename {actions => app/actions}/electionadminpagehandler.php (100%) rename {actions => app/actions}/genlastresult.php (100%) rename {actions => app/actions}/pollRoundStatus.php (100%) rename {actions => app/actions}/useradminpagehandler.php (100%) rename {actions => app/actions}/usersessionhandler.php (100%) rename {actions => app/actions}/votingpagehandler.php (100%) rename {css => app/css}/bootstrap-theme.css (100%) rename {css => app/css}/bootstrap-theme.css.map (100%) rename {css => app/css}/bootstrap-theme.min.css (100%) rename {css => app/css}/bootstrap.css (100%) rename {css => app/css}/bootstrap.css.map (100%) rename {css => app/css}/bootstrap.min.css (100%) rename {css => app/css}/evote.css (100%) rename {data => app/data}/Dialogue.php (100%) rename {data => app/data}/RandomInfo.php (100%) rename {data => app/data}/code_instr.txt (100%) rename {data => app/data}/evote.php (100%) rename ecrypt.php => app/ecrypt.php (100%) rename evote_ascii.php => app/evote_ascii.php (100%) rename favicon.ico => app/favicon.ico (100%) rename {fonts => app/fonts}/glyphicons-halflings-regular.eot (100%) rename {fonts => app/fonts}/glyphicons-halflings-regular.svg (100%) rename {fonts => app/fonts}/glyphicons-halflings-regular.ttf (100%) rename {fonts => app/fonts}/glyphicons-halflings-regular.woff (100%) rename {fonts => app/fonts}/glyphicons-halflings-regular.woff2 (100%) rename footer.php => app/footer.php (100%) rename {fpdf => app/fpdf}/FAQ.htm (100%) rename {fpdf => app/fpdf}/changelog.htm (100%) rename {fpdf => app/fpdf}/doc/__construct.htm (100%) rename {fpdf => app/fpdf}/doc/acceptpagebreak.htm (100%) rename {fpdf => app/fpdf}/doc/addfont.htm (100%) rename {fpdf => app/fpdf}/doc/addlink.htm (100%) rename {fpdf => app/fpdf}/doc/addpage.htm (100%) rename {fpdf => app/fpdf}/doc/aliasnbpages.htm (100%) rename {fpdf => app/fpdf}/doc/cell.htm (100%) rename {fpdf => app/fpdf}/doc/close.htm (100%) rename {fpdf => app/fpdf}/doc/error.htm (100%) rename {fpdf => app/fpdf}/doc/footer.htm (100%) rename {fpdf => app/fpdf}/doc/getpageheight.htm (100%) rename {fpdf => app/fpdf}/doc/getpagewidth.htm (100%) rename {fpdf => app/fpdf}/doc/getstringwidth.htm (100%) rename {fpdf => app/fpdf}/doc/getx.htm (100%) rename {fpdf => app/fpdf}/doc/gety.htm (100%) rename {fpdf => app/fpdf}/doc/header.htm (100%) rename {fpdf => app/fpdf}/doc/image.htm (100%) rename {fpdf => app/fpdf}/doc/index.htm (100%) rename {fpdf => app/fpdf}/doc/line.htm (100%) rename {fpdf => app/fpdf}/doc/link.htm (100%) rename {fpdf => app/fpdf}/doc/ln.htm (100%) rename {fpdf => app/fpdf}/doc/multicell.htm (100%) rename {fpdf => app/fpdf}/doc/output.htm (100%) rename {fpdf => app/fpdf}/doc/pageno.htm (100%) rename {fpdf => app/fpdf}/doc/rect.htm (100%) rename {fpdf => app/fpdf}/doc/setauthor.htm (100%) rename {fpdf => app/fpdf}/doc/setautopagebreak.htm (100%) rename {fpdf => app/fpdf}/doc/setcompression.htm (100%) rename {fpdf => app/fpdf}/doc/setcreator.htm (100%) rename {fpdf => app/fpdf}/doc/setdisplaymode.htm (100%) rename {fpdf => app/fpdf}/doc/setdrawcolor.htm (100%) rename {fpdf => app/fpdf}/doc/setfillcolor.htm (100%) rename {fpdf => app/fpdf}/doc/setfont.htm (100%) rename {fpdf => app/fpdf}/doc/setfontsize.htm (100%) rename {fpdf => app/fpdf}/doc/setkeywords.htm (100%) rename {fpdf => app/fpdf}/doc/setleftmargin.htm (100%) rename {fpdf => app/fpdf}/doc/setlinewidth.htm (100%) rename {fpdf => app/fpdf}/doc/setlink.htm (100%) rename {fpdf => app/fpdf}/doc/setmargins.htm (100%) rename {fpdf => app/fpdf}/doc/setrightmargin.htm (100%) rename {fpdf => app/fpdf}/doc/setsubject.htm (100%) rename {fpdf => app/fpdf}/doc/settextcolor.htm (100%) rename {fpdf => app/fpdf}/doc/settitle.htm (100%) rename {fpdf => app/fpdf}/doc/settopmargin.htm (100%) rename {fpdf => app/fpdf}/doc/setx.htm (100%) rename {fpdf => app/fpdf}/doc/setxy.htm (100%) rename {fpdf => app/fpdf}/doc/sety.htm (100%) rename {fpdf => app/fpdf}/doc/text.htm (100%) rename {fpdf => app/fpdf}/doc/write.htm (100%) rename {fpdf => app/fpdf}/font/courier.php (100%) rename {fpdf => app/fpdf}/font/courierb.php (100%) rename {fpdf => app/fpdf}/font/courierbi.php (100%) rename {fpdf => app/fpdf}/font/courieri.php (100%) rename {fpdf => app/fpdf}/font/helvetica.php (100%) rename {fpdf => app/fpdf}/font/helveticab.php (100%) rename {fpdf => app/fpdf}/font/helveticabi.php (100%) rename {fpdf => app/fpdf}/font/helveticai.php (100%) rename {fpdf => app/fpdf}/font/symbol.php (100%) rename {fpdf => app/fpdf}/font/times.php (100%) rename {fpdf => app/fpdf}/font/timesb.php (100%) rename {fpdf => app/fpdf}/font/timesbi.php (100%) rename {fpdf => app/fpdf}/font/timesi.php (100%) rename {fpdf => app/fpdf}/font/zapfdingbats.php (100%) rename {fpdf => app/fpdf}/fpdf.css (100%) rename {fpdf => app/fpdf}/fpdf.php (100%) rename {fpdf => app/fpdf}/install.txt (100%) rename {fpdf => app/fpdf}/license.txt (100%) rename {fpdf => app/fpdf}/makefont/cp1250.map (100%) rename {fpdf => app/fpdf}/makefont/cp1251.map (100%) rename {fpdf => app/fpdf}/makefont/cp1252.map (100%) rename {fpdf => app/fpdf}/makefont/cp1253.map (100%) rename {fpdf => app/fpdf}/makefont/cp1254.map (100%) rename {fpdf => app/fpdf}/makefont/cp1255.map (100%) rename {fpdf => app/fpdf}/makefont/cp1257.map (100%) rename {fpdf => app/fpdf}/makefont/cp1258.map (100%) rename {fpdf => app/fpdf}/makefont/cp874.map (100%) rename {fpdf => app/fpdf}/makefont/iso-8859-1.map (100%) rename {fpdf => app/fpdf}/makefont/iso-8859-11.map (100%) rename {fpdf => app/fpdf}/makefont/iso-8859-15.map (100%) rename {fpdf => app/fpdf}/makefont/iso-8859-16.map (100%) rename {fpdf => app/fpdf}/makefont/iso-8859-2.map (100%) rename {fpdf => app/fpdf}/makefont/iso-8859-4.map (100%) rename {fpdf => app/fpdf}/makefont/iso-8859-5.map (100%) rename {fpdf => app/fpdf}/makefont/iso-8859-7.map (100%) rename {fpdf => app/fpdf}/makefont/iso-8859-9.map (100%) rename {fpdf => app/fpdf}/makefont/koi8-r.map (100%) rename {fpdf => app/fpdf}/makefont/koi8-u.map (100%) rename {fpdf => app/fpdf}/makefont/makefont.php (100%) rename {fpdf => app/fpdf}/makefont/ttfparser.php (100%) rename {fpdf => app/fpdf}/tutorial/20k_c1.txt (100%) rename {fpdf => app/fpdf}/tutorial/20k_c2.txt (100%) rename {fpdf => app/fpdf}/tutorial/calligra.php (100%) rename {fpdf => app/fpdf}/tutorial/calligra.ttf (100%) rename {fpdf => app/fpdf}/tutorial/calligra.z (100%) rename {fpdf => app/fpdf}/tutorial/countries.txt (100%) rename {fpdf => app/fpdf}/tutorial/index.htm (100%) rename {fpdf => app/fpdf}/tutorial/logo.png (100%) rename {fpdf => app/fpdf}/tutorial/makefont.php (100%) rename {fpdf => app/fpdf}/tutorial/tuto1.htm (100%) rename {fpdf => app/fpdf}/tutorial/tuto1.php (100%) rename {fpdf => app/fpdf}/tutorial/tuto2.htm (100%) rename {fpdf => app/fpdf}/tutorial/tuto2.php (100%) rename {fpdf => app/fpdf}/tutorial/tuto3.htm (100%) rename {fpdf => app/fpdf}/tutorial/tuto3.php (100%) rename {fpdf => app/fpdf}/tutorial/tuto4.htm (100%) rename {fpdf => app/fpdf}/tutorial/tuto4.php (100%) rename {fpdf => app/fpdf}/tutorial/tuto5.htm (100%) rename {fpdf => app/fpdf}/tutorial/tuto5.php (100%) rename {fpdf => app/fpdf}/tutorial/tuto6.htm (100%) rename {fpdf => app/fpdf}/tutorial/tuto6.php (100%) rename {fpdf => app/fpdf}/tutorial/tuto7.htm (100%) rename {fpdf => app/fpdf}/tutorial/tuto7.php (100%) rename index.php => app/index.php (100%) rename {index => app/index}/adjust/adjustpanel.php (100%) rename {index => app/index}/adjust/stat.php (100%) rename {index => app/index}/admin/electionControl.php (100%) rename {index => app/index}/admin/electionsinfo.php (100%) rename {index => app/index}/classes/MenuGenerator.php (100%) rename {index => app/index}/classes/TableGenerator.php (100%) rename {index => app/index}/clear.php (100%) rename {index => app/index}/electionadmin/electionadminpanel.php (100%) rename {index => app/index}/session/login.php (100%) rename {index => app/index}/session/logout.php (100%) rename {index => app/index}/useradmin/changepassword.php (100%) rename {index => app/index}/useradmin/newuser.php (100%) rename {index => app/index}/useradmin/useradminpanel.php (100%) rename {index => app/index}/vote/front.php (100%) rename {install => app/install}/evote.sql (100%) rename {install => app/install}/setup.php (100%) rename {js => app/js}/bootstrap.js (100%) rename {js => app/js}/bootstrap.min.js (100%) rename {js => app/js}/checkForNewRound.js (100%) rename {js => app/js}/checkIfRoundClosed.js (100%) rename {js => app/js}/countdown.js (100%) rename {js => app/js}/npm.js (100%) rename {localization => app/localization}/getLocalizedText.php (100%) rename {localization => app/localization}/localizedTextLookupTable.php (100%) rename logo.jpg => app/logo.jpg (100%) create mode 100644 docker-compose.yml create mode 100644 dockerfiles/MYSQL.dockerfile create mode 100644 dockerfiles/NGINX.dockerfile create mode 100644 dockerfiles/PHP.dockerfile create mode 100644 nginxconf/fastcgi_params create mode 100644 nginxconf/nginx.conf create mode 100644 nginxconf/php.conf diff --git a/.gitignore b/app/.gitignore similarity index 100% rename from .gitignore rename to app/.gitignore diff --git a/LICENSE b/app/LICENSE similarity index 100% rename from LICENSE rename to app/LICENSE diff --git a/README.md b/app/README.md similarity index 100% rename from README.md rename to app/README.md diff --git a/actions/adminpagehandler.php b/app/actions/adminpagehandler.php similarity index 100% rename from actions/adminpagehandler.php rename to app/actions/adminpagehandler.php diff --git a/actions/codeprint.php b/app/actions/codeprint.php similarity index 100% rename from actions/codeprint.php rename to app/actions/codeprint.php diff --git a/actions/csvcodesend.php b/app/actions/csvcodesend.php similarity index 100% rename from actions/csvcodesend.php rename to app/actions/csvcodesend.php diff --git a/actions/electionadminpagehandler.php b/app/actions/electionadminpagehandler.php similarity index 100% rename from actions/electionadminpagehandler.php rename to app/actions/electionadminpagehandler.php diff --git a/actions/genlastresult.php b/app/actions/genlastresult.php similarity index 100% rename from actions/genlastresult.php rename to app/actions/genlastresult.php diff --git a/actions/pollRoundStatus.php b/app/actions/pollRoundStatus.php similarity index 100% rename from actions/pollRoundStatus.php rename to app/actions/pollRoundStatus.php diff --git a/actions/useradminpagehandler.php b/app/actions/useradminpagehandler.php similarity index 100% rename from actions/useradminpagehandler.php rename to app/actions/useradminpagehandler.php diff --git a/actions/usersessionhandler.php b/app/actions/usersessionhandler.php similarity index 100% rename from actions/usersessionhandler.php rename to app/actions/usersessionhandler.php diff --git a/actions/votingpagehandler.php b/app/actions/votingpagehandler.php similarity index 100% rename from actions/votingpagehandler.php rename to app/actions/votingpagehandler.php diff --git a/css/bootstrap-theme.css b/app/css/bootstrap-theme.css similarity index 100% rename from css/bootstrap-theme.css rename to app/css/bootstrap-theme.css diff --git a/css/bootstrap-theme.css.map b/app/css/bootstrap-theme.css.map similarity index 100% rename from css/bootstrap-theme.css.map rename to app/css/bootstrap-theme.css.map diff --git a/css/bootstrap-theme.min.css b/app/css/bootstrap-theme.min.css similarity index 100% rename from css/bootstrap-theme.min.css rename to app/css/bootstrap-theme.min.css diff --git a/css/bootstrap.css b/app/css/bootstrap.css similarity index 100% rename from css/bootstrap.css rename to app/css/bootstrap.css diff --git a/css/bootstrap.css.map b/app/css/bootstrap.css.map similarity index 100% rename from css/bootstrap.css.map rename to app/css/bootstrap.css.map diff --git a/css/bootstrap.min.css b/app/css/bootstrap.min.css similarity index 100% rename from css/bootstrap.min.css rename to app/css/bootstrap.min.css diff --git a/css/evote.css b/app/css/evote.css similarity index 100% rename from css/evote.css rename to app/css/evote.css diff --git a/data/Dialogue.php b/app/data/Dialogue.php similarity index 100% rename from data/Dialogue.php rename to app/data/Dialogue.php diff --git a/data/RandomInfo.php b/app/data/RandomInfo.php similarity index 100% rename from data/RandomInfo.php rename to app/data/RandomInfo.php diff --git a/data/code_instr.txt b/app/data/code_instr.txt similarity index 100% rename from data/code_instr.txt rename to app/data/code_instr.txt diff --git a/data/evote.php b/app/data/evote.php similarity index 100% rename from data/evote.php rename to app/data/evote.php diff --git a/ecrypt.php b/app/ecrypt.php similarity index 100% rename from ecrypt.php rename to app/ecrypt.php diff --git a/evote_ascii.php b/app/evote_ascii.php similarity index 100% rename from evote_ascii.php rename to app/evote_ascii.php diff --git a/favicon.ico b/app/favicon.ico similarity index 100% rename from favicon.ico rename to app/favicon.ico diff --git a/fonts/glyphicons-halflings-regular.eot b/app/fonts/glyphicons-halflings-regular.eot similarity index 100% rename from fonts/glyphicons-halflings-regular.eot rename to app/fonts/glyphicons-halflings-regular.eot diff --git a/fonts/glyphicons-halflings-regular.svg b/app/fonts/glyphicons-halflings-regular.svg similarity index 100% rename from fonts/glyphicons-halflings-regular.svg rename to app/fonts/glyphicons-halflings-regular.svg diff --git a/fonts/glyphicons-halflings-regular.ttf b/app/fonts/glyphicons-halflings-regular.ttf similarity index 100% rename from fonts/glyphicons-halflings-regular.ttf rename to app/fonts/glyphicons-halflings-regular.ttf diff --git a/fonts/glyphicons-halflings-regular.woff b/app/fonts/glyphicons-halflings-regular.woff similarity index 100% rename from fonts/glyphicons-halflings-regular.woff rename to app/fonts/glyphicons-halflings-regular.woff diff --git a/fonts/glyphicons-halflings-regular.woff2 b/app/fonts/glyphicons-halflings-regular.woff2 similarity index 100% rename from fonts/glyphicons-halflings-regular.woff2 rename to app/fonts/glyphicons-halflings-regular.woff2 diff --git a/footer.php b/app/footer.php similarity index 100% rename from footer.php rename to app/footer.php diff --git a/fpdf/FAQ.htm b/app/fpdf/FAQ.htm similarity index 100% rename from fpdf/FAQ.htm rename to app/fpdf/FAQ.htm diff --git a/fpdf/changelog.htm b/app/fpdf/changelog.htm similarity index 100% rename from fpdf/changelog.htm rename to app/fpdf/changelog.htm diff --git a/fpdf/doc/__construct.htm b/app/fpdf/doc/__construct.htm similarity index 100% rename from fpdf/doc/__construct.htm rename to app/fpdf/doc/__construct.htm diff --git a/fpdf/doc/acceptpagebreak.htm b/app/fpdf/doc/acceptpagebreak.htm similarity index 100% rename from fpdf/doc/acceptpagebreak.htm rename to app/fpdf/doc/acceptpagebreak.htm diff --git a/fpdf/doc/addfont.htm b/app/fpdf/doc/addfont.htm similarity index 100% rename from fpdf/doc/addfont.htm rename to app/fpdf/doc/addfont.htm diff --git a/fpdf/doc/addlink.htm b/app/fpdf/doc/addlink.htm similarity index 100% rename from fpdf/doc/addlink.htm rename to app/fpdf/doc/addlink.htm diff --git a/fpdf/doc/addpage.htm b/app/fpdf/doc/addpage.htm similarity index 100% rename from fpdf/doc/addpage.htm rename to app/fpdf/doc/addpage.htm diff --git a/fpdf/doc/aliasnbpages.htm b/app/fpdf/doc/aliasnbpages.htm similarity index 100% rename from fpdf/doc/aliasnbpages.htm rename to app/fpdf/doc/aliasnbpages.htm diff --git a/fpdf/doc/cell.htm b/app/fpdf/doc/cell.htm similarity index 100% rename from fpdf/doc/cell.htm rename to app/fpdf/doc/cell.htm diff --git a/fpdf/doc/close.htm b/app/fpdf/doc/close.htm similarity index 100% rename from fpdf/doc/close.htm rename to app/fpdf/doc/close.htm diff --git a/fpdf/doc/error.htm b/app/fpdf/doc/error.htm similarity index 100% rename from fpdf/doc/error.htm rename to app/fpdf/doc/error.htm diff --git a/fpdf/doc/footer.htm b/app/fpdf/doc/footer.htm similarity index 100% rename from fpdf/doc/footer.htm rename to app/fpdf/doc/footer.htm diff --git a/fpdf/doc/getpageheight.htm b/app/fpdf/doc/getpageheight.htm similarity index 100% rename from fpdf/doc/getpageheight.htm rename to app/fpdf/doc/getpageheight.htm diff --git a/fpdf/doc/getpagewidth.htm b/app/fpdf/doc/getpagewidth.htm similarity index 100% rename from fpdf/doc/getpagewidth.htm rename to app/fpdf/doc/getpagewidth.htm diff --git a/fpdf/doc/getstringwidth.htm b/app/fpdf/doc/getstringwidth.htm similarity index 100% rename from fpdf/doc/getstringwidth.htm rename to app/fpdf/doc/getstringwidth.htm diff --git a/fpdf/doc/getx.htm b/app/fpdf/doc/getx.htm similarity index 100% rename from fpdf/doc/getx.htm rename to app/fpdf/doc/getx.htm diff --git a/fpdf/doc/gety.htm b/app/fpdf/doc/gety.htm similarity index 100% rename from fpdf/doc/gety.htm rename to app/fpdf/doc/gety.htm diff --git a/fpdf/doc/header.htm b/app/fpdf/doc/header.htm similarity index 100% rename from fpdf/doc/header.htm rename to app/fpdf/doc/header.htm diff --git a/fpdf/doc/image.htm b/app/fpdf/doc/image.htm similarity index 100% rename from fpdf/doc/image.htm rename to app/fpdf/doc/image.htm diff --git a/fpdf/doc/index.htm b/app/fpdf/doc/index.htm similarity index 100% rename from fpdf/doc/index.htm rename to app/fpdf/doc/index.htm diff --git a/fpdf/doc/line.htm b/app/fpdf/doc/line.htm similarity index 100% rename from fpdf/doc/line.htm rename to app/fpdf/doc/line.htm diff --git a/fpdf/doc/link.htm b/app/fpdf/doc/link.htm similarity index 100% rename from fpdf/doc/link.htm rename to app/fpdf/doc/link.htm diff --git a/fpdf/doc/ln.htm b/app/fpdf/doc/ln.htm similarity index 100% rename from fpdf/doc/ln.htm rename to app/fpdf/doc/ln.htm diff --git a/fpdf/doc/multicell.htm b/app/fpdf/doc/multicell.htm similarity index 100% rename from fpdf/doc/multicell.htm rename to app/fpdf/doc/multicell.htm diff --git a/fpdf/doc/output.htm b/app/fpdf/doc/output.htm similarity index 100% rename from fpdf/doc/output.htm rename to app/fpdf/doc/output.htm diff --git a/fpdf/doc/pageno.htm b/app/fpdf/doc/pageno.htm similarity index 100% rename from fpdf/doc/pageno.htm rename to app/fpdf/doc/pageno.htm diff --git a/fpdf/doc/rect.htm b/app/fpdf/doc/rect.htm similarity index 100% rename from fpdf/doc/rect.htm rename to app/fpdf/doc/rect.htm diff --git a/fpdf/doc/setauthor.htm b/app/fpdf/doc/setauthor.htm similarity index 100% rename from fpdf/doc/setauthor.htm rename to app/fpdf/doc/setauthor.htm diff --git a/fpdf/doc/setautopagebreak.htm b/app/fpdf/doc/setautopagebreak.htm similarity index 100% rename from fpdf/doc/setautopagebreak.htm rename to app/fpdf/doc/setautopagebreak.htm diff --git a/fpdf/doc/setcompression.htm b/app/fpdf/doc/setcompression.htm similarity index 100% rename from fpdf/doc/setcompression.htm rename to app/fpdf/doc/setcompression.htm diff --git a/fpdf/doc/setcreator.htm b/app/fpdf/doc/setcreator.htm similarity index 100% rename from fpdf/doc/setcreator.htm rename to app/fpdf/doc/setcreator.htm diff --git a/fpdf/doc/setdisplaymode.htm b/app/fpdf/doc/setdisplaymode.htm similarity index 100% rename from fpdf/doc/setdisplaymode.htm rename to app/fpdf/doc/setdisplaymode.htm diff --git a/fpdf/doc/setdrawcolor.htm b/app/fpdf/doc/setdrawcolor.htm similarity index 100% rename from fpdf/doc/setdrawcolor.htm rename to app/fpdf/doc/setdrawcolor.htm diff --git a/fpdf/doc/setfillcolor.htm b/app/fpdf/doc/setfillcolor.htm similarity index 100% rename from fpdf/doc/setfillcolor.htm rename to app/fpdf/doc/setfillcolor.htm diff --git a/fpdf/doc/setfont.htm b/app/fpdf/doc/setfont.htm similarity index 100% rename from fpdf/doc/setfont.htm rename to app/fpdf/doc/setfont.htm diff --git a/fpdf/doc/setfontsize.htm b/app/fpdf/doc/setfontsize.htm similarity index 100% rename from fpdf/doc/setfontsize.htm rename to app/fpdf/doc/setfontsize.htm diff --git a/fpdf/doc/setkeywords.htm b/app/fpdf/doc/setkeywords.htm similarity index 100% rename from fpdf/doc/setkeywords.htm rename to app/fpdf/doc/setkeywords.htm diff --git a/fpdf/doc/setleftmargin.htm b/app/fpdf/doc/setleftmargin.htm similarity index 100% rename from fpdf/doc/setleftmargin.htm rename to app/fpdf/doc/setleftmargin.htm diff --git a/fpdf/doc/setlinewidth.htm b/app/fpdf/doc/setlinewidth.htm similarity index 100% rename from fpdf/doc/setlinewidth.htm rename to app/fpdf/doc/setlinewidth.htm diff --git a/fpdf/doc/setlink.htm b/app/fpdf/doc/setlink.htm similarity index 100% rename from fpdf/doc/setlink.htm rename to app/fpdf/doc/setlink.htm diff --git a/fpdf/doc/setmargins.htm b/app/fpdf/doc/setmargins.htm similarity index 100% rename from fpdf/doc/setmargins.htm rename to app/fpdf/doc/setmargins.htm diff --git a/fpdf/doc/setrightmargin.htm b/app/fpdf/doc/setrightmargin.htm similarity index 100% rename from fpdf/doc/setrightmargin.htm rename to app/fpdf/doc/setrightmargin.htm diff --git a/fpdf/doc/setsubject.htm b/app/fpdf/doc/setsubject.htm similarity index 100% rename from fpdf/doc/setsubject.htm rename to app/fpdf/doc/setsubject.htm diff --git a/fpdf/doc/settextcolor.htm b/app/fpdf/doc/settextcolor.htm similarity index 100% rename from fpdf/doc/settextcolor.htm rename to app/fpdf/doc/settextcolor.htm diff --git a/fpdf/doc/settitle.htm b/app/fpdf/doc/settitle.htm similarity index 100% rename from fpdf/doc/settitle.htm rename to app/fpdf/doc/settitle.htm diff --git a/fpdf/doc/settopmargin.htm b/app/fpdf/doc/settopmargin.htm similarity index 100% rename from fpdf/doc/settopmargin.htm rename to app/fpdf/doc/settopmargin.htm diff --git a/fpdf/doc/setx.htm b/app/fpdf/doc/setx.htm similarity index 100% rename from fpdf/doc/setx.htm rename to app/fpdf/doc/setx.htm diff --git a/fpdf/doc/setxy.htm b/app/fpdf/doc/setxy.htm similarity index 100% rename from fpdf/doc/setxy.htm rename to app/fpdf/doc/setxy.htm diff --git a/fpdf/doc/sety.htm b/app/fpdf/doc/sety.htm similarity index 100% rename from fpdf/doc/sety.htm rename to app/fpdf/doc/sety.htm diff --git a/fpdf/doc/text.htm b/app/fpdf/doc/text.htm similarity index 100% rename from fpdf/doc/text.htm rename to app/fpdf/doc/text.htm diff --git a/fpdf/doc/write.htm b/app/fpdf/doc/write.htm similarity index 100% rename from fpdf/doc/write.htm rename to app/fpdf/doc/write.htm diff --git a/fpdf/font/courier.php b/app/fpdf/font/courier.php similarity index 100% rename from fpdf/font/courier.php rename to app/fpdf/font/courier.php diff --git a/fpdf/font/courierb.php b/app/fpdf/font/courierb.php similarity index 100% rename from fpdf/font/courierb.php rename to app/fpdf/font/courierb.php diff --git a/fpdf/font/courierbi.php b/app/fpdf/font/courierbi.php similarity index 100% rename from fpdf/font/courierbi.php rename to app/fpdf/font/courierbi.php diff --git a/fpdf/font/courieri.php b/app/fpdf/font/courieri.php similarity index 100% rename from fpdf/font/courieri.php rename to app/fpdf/font/courieri.php diff --git a/fpdf/font/helvetica.php b/app/fpdf/font/helvetica.php similarity index 100% rename from fpdf/font/helvetica.php rename to app/fpdf/font/helvetica.php diff --git a/fpdf/font/helveticab.php b/app/fpdf/font/helveticab.php similarity index 100% rename from fpdf/font/helveticab.php rename to app/fpdf/font/helveticab.php diff --git a/fpdf/font/helveticabi.php b/app/fpdf/font/helveticabi.php similarity index 100% rename from fpdf/font/helveticabi.php rename to app/fpdf/font/helveticabi.php diff --git a/fpdf/font/helveticai.php b/app/fpdf/font/helveticai.php similarity index 100% rename from fpdf/font/helveticai.php rename to app/fpdf/font/helveticai.php diff --git a/fpdf/font/symbol.php b/app/fpdf/font/symbol.php similarity index 100% rename from fpdf/font/symbol.php rename to app/fpdf/font/symbol.php diff --git a/fpdf/font/times.php b/app/fpdf/font/times.php similarity index 100% rename from fpdf/font/times.php rename to app/fpdf/font/times.php diff --git a/fpdf/font/timesb.php b/app/fpdf/font/timesb.php similarity index 100% rename from fpdf/font/timesb.php rename to app/fpdf/font/timesb.php diff --git a/fpdf/font/timesbi.php b/app/fpdf/font/timesbi.php similarity index 100% rename from fpdf/font/timesbi.php rename to app/fpdf/font/timesbi.php diff --git a/fpdf/font/timesi.php b/app/fpdf/font/timesi.php similarity index 100% rename from fpdf/font/timesi.php rename to app/fpdf/font/timesi.php diff --git a/fpdf/font/zapfdingbats.php b/app/fpdf/font/zapfdingbats.php similarity index 100% rename from fpdf/font/zapfdingbats.php rename to app/fpdf/font/zapfdingbats.php diff --git a/fpdf/fpdf.css b/app/fpdf/fpdf.css similarity index 100% rename from fpdf/fpdf.css rename to app/fpdf/fpdf.css diff --git a/fpdf/fpdf.php b/app/fpdf/fpdf.php similarity index 100% rename from fpdf/fpdf.php rename to app/fpdf/fpdf.php diff --git a/fpdf/install.txt b/app/fpdf/install.txt similarity index 100% rename from fpdf/install.txt rename to app/fpdf/install.txt diff --git a/fpdf/license.txt b/app/fpdf/license.txt similarity index 100% rename from fpdf/license.txt rename to app/fpdf/license.txt diff --git a/fpdf/makefont/cp1250.map b/app/fpdf/makefont/cp1250.map similarity index 100% rename from fpdf/makefont/cp1250.map rename to app/fpdf/makefont/cp1250.map diff --git a/fpdf/makefont/cp1251.map b/app/fpdf/makefont/cp1251.map similarity index 100% rename from fpdf/makefont/cp1251.map rename to app/fpdf/makefont/cp1251.map diff --git a/fpdf/makefont/cp1252.map b/app/fpdf/makefont/cp1252.map similarity index 100% rename from fpdf/makefont/cp1252.map rename to app/fpdf/makefont/cp1252.map diff --git a/fpdf/makefont/cp1253.map b/app/fpdf/makefont/cp1253.map similarity index 100% rename from fpdf/makefont/cp1253.map rename to app/fpdf/makefont/cp1253.map diff --git a/fpdf/makefont/cp1254.map b/app/fpdf/makefont/cp1254.map similarity index 100% rename from fpdf/makefont/cp1254.map rename to app/fpdf/makefont/cp1254.map diff --git a/fpdf/makefont/cp1255.map b/app/fpdf/makefont/cp1255.map similarity index 100% rename from fpdf/makefont/cp1255.map rename to app/fpdf/makefont/cp1255.map diff --git a/fpdf/makefont/cp1257.map b/app/fpdf/makefont/cp1257.map similarity index 100% rename from fpdf/makefont/cp1257.map rename to app/fpdf/makefont/cp1257.map diff --git a/fpdf/makefont/cp1258.map b/app/fpdf/makefont/cp1258.map similarity index 100% rename from fpdf/makefont/cp1258.map rename to app/fpdf/makefont/cp1258.map diff --git a/fpdf/makefont/cp874.map b/app/fpdf/makefont/cp874.map similarity index 100% rename from fpdf/makefont/cp874.map rename to app/fpdf/makefont/cp874.map diff --git a/fpdf/makefont/iso-8859-1.map b/app/fpdf/makefont/iso-8859-1.map similarity index 100% rename from fpdf/makefont/iso-8859-1.map rename to app/fpdf/makefont/iso-8859-1.map diff --git a/fpdf/makefont/iso-8859-11.map b/app/fpdf/makefont/iso-8859-11.map similarity index 100% rename from fpdf/makefont/iso-8859-11.map rename to app/fpdf/makefont/iso-8859-11.map diff --git a/fpdf/makefont/iso-8859-15.map b/app/fpdf/makefont/iso-8859-15.map similarity index 100% rename from fpdf/makefont/iso-8859-15.map rename to app/fpdf/makefont/iso-8859-15.map diff --git a/fpdf/makefont/iso-8859-16.map b/app/fpdf/makefont/iso-8859-16.map similarity index 100% rename from fpdf/makefont/iso-8859-16.map rename to app/fpdf/makefont/iso-8859-16.map diff --git a/fpdf/makefont/iso-8859-2.map b/app/fpdf/makefont/iso-8859-2.map similarity index 100% rename from fpdf/makefont/iso-8859-2.map rename to app/fpdf/makefont/iso-8859-2.map diff --git a/fpdf/makefont/iso-8859-4.map b/app/fpdf/makefont/iso-8859-4.map similarity index 100% rename from fpdf/makefont/iso-8859-4.map rename to app/fpdf/makefont/iso-8859-4.map diff --git a/fpdf/makefont/iso-8859-5.map b/app/fpdf/makefont/iso-8859-5.map similarity index 100% rename from fpdf/makefont/iso-8859-5.map rename to app/fpdf/makefont/iso-8859-5.map diff --git a/fpdf/makefont/iso-8859-7.map b/app/fpdf/makefont/iso-8859-7.map similarity index 100% rename from fpdf/makefont/iso-8859-7.map rename to app/fpdf/makefont/iso-8859-7.map diff --git a/fpdf/makefont/iso-8859-9.map b/app/fpdf/makefont/iso-8859-9.map similarity index 100% rename from fpdf/makefont/iso-8859-9.map rename to app/fpdf/makefont/iso-8859-9.map diff --git a/fpdf/makefont/koi8-r.map b/app/fpdf/makefont/koi8-r.map similarity index 100% rename from fpdf/makefont/koi8-r.map rename to app/fpdf/makefont/koi8-r.map diff --git a/fpdf/makefont/koi8-u.map b/app/fpdf/makefont/koi8-u.map similarity index 100% rename from fpdf/makefont/koi8-u.map rename to app/fpdf/makefont/koi8-u.map diff --git a/fpdf/makefont/makefont.php b/app/fpdf/makefont/makefont.php similarity index 100% rename from fpdf/makefont/makefont.php rename to app/fpdf/makefont/makefont.php diff --git a/fpdf/makefont/ttfparser.php b/app/fpdf/makefont/ttfparser.php similarity index 100% rename from fpdf/makefont/ttfparser.php rename to app/fpdf/makefont/ttfparser.php diff --git a/fpdf/tutorial/20k_c1.txt b/app/fpdf/tutorial/20k_c1.txt similarity index 100% rename from fpdf/tutorial/20k_c1.txt rename to app/fpdf/tutorial/20k_c1.txt diff --git a/fpdf/tutorial/20k_c2.txt b/app/fpdf/tutorial/20k_c2.txt similarity index 100% rename from fpdf/tutorial/20k_c2.txt rename to app/fpdf/tutorial/20k_c2.txt diff --git a/fpdf/tutorial/calligra.php b/app/fpdf/tutorial/calligra.php similarity index 100% rename from fpdf/tutorial/calligra.php rename to app/fpdf/tutorial/calligra.php diff --git a/fpdf/tutorial/calligra.ttf b/app/fpdf/tutorial/calligra.ttf similarity index 100% rename from fpdf/tutorial/calligra.ttf rename to app/fpdf/tutorial/calligra.ttf diff --git a/fpdf/tutorial/calligra.z b/app/fpdf/tutorial/calligra.z similarity index 100% rename from fpdf/tutorial/calligra.z rename to app/fpdf/tutorial/calligra.z diff --git a/fpdf/tutorial/countries.txt b/app/fpdf/tutorial/countries.txt similarity index 100% rename from fpdf/tutorial/countries.txt rename to app/fpdf/tutorial/countries.txt diff --git a/fpdf/tutorial/index.htm b/app/fpdf/tutorial/index.htm similarity index 100% rename from fpdf/tutorial/index.htm rename to app/fpdf/tutorial/index.htm diff --git a/fpdf/tutorial/logo.png b/app/fpdf/tutorial/logo.png similarity index 100% rename from fpdf/tutorial/logo.png rename to app/fpdf/tutorial/logo.png diff --git a/fpdf/tutorial/makefont.php b/app/fpdf/tutorial/makefont.php similarity index 100% rename from fpdf/tutorial/makefont.php rename to app/fpdf/tutorial/makefont.php diff --git a/fpdf/tutorial/tuto1.htm b/app/fpdf/tutorial/tuto1.htm similarity index 100% rename from fpdf/tutorial/tuto1.htm rename to app/fpdf/tutorial/tuto1.htm diff --git a/fpdf/tutorial/tuto1.php b/app/fpdf/tutorial/tuto1.php similarity index 100% rename from fpdf/tutorial/tuto1.php rename to app/fpdf/tutorial/tuto1.php diff --git a/fpdf/tutorial/tuto2.htm b/app/fpdf/tutorial/tuto2.htm similarity index 100% rename from fpdf/tutorial/tuto2.htm rename to app/fpdf/tutorial/tuto2.htm diff --git a/fpdf/tutorial/tuto2.php b/app/fpdf/tutorial/tuto2.php similarity index 100% rename from fpdf/tutorial/tuto2.php rename to app/fpdf/tutorial/tuto2.php diff --git a/fpdf/tutorial/tuto3.htm b/app/fpdf/tutorial/tuto3.htm similarity index 100% rename from fpdf/tutorial/tuto3.htm rename to app/fpdf/tutorial/tuto3.htm diff --git a/fpdf/tutorial/tuto3.php b/app/fpdf/tutorial/tuto3.php similarity index 100% rename from fpdf/tutorial/tuto3.php rename to app/fpdf/tutorial/tuto3.php diff --git a/fpdf/tutorial/tuto4.htm b/app/fpdf/tutorial/tuto4.htm similarity index 100% rename from fpdf/tutorial/tuto4.htm rename to app/fpdf/tutorial/tuto4.htm diff --git a/fpdf/tutorial/tuto4.php b/app/fpdf/tutorial/tuto4.php similarity index 100% rename from fpdf/tutorial/tuto4.php rename to app/fpdf/tutorial/tuto4.php diff --git a/fpdf/tutorial/tuto5.htm b/app/fpdf/tutorial/tuto5.htm similarity index 100% rename from fpdf/tutorial/tuto5.htm rename to app/fpdf/tutorial/tuto5.htm diff --git a/fpdf/tutorial/tuto5.php b/app/fpdf/tutorial/tuto5.php similarity index 100% rename from fpdf/tutorial/tuto5.php rename to app/fpdf/tutorial/tuto5.php diff --git a/fpdf/tutorial/tuto6.htm b/app/fpdf/tutorial/tuto6.htm similarity index 100% rename from fpdf/tutorial/tuto6.htm rename to app/fpdf/tutorial/tuto6.htm diff --git a/fpdf/tutorial/tuto6.php b/app/fpdf/tutorial/tuto6.php similarity index 100% rename from fpdf/tutorial/tuto6.php rename to app/fpdf/tutorial/tuto6.php diff --git a/fpdf/tutorial/tuto7.htm b/app/fpdf/tutorial/tuto7.htm similarity index 100% rename from fpdf/tutorial/tuto7.htm rename to app/fpdf/tutorial/tuto7.htm diff --git a/fpdf/tutorial/tuto7.php b/app/fpdf/tutorial/tuto7.php similarity index 100% rename from fpdf/tutorial/tuto7.php rename to app/fpdf/tutorial/tuto7.php diff --git a/index.php b/app/index.php similarity index 100% rename from index.php rename to app/index.php diff --git a/index/adjust/adjustpanel.php b/app/index/adjust/adjustpanel.php similarity index 100% rename from index/adjust/adjustpanel.php rename to app/index/adjust/adjustpanel.php diff --git a/index/adjust/stat.php b/app/index/adjust/stat.php similarity index 100% rename from index/adjust/stat.php rename to app/index/adjust/stat.php diff --git a/index/admin/electionControl.php b/app/index/admin/electionControl.php similarity index 100% rename from index/admin/electionControl.php rename to app/index/admin/electionControl.php diff --git a/index/admin/electionsinfo.php b/app/index/admin/electionsinfo.php similarity index 100% rename from index/admin/electionsinfo.php rename to app/index/admin/electionsinfo.php diff --git a/index/classes/MenuGenerator.php b/app/index/classes/MenuGenerator.php similarity index 100% rename from index/classes/MenuGenerator.php rename to app/index/classes/MenuGenerator.php diff --git a/index/classes/TableGenerator.php b/app/index/classes/TableGenerator.php similarity index 100% rename from index/classes/TableGenerator.php rename to app/index/classes/TableGenerator.php diff --git a/index/clear.php b/app/index/clear.php similarity index 100% rename from index/clear.php rename to app/index/clear.php diff --git a/index/electionadmin/electionadminpanel.php b/app/index/electionadmin/electionadminpanel.php similarity index 100% rename from index/electionadmin/electionadminpanel.php rename to app/index/electionadmin/electionadminpanel.php diff --git a/index/session/login.php b/app/index/session/login.php similarity index 100% rename from index/session/login.php rename to app/index/session/login.php diff --git a/index/session/logout.php b/app/index/session/logout.php similarity index 100% rename from index/session/logout.php rename to app/index/session/logout.php diff --git a/index/useradmin/changepassword.php b/app/index/useradmin/changepassword.php similarity index 100% rename from index/useradmin/changepassword.php rename to app/index/useradmin/changepassword.php diff --git a/index/useradmin/newuser.php b/app/index/useradmin/newuser.php similarity index 100% rename from index/useradmin/newuser.php rename to app/index/useradmin/newuser.php diff --git a/index/useradmin/useradminpanel.php b/app/index/useradmin/useradminpanel.php similarity index 100% rename from index/useradmin/useradminpanel.php rename to app/index/useradmin/useradminpanel.php diff --git a/index/vote/front.php b/app/index/vote/front.php similarity index 100% rename from index/vote/front.php rename to app/index/vote/front.php diff --git a/install/evote.sql b/app/install/evote.sql similarity index 100% rename from install/evote.sql rename to app/install/evote.sql diff --git a/install/setup.php b/app/install/setup.php similarity index 100% rename from install/setup.php rename to app/install/setup.php diff --git a/js/bootstrap.js b/app/js/bootstrap.js similarity index 100% rename from js/bootstrap.js rename to app/js/bootstrap.js diff --git a/js/bootstrap.min.js b/app/js/bootstrap.min.js similarity index 100% rename from js/bootstrap.min.js rename to app/js/bootstrap.min.js diff --git a/js/checkForNewRound.js b/app/js/checkForNewRound.js similarity index 100% rename from js/checkForNewRound.js rename to app/js/checkForNewRound.js diff --git a/js/checkIfRoundClosed.js b/app/js/checkIfRoundClosed.js similarity index 100% rename from js/checkIfRoundClosed.js rename to app/js/checkIfRoundClosed.js diff --git a/js/countdown.js b/app/js/countdown.js similarity index 100% rename from js/countdown.js rename to app/js/countdown.js diff --git a/js/npm.js b/app/js/npm.js similarity index 100% rename from js/npm.js rename to app/js/npm.js diff --git a/localization/getLocalizedText.php b/app/localization/getLocalizedText.php similarity index 100% rename from localization/getLocalizedText.php rename to app/localization/getLocalizedText.php diff --git a/localization/localizedTextLookupTable.php b/app/localization/localizedTextLookupTable.php similarity index 100% rename from localization/localizedTextLookupTable.php rename to app/localization/localizedTextLookupTable.php diff --git a/logo.jpg b/app/logo.jpg similarity index 100% rename from logo.jpg rename to app/logo.jpg diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..232a53e --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,33 @@ +version: '3' +services: + web: + build: + context: . + dockerfile: dockerfiles/NGINX.dockerfile + ports: + - "80:80" + volumes: + - webfiles:/app + depends_on: + - php + - mysql + php: + build: + context: . + dockerfile: dockerfiles/PHP.dockerfile + volumes: + - webfiles:/app + mysql: + build: + context: . + dockerfile: dockerfiles/MYSQL.dockerfile + environment: + MYSQL_ROOT_PASSWORD: 'noneofyourbuisness' + MYSQL_USER: 'evote' + MYSQL_PASSWORD: 'evote' + MYSQL_DATABASE: 'evote' + ports: + - 3306 + +volumes: + webfiles: \ No newline at end of file diff --git a/dockerfiles/MYSQL.dockerfile b/dockerfiles/MYSQL.dockerfile new file mode 100644 index 0000000..9f980d3 --- /dev/null +++ b/dockerfiles/MYSQL.dockerfile @@ -0,0 +1,3 @@ +FROM mariadb:latest + +ADD app/install/evote.sql /docker-entrypoint-initdb.d/evote.sql \ No newline at end of file diff --git a/dockerfiles/NGINX.dockerfile b/dockerfiles/NGINX.dockerfile new file mode 100644 index 0000000..0601162 --- /dev/null +++ b/dockerfiles/NGINX.dockerfile @@ -0,0 +1,6 @@ +FROM nginx:latest +COPY nginxconf/nginx.conf /etc/nginx/conf.d/nginx.conf +COPY nginxconf/php.conf /etc/nginx/php.conf +COPY nginxconf/fastcgi_params /etc/nginx/fastcgi_params +COPY ./app/ /app/ +RUN chown -R www-data:www-data /app diff --git a/dockerfiles/PHP.dockerfile b/dockerfiles/PHP.dockerfile new file mode 100644 index 0000000..ca9b8b2 --- /dev/null +++ b/dockerfiles/PHP.dockerfile @@ -0,0 +1,3 @@ +FROM php:7.4.33-fpm + +RUN docker-php-ext-install pdo pdo_mysql mysqli \ No newline at end of file diff --git a/nginxconf/fastcgi_params b/nginxconf/fastcgi_params new file mode 100644 index 0000000..4b9008f --- /dev/null +++ b/nginxconf/fastcgi_params @@ -0,0 +1,25 @@ +fastcgi_param QUERY_STRING $query_string; +fastcgi_param REQUEST_METHOD $request_method; +fastcgi_param CONTENT_TYPE $content_type; +fastcgi_param CONTENT_LENGTH $content_length; + +fastcgi_param SCRIPT_NAME $fastcgi_script_name; +fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; +fastcgi_param PATH_INFO $fastcgi_path_info; +fastcgi_param REQUEST_URI $request_uri; +fastcgi_param DOCUMENT_URI $document_uri; +fastcgi_param DOCUMENT_ROOT $document_root; +fastcgi_param SERVER_PROTOCOL $server_protocol; +fastcgi_param HTTPS $https if_not_empty; + +fastcgi_param GATEWAY_INTERFACE CGI/1.1; +fastcgi_param SERVER_SOFTWARE nginx/$nginx_version; + +fastcgi_param REMOTE_ADDR $remote_addr; +fastcgi_param REMOTE_PORT $remote_port; +fastcgi_param SERVER_ADDR $server_addr; +fastcgi_param SERVER_PORT $server_port; +fastcgi_param SERVER_NAME $server_name; + +# PHP only, required if PHP was built with --enable-force-cgi-redirect +fastcgi_param REDIRECT_STATUS 200; \ No newline at end of file diff --git a/nginxconf/nginx.conf b/nginxconf/nginx.conf new file mode 100644 index 0000000..3b419c7 --- /dev/null +++ b/nginxconf/nginx.conf @@ -0,0 +1,23 @@ +server { + listen 80 default_server; +# server_name evote.; +# access_log //access.log; +# error_log //error.log; + root /app; + index index.html index.php; + + location ~ \.php$ { + include php.conf; + } + + + location / { + try_files $uri @evote; + } + + # Always rewrite to index.php + location @evote { + rewrite ^(.*)$ /index.php$1 break; + include php.conf; + } +} diff --git a/nginxconf/php.conf b/nginxconf/php.conf new file mode 100644 index 0000000..38a1a2a --- /dev/null +++ b/nginxconf/php.conf @@ -0,0 +1,4 @@ +fastcgi_split_path_info ^(.+\.php)(/.+)$; +fastcgi_pass php:9000; +fastcgi_index index.php; +include fastcgi_params; \ No newline at end of file From 377da52718bda4799c1ed9c94bddc7727789ad3a Mon Sep 17 00:00:00 2001 From: Witko Tamm Date: Mon, 11 Sep 2023 13:37:22 +0200 Subject: [PATCH 2/4] Moved variables for database to environmentfile --- .env-sample | 4 ++++ .gitignore | 1 + docker-compose.yml | 13 ++++++++----- 3 files changed, 13 insertions(+), 5 deletions(-) create mode 100644 .env-sample create mode 100644 .gitignore diff --git a/.env-sample b/.env-sample new file mode 100644 index 0000000..20732a2 --- /dev/null +++ b/.env-sample @@ -0,0 +1,4 @@ +DB_ROOT_PASSWD='secret' +DB_USER='evote' +DB_USER_PASSWD='secret' +DB_NAME='evote' \ No newline at end of file diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..4c49bd7 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.env diff --git a/docker-compose.yml b/docker-compose.yml index 232a53e..a3a74c0 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -22,12 +22,15 @@ services: context: . dockerfile: dockerfiles/MYSQL.dockerfile environment: - MYSQL_ROOT_PASSWORD: 'noneofyourbuisness' - MYSQL_USER: 'evote' - MYSQL_PASSWORD: 'evote' - MYSQL_DATABASE: 'evote' + MYSQL_ROOT_PASSWORD: ${DB_ROOT_PASSWD} + MYSQL_USER: ${DB_USER} + MYSQL_PASSWORD: ${DB_USER_PASSWD} + MYSQL_DATABASE: ${DB_NAME} + volumes: + - evote-mysqldata:/var/lib/mysql ports: - 3306 volumes: - webfiles: \ No newline at end of file + webfiles: + evote-mysqldata: \ No newline at end of file From 680e65cacab3128787cf1e75254d1b9ee4b0638b Mon Sep 17 00:00:00 2001 From: Witko Tamm Date: Mon, 11 Sep 2023 14:05:05 +0200 Subject: [PATCH 3/4] Possibility to serve on different ports --- .env-sample | 3 ++- docker-compose.yml | 4 +--- nginxconf/nginx.conf | 2 +- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/.env-sample b/.env-sample index 20732a2..9cf99a4 100644 --- a/.env-sample +++ b/.env-sample @@ -1,4 +1,5 @@ DB_ROOT_PASSWD='secret' DB_USER='evote' DB_USER_PASSWD='secret' -DB_NAME='evote' \ No newline at end of file +DB_NAME='evote' +NGINX_PORT=80 \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index a3a74c0..6690d17 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -5,7 +5,7 @@ services: context: . dockerfile: dockerfiles/NGINX.dockerfile ports: - - "80:80" + - "${NGINX_PORT}:80" volumes: - webfiles:/app depends_on: @@ -28,8 +28,6 @@ services: MYSQL_DATABASE: ${DB_NAME} volumes: - evote-mysqldata:/var/lib/mysql - ports: - - 3306 volumes: webfiles: diff --git a/nginxconf/nginx.conf b/nginxconf/nginx.conf index 3b419c7..60f9c9d 100644 --- a/nginxconf/nginx.conf +++ b/nginxconf/nginx.conf @@ -1,5 +1,5 @@ server { - listen 80 default_server; + listen 80 default_server; # server_name evote.; # access_log //access.log; # error_log //error.log; From 0fbbec82fb91ef4efd7b663f68d126d234005d04 Mon Sep 17 00:00:00 2001 From: Witko Tamm Date: Mon, 11 Sep 2023 15:33:25 +0200 Subject: [PATCH 4/4] included instructions for docker --- app/README.md => README.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) rename app/README.md => README.md (87%) diff --git a/app/README.md b/README.md similarity index 87% rename from app/README.md rename to README.md index dc97c45..6996d47 100644 --- a/app/README.md +++ b/README.md @@ -36,6 +36,22 @@ A good strategy of handling the personal codes of a meeting is to create the ele ## Installation guide +### Quickstart for docker +This version of E-vote has been constructed to work with Docker in order for the setup to be quicker than before. Implementationdetails are outlined below. +Rename .env-sample to .env and change the default values. These are used in the setup of the website. Note that `NGINX_PORT` should only be changed if used behind a reverse proxy as the final url must access port 80. + +After that run it with +``` +docker-compose up +``` +This will download the base images (webserver and database), add the files from this project, configure these and then run it. As a final step, open the webbrowser and open `{baseurl}/install/setup.php` and complete the setup there. If developing locally, use `127.0.0.1` since `localhost` does not work. Database `host` will be `mysql`. + +#### Docker implementation +Docker-compose creates 3 containers, NGINX which is the webserver, PHP evaluates the PHP sites for NGINX, and mysql which is the database used. + +Each of these containers has their own dockerfile for configuring them. NGINX has to include multiple files for configuration, as well as the project files. PHP has to import functionallity to connect to the database, and the database needs a prefilled database. + +If the stack is stopped, the data is retained in volumes, and as such if started again will not need new setup. ### Running locally for development/testing If you are going to develop or test E-vote locally you can use PHP's built-in tools. Simply clone the repo, change directory to the one created by the clone and run