Developement is now continued by gruene.ch on their own fork. See grueneschweiz/imagery.
Easily generate images in the corporate design of the swiss GREENS.
This tools aims to provide a simple way to generate images conforming the corporate design rules. It's designed to be so simple to use, that no further instructions are needed and no corporate design rules can be broken.
Not everybody has the software and skills to create corporate design images on his own. And it's not everybodys hobby to learn all the rules of the corporate design.
Read the dedicated docs.
... is cool, simple and helps to make the π a better place π€©
- Install docker and docker-compose.
- Clone this repo
git clone https://github.com/cyrillbolliger/imagery
cd
into the folder containing the repo- Execute
bash install.sh
and have a βοΈ while it installs. - Visit localhost:8000/
- Use
superadmin@user.login
andpassword
to login. - As the font used in the corporate design is proprietary, you'll need to get a
licenced copy of the Sanuk font (fat and bold). Store it as follows:
storage |-- app |-- fonts |-- SanukOT-Bold.otf |-- SanutOT-Fat.otf
- The indesign templates bundles for the logo suffer the limitations of the
proprietary Sanuk font as well. If you've got a licenced copy of the Sanuk
font, we can provide you the bundles. Store them as follows:
storage |-- app |-- vector_logo_templates_indesign |-- gruene |-- ... |-- gruene-les-vertes |-- ... |-- les-vertes |-- ...
Using a Lamp stack on docker, the tool is built with Laravel.
The frontend is built with VueJS and the image processing
is done with the canvas
element. It's all bundled by Webpack using
Laravel Mix. Have a look at the package.json
if you want to dig deeper.
- Start up:
docker-compose up -d
- Shut down:
docker-compose stop
- Execute CLI commands (enter container):
docker exec -it imagery bash
. Useexit
to escape the container.
All tests are based on PHPUnit. It may be used as follows:
- Make sure your containers are up and running.
- Run
docker exec imagery vendor/bin/phpunit
.
Use the handy phpMyAdmin or access the mysql CLI using
docker exec -it imagery_mysql bash -c 'mysql -u${MYSQL_USER} -p${MYSQL_PASSWORD} imagery'
The node container is watching the js, css and scss files and building the assets.
- Access the watching container using
docker exec -it imagery_node bash
. - Get the build output
docker attach imagery_node
.
The PHP Composer runs directly on the imagery
container.
- Access it using
docker exec imagery composer YOUR_COMPOSER_SUBCOMMAND
.
All mail you send out of the application will be caught by Mailhog. Access it on localhost:8020
All translation is done with crowdin. To translate in-context visit localhost:8000/?translate=true&lang=zu.
Logins created by the demo seeder:
superadmin@user.login
:password
countryadmin@user.login
:password
cantonadmin@user.login
:password
localuser@user.login
:password
We use actions to test the application (and maybe in the future to automate the crowdin workflow).
The tests rely on the proprietary fonts. Bundle them using the following command (executed in the project root):
tar -zcv \
storage/app/fonts \
storage/app/vector_logo_templates_indesign \
| openssl enc \
-e -aes256 \
-md sha512 \
-pbkdf2 -iter 100000 \
-pass file:proprietary.key \
-out proprietary.tar.gz.enc
The files will be automatically decrypted by the Add proprietary files
step (cf. .github/workflows/tests.yml
).
The key is stored as a
repository secret.
To decrypt and unpack the bundle manually:
openssl enc \
-d -aes256 \
-md sha512 \
-pbkdf2 -iter 100000 \
-pass file:proprietary.key \
-in proprietary.tar.gz.enc \
| tar -xzv