Giter Club home page Giter Club logo

mail2deck's Introduction

mail2deck

Provides an "email in" solution for the Nextcloud Deck app

๐Ÿš€ A. For users

Follow the above steps to add a new card from email.

  • Deck Bot is the user who will create the cards and it will be set up by your nextcloud admin.
  • In this tutorial email address for Deck Bot will be: [email protected]

1) Assign Deck Bot to the board.

Deck Bot must be assigned and must have edit permission inside the board.

2) Mail subject & content

Let's assume you want to add a card with title "Update website logo" on board "Website" and stack "To do". You can do this in two ways.

2.1: Set stack and board in the email subject

Here's how the email subject should look like: Update website logo b-'website' s-'to do'

You can use single or double quotes.

Case-insensitive for board and stack respectively.

2.2: Set the board in the email address

At the end of the email address prefix (before @) add "+website"

Example: [email protected]

In this case, if you don't specify the stack in the email subject, the card will be added in the first stack (if it exists).

Note:

  • Email content will be card description
  • You can add attachments in the email and those will be integrated in the created card

โš™๏ธ B. For NextCloud admins to setup

Requirements

This app requires php-curl, php-mbstring ,php-imap and some sort of imap server (e.g. Postfix with Courier).

NC new user

Create a new user from User Management on your NC server, which will have to function as a bot. We chose to call him deckbot, but you can call it however you want.
Note: that you have to assign deckbot on each board you want to add new cards from email.

Configure Email

Option 1 - Set up Postfix for incoming email

You can setup Posfix mail server folowing the instructions on Posfix setup, and after that add "+" delimiter (which separe the user from the board in the email address) using the command:

sudo postconf -e "recipient_delimiter = +"

Option 2 - Use an existing email server

This could be any hosted email service. The only requirement is that you can connect to it via the IMAP protocol. Please note this option may not be as flexible as a self-hosted server. For example your email service may not support the "+"delimiter for directing messages to a specific board.

Download and install

If using a self-hosted Postfix server, clone this repository into the home directory of the incoming user. If not self-hosting, you may need to create a new user on your system and adjust the commands in future steps to match that username.

cd /home/incoming/
git clone https://github.com/putt1ck/mail2deck.git mail2deck

Edit the config file as you need:

sudo nano /home/incoming/mail2deck/config.php

You can refer to https://www.php.net/manual/en/function.imap-open.php for setting the value of MAIL_SERVER_FLAGS

Add a cronjob which will run mail2deck.

sudo crontab -u incoming -e

Add the following line in the opened file: */5 * * * * /usr/bin/php /home/incoming/mail2deck/index.php >/dev/null 2>&1

Finish

Now mail2deck will add new cards every five minutes if new emails are received.

mail2deck's People

Contributors

puiuallex avatar bpehrs11 avatar lucianpricop avatar putt1ck avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.