Month: February 2017

Recent Posts

GitLab & LaTeX Builds


I like to write letters. I do not, however, enjoy wrangling Microsoft Word to ensure the same results each time; I use LaTex, where I can be guaranteed of consistent output.

As my library of past correspondence increases, I was looking for a way to implement version control as I drafted correspondence. Git was the obvious solution, and quite straightforward to set up. As I run a GitLab server on my Synology, I was happy storing a big backup of all of the history on a RAID device elsewhere in the house. But, I realised, it wasn't good practice to store the generated PDFs — the binary outputs — alongside their .tex files. At the same time, I had recently put together a fairly unique build server using GitLab CI for work. I was sure that I could make something that would be useful to me in this instance too.

...Read More

Email Submission to GitLab in a Synology Docker Image

I realise this is quite a specific post; this is mainly for posterity.

I have a Synology box running this docker image for GitLab. I also have some interest in configuring GitLab to receive emails from a specified mailbox, and create new issues upon receipt of an email.

This is possible with the docker image, using variables such as IMAP_USER as described in the gitlab docker page.

When this is all set up, the docker image fails to start its mail client. You will need to log in to the docker image, by first running docker ps. This will allow you to obtain the CONTAINER_ID of the docker image.

This will allow you to obtain a shell for the docker image, by typing docker exec -it CONTAINER_ID bash.

Then, on the docker image, run sudo -u git -H RAILS_ENV=production bin/mail_room start. This will start the mail_room, and if configured correctly, your docker image should start polling the configured IMAP server.