Django community: RSS
This page, updated regularly, aggregates Django Q&A from the Django community.
-
Django database relation
I am working on a forum using django, I have a problem accessing user fullname and bio, from a model class I have. I have no problem accessing the user.username or user.email, but not from the Author class.. This is from the models.py in the forum app User = get_user_model() class Author(models.Model): user = models.ForeignKey(User, on_delete=models.CASCADE) fullname = models.CharField(max_length=40, blank=True) slug = slug = models.SlugField(max_length=400, unique=True, blank=True) bio = HTMLField() points = models.IntegerField(default=0) profile_pic = ResizedImageField(size=[50, 80], quality=100, upload_to="authors", default=None, null=True, blank=True) def __str__(self): return self.fullname My form is in the user app, where i have a profile update site, and the form is like this from forums.models import Author class UpdateForm(forms.ModelForm): class Meta: model = Author fields = ('fullname', 'bio', 'profile_pic') Then here is some of the update site, however nothing let me get access to the bio or fullname, I've tried so many combos. and I am lost here.. {% block content %} <section class="section" id="about"> <!-- Title --> <div class="section-heading"> <h3 class="title is-2">Hey {{ user.username }}</h3> <div class="container"> <p>{{ user.bio }}bio comes here</p> </div> </div> If there is some relation i am missing please help -
Django, user customization of current site
Is there any way I can create in Django site that the user can customize for his purpose, by for e.g. adding as many charts as he likes to? -
Django Debug toolbar isn't showing up in the browser
I expected to see Django Debug toolbar on the right hand side of my browser. Instead on my browser I have a box with "Enter your search term" in it. I have looked over the installation instructions to see if I've missed a step and I haven't. Also, I imported the debug_toolbar on the urls.py page and it looks to be a bit gray. [enter image description here] 1Below is some of my code from the settings.py file and the picture is from my urls.py file INSTALLED_APPS = [ 'django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.messages', 'django.contrib.staticfiles', 'playground', 'debug_toolbar' ] MIDDLEWARE = [ 'debug_toolbar.middleware.DebugToolbarMiddleware', 'django.middleware.security.SecurityMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.common.CommonMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware', 'django.middleware.clickjacking.XFrameOptionsMiddleware', ] INTERNAL_IPS = [ # ... "127.0.0.1", # ... ] ROOT_URLCONF = 'storefront.urls' TEMPLATES = [ { 'BACKEND': 'django.template.backends.django.DjangoTemplates', 'DIRS': [], 'APP_DIRS': True, 'OPTIONS': { 'context_processors': [ 'django.template.context_processors.debug', 'django.template.context_processors.request', 'django.contrib.auth.context_processors.auth', 'django.contrib.messages.context_processors.messages', ], }, }, ] -
Django Pagination show no data after clicking on next button
I have a pagination in Django application. when I load the page the data display is fine on the first page but when I click on second button of paginator no data is shown on next page. Following is my code: viwes.py def get_queryset(self, **kwargs): # get query params query = self.request.GET.get("q", "") page = self.request.GET.get("page", "1") size = self.request.GET.get("rows", "15") cname = self.request.GET.getlist("cname", []) tags = self.request.GET.getlist("tag", []) filter_param = self.request.GET.getlist("filter_param", []) # get size and set to default 15 if its not digit if size.isdigit(): size = int(size) else: size = 15 # get response from elastic search response = self.get_archives(query, page, size, cname, tags, filter_param) response = list(iter(response)) for res in response: if 'statement' in res: ref = self.get_reference(res['statement'], response) res['references'] = ref p = Paginator(response, 2) pages = p.get_page(page) return pages response list is passed to frontend, response has data when sending it to first page but when request is send again after clicking on second button response list is passed empty to frontend. claims.html <div class="row" style="padding-top: 30px;"> {%if archives.paginator.count %} <div class="col" style="float: right;"> <nav aria-label="Page navigation"> <ul class="pagination"> {% if archives.has_previous %} <li class="page-item"> <a class="page-link" href="?page=1&q={{query}}&size={{size}}&cname={{cname}}" aria-label="Previous"> <span aria-hidden="true">&laquo;</span> <span class="sr-only">begin</span> </a> … -
psycopg2.errors.DuplicateTable: relation "airgoLocator_translationexception" already exists
I am experiencing the error, psycopg2.errors.DuplicateTable: relation "airgoLocator_translationexception" already exists I have returned the migrations back, to a point where I am sure that everything worked python manage.py migrate app 0058 python manage.py migrate app python manage.py makemigrations I have also tried to do python manage.py migrate --fake app python manage.py migrate python manage.py makemigrations But I have not been lucky. I have the backend in a gitlab image that I lift from a docker, therefore the backend restarts all the time with this error. Therefore I have to make these changes in the migrations and generate a new image, every time I try to test a solution. The database is a postgres that is in another container. If someone can give me support in this regard, I would be more than grateful. Thank you -
django/bootstrap5 signup form unknown checkbox
I'm creating an app with Django and I created a sign up form with Django/Bootstrap5. It's all good. The only problem is a checkbox at the end of the form that I didn't expect. I'll try to add a screenshot to this post to show it to you. I would like your opinion about it. My guess is that probably with this checkbox the user would accept T&C, but I have no T&C for this registration to propose. Is there any way to remove this checkbox from here? Sorry but I could not find anything in the documentation. The code is very simple: {% extends "learning_steps/base.html" %} {% load bootstrap5 %} {% block page_header %} <h2 class="mt-5">Create your new account.</h2> {% endblock page_header %} {% block content %} <div class="col-7"> <form method="post" action="{% url 'users:register' %}" class="form form-red"> {% csrf_token %} {% bootstrap_form form %} {% buttons %} <button name="submit" class="btn-red btn-login-size">Sign up!<button> {% endbuttons %} <input type="hidden" name="next" value="{% url 'learning_steps:index' %}" /> </form> </div> {% endblock content %} And this is the screenshot, I hope it's useful. Thank you everybody! -
Getting 403 Forbidden error in django applicaion if user is logged-in in my website. I am not getting this error for anonymous user
I am new to django and ajax both. I am getting 403 error only if I am logged-in user. If am logged out same is working fine. Here is my ajax call: $("div#mainCont").on("click","#detail_icon", function(){ var _tickName = $(this).parent().attr('id'); var csrf = $("input[name=csrfmiddlewaretoken]").val(); $.ajax({ method: "POST", url: 'performance', data:JSON.stringify({ csrfmiddlewaretoken: csrf, ticker: _tickName }), success: function (data) { console.log(data) } }); This is my view: class PerformanceView(APIView): def get(self,request, format=None): queryset = Advice.objects.all() serializer = AdviceSerializers(queryset,many=True) return Response(serializer.data) def post(self, request): data=json.loads(request.body) print(data) queryset = Stocks.objects.filter(ticker=data["ticker"]) serializer = PerformanceSerializers(queryset,many=True) return Response(serializer.data) Thanks in advance -
Image is not showing up on my website (django)
I'am new to django. I wanted to upload an image but it doesn't show up on website. Instead it shows broken image icon. I tried to use load static block but it still doesn't work. My html file: <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Website</title> </head> <body> <h1>Hello</h1> {% load static %} <img src="{% static 'webdev/static/webdev/images/images.jpg' %}"> </body> urls.py file: from django.contrib import admin from django.urls import path from homepage import views urlpatterns = [ path('', views.home_page, name='home'), path('admin/', admin.site.urls), ] views.py file: from django.shortcuts import render from django.http import HttpResponse def home_page(request, *args, **kwargs): return render(request, 'home.html', {}) -
Trying to display webcam footage on webpage from OpenCV (Django) while using docker
I am trying to create a facial recognition attendance system - My project framework is DJango and I have deployed it on docker, however I am running into issues trying to access the webcam through docker. This is my code: views.py: class mycamera(object): def __init__(self): self.frames = cv2.VideoCapture(0) def __del__(self): self.frames.release() def get_jpg_frame(self): is_captured, frame = self.frames.read() retval, jframe = cv2.imencode('.jpg', frame) return jframe.tobytes() def livefeed(): camera_object = mycamera() while True: jframe_bytes = camera_object.get_jpg_frame() yield (b'--frame\r\n' b'Content-Type: image/jpeg\r\n\r\n' + jframe_bytes + b'\r\n\r\n') @condition(etag_func=None) def display_livefeed(self): return StreamingHttpResponse( livefeed(), content_type='multipart/x-mixed-replace; boundary=frame' ) urls.py: from users import views as user_views path('vidstream/', user_views.display_livefeed, name='vidStream') Error code when access 0.0.0.0:8000/vidstream/: web_1 | [04/Jan/2022 17:47:16] "GET /vidstream/ HTTP/1.1" 500 59 web_1 | [ WARN:0@3.508] global /io/opencv/modules/videoio/src/cap_v4l.cpp (889) open VIDEOIO(V4L2:/dev/video0): can't open camera by index web_1 | Traceback (most recent call last): web_1 | File "/usr/local/lib/python3.10/wsgiref/handlers.py", line 138, in run web_1 | self.finish_response() web_1 | File "/usr/local/lib/python3.10/wsgiref/handlers.py", line 183, in finish_response web_1 | for data in self.result: web_1 | File "/code/users/views.py", line 81, in livefeed web_1 | jframe_bytes = camera_object.get_jpg_frame() web_1 | File "/code/users/views.py", line 75, in get_jpg_frame web_1 | retval, jframe = cv2.imencode('.jpg', frame) web_1 | cv2.error: OpenCV(4.5.5) /io/opencv/modules/imgcodecs/src/loadsave.cpp:976: error: (-215:Assertion failed) !image.empty() in function … -
Which subscription events to monitor for and which actions to take?
I have a subscription product that offers users monthly and annual subscriptions without free trials. All the docs I've seen kind of assume that I should know what types of actions to take when a new user subscribes to my service. The Stripe docs on provision and monitor say the minimum events to monitor are: checkout.session.completed invoice.paid invoice.payment_failed But then what do after monitoring for these events? In the dj-stripe docs on webhooks there are some clues as to what I should be doing including: Notifying the customer via email "Invalidating a cache" "Fire off a celery task" Is there anything else I should consider doing? And how do I know when to do what? Sorry if these are newb questions but this all just seems really subjective and I am just grasping for some guidance. Of course with dj-stripe I will be adding a lot of info to the database and this is all handled automatically. And of know that I can and should email the user when an invoice is paid or payment failed. But what about checkout.session.completed? Why is this a minimum event to monitor for? When a checkout session is completed Stripe redirects the user back … -
How do I integrate Neo4j DB with Django application?
I've tried this "https://neomodel.readthedocs.io/en/latest/getting_started.html#connecting" but Didn't mention which code is need to be placed in which file. I installed neomodel package but it's still not recognizing neomodel. Also, I've tried Py2neo and neo4django. But it's not working in any way. Can anyone please suggest me something helpful for doing it? Thanks in advance. -
django-simple-menu multiple active at a time
I've select submenu of an item. But it selects top most parents and selects anothers what I've selected. Just like below. Though I've selected purchase submenu but it shows 1st one and selected one -
In Django, how do I obtain ONLY the file path from a FileField in a form without loading the file into memory?
For a Django form, I like and need the FileField feature where it allows the user to navigate to a file locally and select it, but on the backend I only want to retain the absolute file path WITHOUT loading the file into memory first. I'm dealing with files in the 300 million+ records and do not want to do any data storage in memory, only obtain its path on the system. I tried FilePathField but it mandates pre-specifying a home directory for the files, which would not allow for the navigation feature of FileField. -
Django FOREIGN KEY constraint failed on OneToOneField
So I've created 2 classes of models. One has an OneToOneField and this class was referenced by the other using the ForeignKey field. It returns an error whenever I save it even in Django admin. Model classes class First(models.Model): sample_field = models.OneToOneField(Person, on_delete=models.CASCADE, primary_key=True) class Second(models.Model): another_field = models.ForeignKey(First, on_delete=models.CASCADE, blank=True, null=True, related_name='sample_related_name') Error Message IntegrityError at /admin/management/group/add/ FOREIGN KEY constraint failed Thank you! -
JS appending element to parent not working
I am trying to add the new row to my table, but the I am unable to append a new row to the table. If i console log the elements individually I get the expect response can anyone help me find a solution to the problem, below is the code Html <tbody id="tableProduct"> {%for product in products %} <tr> <td scope="row" class="rowCounter"></td> <td>{{product.nameP}}</td> <td>{{product.brand}}</td> <td>{{product.price}}</td> </tr> {%endfor%} </tbody> JS class UI { //Adding the new Product to the display static addProduct(product){ const table = document.querySelector('#tableProduct'); const newRow = document.createElement('tr'); newRow.innerHtml = ` <td scope="row" class="rowCounter"></td> <td>Camera</td> <td>Sony</td> <td>10000</td> `; console.log(table.firstElementChild); //Placing the new row into the table //table.insertBefore(newRow, table.firstElementChild); //table.insertBefore(newRow, table.firstChild); table.appendChild(newRow); console.log(newRow.innerHtml) } } document.querySelector('#productForm').addEventListener('submit', (event)=>{ event.preventDefault(); UI.addProduct(newProduct); }) -
Change Celery task to run on-demand with clicking a button
I have a celery task that runs periodically and fetches some data for all companies that use a certain accounting service. I now need to make that task run on-demand with a click of a button, and fetch only the current company's data. Modified celery task: @APP.task def import_data_for_company(company_id): for integration in settings.INTEGRATIONS: if integration["owner"]["company_id"] == company_id: print("omlette du fromage") Current button in Django template {% for integration in settings.INTEGRATIONS %} {% if company.company_id == integration.owner.company_id %} <div class="button"> <a class="btn" href="#">Import Data</a> </div> {% endif %} {% endfor %} I need to trigger that task from the Django template and pass a company ID as an argument while doing it. But according to this comment, I cannot pass arguments from the Django template. Writing a custom template tag/filter seems not to help here. What are my options for calling that function via this button? Have to note, that I'm very green at this still. -
Does not understanding what does the Operating system security website means?
For the FYP of Operating System subject , i create the django website buy domain from namecheap use Heroku for hosting and SSL . But my teacher is saying something different which i'm not getting what he want me to build read the email of my teacher kindly guide me what i have to build to show him the email : Unfortunately i do not see your project satisfying the requirements of the OS security project.i understand u worked hard building the web Application using django .However the project was not to build the web application alone ,it was to build install the OS the entire web application slack and then use SSL, in addition it was to build the certificate Authority from what i can see, You used the django web framework on a heroku service (with all the slack pre -installed ). -
FiedDoesNotExist with ManytoMany field
I have an issue while running migrations, I get this error : django.core.exceptions.FieldDoesNotExist: Profile has no field named 'following yet I have defined the field in my model, what could be the issue ? below is my model : class Profile(TimeStampedModel, models.Model): last_name = models.CharField(_('Last Name'), max_length=150, null=True, blank=True) gender = models.CharField(_('Gender'), null=True, max_length=30, choices=GENDER_CHOICES, blank=True) following = models.ManyToManyField(User, related_name='following', default=None, blank=True) What could be the issue ? -
How to show all objects by one on one page?
I am doing quiz app. I want questions to appear on one page but by one. For example, we have 5 questions. I see the first of them, answer this and only after that I can see the next one and the previous one disappears. How to do it? Plz I need help. It is really important. Thanks everyone! -
How to build sass files with django
I'm completly new with Django and python (and alone as tech in my company, not able to ask help to previous dev). I have to maintain an existing app written in django still developing new services fully written in node, which is my most important task (and my skills). I have a problem that i have fixed some bugs in UX, fixing CSS mostly. And I don't understand how to build sass. In manage.py, when i ask the list of commands the only things which is related to my problem is "collectstatic" which seems to not build but just collect static files (good naming so) in one folder. And obviously, it doesn't resolve my problem. Any suggestion ? I'm lost in this big new thing. Many love on every body who can help me. Do you know if there is an integrated tool ? Do i need to use an external compiler which is just not documented ? -
Filter doesn't work with prefetch_related_objects - Django
I'm trying to write a view that prefetch its request content so I can speed up the request execution (3.5s instead of 3min when chaining requests). The goal is to fetch some rows (Exchange_pair objects) depending on a root model value in the prefetch path (connection.exchange_id). connections__wallets__currency__base_pairs ^ | |_______________________________| depends on the current connection's exchange_id View: @api_view(['GET']) @permission_classes([permissions.IsAuthenticated]) def get_portfolio_view(request): portfolio_id = request.GET.get('id') # get portfolio + prefetch connections (and other things...) portfolio = Portfolio.objects.prefetch_related( 'connections__exchange', 'connections__wallets__currency__metadata__images' ).get(id=portfolio_id) for connection in portfolio.connections.all(): # build filter pairs_queryset = ExchangePair.objects.filter( exchange_id=connection.exchange_id, quote_id__in=["825", "2781", "3408", "4687"], last_price__isnull=False, ) # prefetch for related connection prefetch_related_objects( [connection], Prefetch('wallets__currency__base_pairs', queryset=pairs_queryset) ) data = PortfolioSerializer(portfolio).data return Response(data) Models: class Connection(models.Model): exchange = models.ForeignKey(Exchange, related_name='exchange', on_delete=models.CASCADE) portfolios = models.ManyToManyField(Portfolio, related_name='connections') # ... class ExchangePair(models.Model): id = models.IntegerField(primary_key=True) # CoinMarketCap id exchange = models.ForeignKey(Exchange, related_name='pairs', on_delete=models.CASCADE) # ... The code works in 90% of the cases. But in some cases: the queryset filter doesn't work and it retrieves ExchangePair objects with the wrong exchange_id. This makes no sense to me, I can't figure it out, seems like prefetch_related_objects() contains a bug. -
How to provide a source directory in the [tool.django-stubs] directive of a pyproject.tom file?
I'm using a src directory as root source directory in my django projects. I'm trying to perform pre-commit actions on those django projects, with mypy and django-stubs. Is is a way to say in pyproject.toml than the source root is in src/ ? For now, I've: [tool.django-stubs] django_version = "3.2" django_apps = ["account", "seniors", "seniors_app"] django_settings_module = "seniors.settings.dev" ignore_missing_settings = true ignore_missing_model_attributes = true pre-commit run --all ... ModuleNotFoundError: No module named 'seniors' When I put django_settings_module = "src.seniors.settings.dev", I've some errors later on importing the other modules ( account...) Have you any ideas ? For sure I don't want to change my project layout ! Thanks ! -
Bootstrap 5 site header works on desktop but not on mobile
I am following the great Django series by Corey Schafer (https://www.youtube.com/playlist?list=PL-osiE80TeTtoQCKZ03TU5fNfx2UY6U4p). Given that Bootstrap 5 has emerged since it's creation, i'm attempting to utilize it for my modified creation. The problem I am finding is that the header below is functioning properly desktop site (note: I've only activated the register.html link so far as I progress through the course), but the "hamburger" that should be created is inactive and unclickable on the mobile site. Here is the relevant file creating the header: base.html {% load static %} <!DOCTYPE html> <html> <head> <!-- Required meta tags --> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <!-- Bootstrap CSS --> <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous"> <link rel="stylesheet" type="text/css" href="{% static 'The6ixDjango/main.css' %}"> {% if title %} <title>{{ title }}</title> {% else %} <title>The6ixClan</title> {% endif %} </head> <body> <header class="site-header"> <nav class="navbar navbar-expand-md navbar-dark bg-steel fixed-top"> <div class="container"> <a class="navbar-brand mr-4" href="{% url 'The6ixDjango-home' %}">The6ixClan</a> <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarToggle" aria-controls="navbarToggle" aria-expanded="false" aria-label="Toggle navigation"> <span class="navbar-toggler-icon"></span> </button> <div class="collapse navbar-collapse" id="navbarToggle"> <div class="navbar-nav mr-auto"> <a class="nav-item nav-link" href="{% url 'The6ixDjango-home' %}">Home</a> <a class="nav-item nav-link" href="{% url 'The6ixDjango-about' %}">About</a> </div> <!-- Navbar Right Side --> <div class="navbar-nav"> <a class="nav-item nav-link" href="#">Login</a> <a class="nav-item nav-link" href="{% … -
File not in request.FILES but in request.POST I'm using htmx to make post request
I have snippet of inputs that I render to the html page when a condition is met, everythings works appropriately except for the input with type file, I want to upload the files when a change has occured but the file object is not in request.FILES, it's in request.POST now I don't mind it being request.POST but the files is displayed as 'multiple': ['[object File]'] My partial template <div class="my-2"> <div id="uploaded"></div> <p class="lead">{{question.prompt}}</p> <input name="multiple" type="file" accept="image/*, .pdf" id="image_{{question.id}}" {% if question.required %}required{% endif %} {% if question.disabled %}disabled{% endif %} class="form-control" placeholder="{{question.placeholder}}" hx-post="{% url 'survey:file_multiple' %}" hx-trigger="change"> <input type="hidden" name="filemultipleId" value="{% if question.form_input_type == 'file-multiple' %}{{question.id}}{% endif %}"> </div> I am not rendering the form with django form as it will be difficult and near impossible to achieve the dynamicity I am looking for request.POST QueryDict <QueryDict: {'csrfmiddlewaretoken': ['TiLZFEWw88cqItD8MABv6lZKYDrNaVxGF4ZMDOV3sK43540z6uOcrx5uQO6iYldA', 'date': [''], 'dateId': ['20', '5'], 'multiple': ['[object File]'], 'filemultipleId': ['18'], 'fileId': ['17']}> Traceback Internal Server Error: /file-multiple/ Traceback (most recent call last): File "/home/tomms/.local/share/virtualenvs/web-app-QB9eq0sY/lib/python3.9/site-packages/django/utils/datastructures.py", line 83, in __getitem__ list_ = super().__getitem__(key) KeyError: 'multiple' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/tomms/.local/share/virtualenvs/web-app-QB9eq0sY/lib/python3.9/site-packages/django/core/handlers/exception.py", line 47, in inner response = get_response(request) File "/home/tomms/.local/share/virtualenvs/web-app-QB9eq0sY/lib/python3.9/site-packages/django/core/handlers/base.py", line … -
Deploy Django app with Nginx, Gunicorn, uvicorn, PostgreSQL
My app works on development mode (I run from a container with specified variable RTE=dev docker-compose up) I need to deploy the app to my domain and I have all settings in place for it (Nginx, Gunicorn, uvicorn, PostgreSQL). When I docker-compose up in Production mode I do not get any errors and I can't seem to find out where the issue is. settings.py class RuntimeEnvironment(Enum): """docstring: environment variables""" dev = 1 test = 2 prod = 3 RTE = RuntimeEnvironment[os.environ['RTE']] (...) if RTE is RuntimeEnvironment.dev: SECRET_KEY = 'django-insecure-l)lj4%c6(3v5r!0b9eac&0%%_500%ct4x1nbf5j5qsarmtn0#d' else: SECRET_KEY = os.environ['DJANGO_SECRET_KEY'] (...) if RTE is RuntimeEnvironment.dev: DEBUG = True ALLOWED_HOSTS = [] else: DEBUG = False ALLOWED_HOSTS = ['pbstyle.dk', 'https://pbstyle.dk/'] nginx.conf upstream app_upstream { server app:8080; } server { listen 80; listen 443; server_name pbstyle.dk; location /static/ { alias /static/; } location /media/ { alias /media/; } location / { proxy_set_header Host $host; proxy_pass http://app_upstream; } } docker-compose version: "3.8" services: db: image: postgres:13-alpine volumes: - db_data:/var/lib/postgresql/data - ./dbscripts/:/dbscripts/ env_file: - db_${RTE}.env app: build: . ports: - 8000:8000 - 8080:8080 env_file: - db_${RTE}.env volumes: - .:/app/ - static:/static/ - media:/media/ depends_on: - db nginx: build: nginx/ ports: - 443:443 - 80:80 volumes: - ./ngin/${RTE}/conf.d/:/etc/nginx/conf.d/ - ./certs/:/etc/letsencrypt/ - static:/static/ …