mirror of
https://github.com/Crocmagnon/checkout.git
synced 2024-11-21 15:48:02 +01:00
Compile messages at build time
This commit is contained in:
parent
6aee5a3b7b
commit
ea8f76db2d
3 changed files with 152 additions and 1 deletions
|
@ -19,6 +19,7 @@ RUN python -m venv --copies /app/venv \
|
|||
ENV PATH /app/venv/bin:$PATH
|
||||
COPY src ./src/
|
||||
RUN python ./src/manage.py collectstatic --no-input
|
||||
RUN python ./src/manage.py compilemessages -l fr -l en
|
||||
|
||||
## Get git versions
|
||||
FROM alpine/git AS git
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
#!/bin/bash
|
||||
set -eux
|
||||
python manage.py migrate --noinput
|
||||
python manage.py compilemessages -l en -l fr
|
||||
gunicorn checkout.wsgi -b 0.0.0.0:8000 --log-file -
|
||||
|
|
|
@ -0,0 +1,151 @@
|
|||
# Generated by Django 4.0.4 on 2022-04-26 18:18
|
||||
|
||||
import django.db.models.deletion
|
||||
from django.db import migrations, models
|
||||
|
||||
import purchase.models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
("purchase", "0004_remove_basket_status"),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AlterModelOptions(
|
||||
name="basket",
|
||||
options={"verbose_name": "basket", "verbose_name_plural": "baskets"},
|
||||
),
|
||||
migrations.AlterModelOptions(
|
||||
name="basketitem",
|
||||
options={
|
||||
"verbose_name": "basket item",
|
||||
"verbose_name_plural": "basket items",
|
||||
},
|
||||
),
|
||||
migrations.AlterModelOptions(
|
||||
name="paymentmethod",
|
||||
options={
|
||||
"verbose_name": "payment method",
|
||||
"verbose_name_plural": "payment methods",
|
||||
},
|
||||
),
|
||||
migrations.AlterModelOptions(
|
||||
name="product",
|
||||
options={
|
||||
"ordering": ["display_order", "name"],
|
||||
"verbose_name": "product",
|
||||
"verbose_name_plural": "products",
|
||||
},
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="basket",
|
||||
name="created_at",
|
||||
field=models.DateTimeField(auto_now_add=True, verbose_name="created at"),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="basket",
|
||||
name="payment_method",
|
||||
field=models.ForeignKey(
|
||||
blank=True,
|
||||
null=True,
|
||||
on_delete=django.db.models.deletion.PROTECT,
|
||||
related_name="baskets",
|
||||
to="purchase.paymentmethod",
|
||||
verbose_name="payment method",
|
||||
),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="basket",
|
||||
name="updated_at",
|
||||
field=models.DateTimeField(auto_now=True, verbose_name="updated at"),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="basketitem",
|
||||
name="basket",
|
||||
field=models.ForeignKey(
|
||||
on_delete=django.db.models.deletion.CASCADE,
|
||||
related_name="items",
|
||||
to="purchase.basket",
|
||||
verbose_name="basket",
|
||||
),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="basketitem",
|
||||
name="created_at",
|
||||
field=models.DateTimeField(auto_now_add=True, verbose_name="created at"),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="basketitem",
|
||||
name="product",
|
||||
field=models.ForeignKey(
|
||||
on_delete=django.db.models.deletion.PROTECT,
|
||||
related_name="basket_items",
|
||||
to="purchase.product",
|
||||
verbose_name="product",
|
||||
),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="basketitem",
|
||||
name="quantity",
|
||||
field=models.PositiveIntegerField(verbose_name="quantity"),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="basketitem",
|
||||
name="updated_at",
|
||||
field=models.DateTimeField(auto_now=True, verbose_name="updated at"),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="paymentmethod",
|
||||
name="created_at",
|
||||
field=models.DateTimeField(auto_now_add=True, verbose_name="created at"),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="paymentmethod",
|
||||
name="name",
|
||||
field=models.CharField(max_length=50, unique=True, verbose_name="name"),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="paymentmethod",
|
||||
name="updated_at",
|
||||
field=models.DateTimeField(auto_now=True, verbose_name="updated at"),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="product",
|
||||
name="created_at",
|
||||
field=models.DateTimeField(auto_now_add=True, verbose_name="created at"),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="product",
|
||||
name="display_order",
|
||||
field=models.PositiveIntegerField(
|
||||
default=purchase.models.default_product_display_order,
|
||||
verbose_name="display order",
|
||||
),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="product",
|
||||
name="image",
|
||||
field=models.ImageField(
|
||||
blank=True, null=True, upload_to="", verbose_name="image"
|
||||
),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="product",
|
||||
name="name",
|
||||
field=models.CharField(max_length=250, unique=True, verbose_name="name"),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="product",
|
||||
name="unit_price_cents",
|
||||
field=models.PositiveIntegerField(
|
||||
help_text="unit price in cents", verbose_name="unit price (cents)"
|
||||
),
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name="product",
|
||||
name="updated_at",
|
||||
field=models.DateTimeField(auto_now=True, verbose_name="updated at"),
|
||||
),
|
||||
]
|
Loading…
Reference in a new issue