I'm using django-inlinecss to style emails.
Here's a snippet of my email template:
{% extends "base/email.html" %}
{% block content %}
{% load inlinecss %}
{% inlinecss "base/css/email.css" %}
<p class="c-c-test">test</p>
{% endinlinecss %}
{% endblock %}
When rendering the template, an error occurs saying:
No such file or directory: '/usr/src/project/static/base/css/email.css'
Although, trying to use the same css file path (i.e. "base/css/email.css"
) with static
template tag works fine.
What am I doing wrong here?
EDIT:
I'm using docker, django-inlinecss
seems to load the css file from local storage (i.e. from docker image) where there's no such file. The actual file is located on my machine. Is there a workaround to solve this issue? something like how static
template tag work?