-
Notifications
You must be signed in to change notification settings - Fork 81
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #925 from daviddavis/fix911
Serve previously published artifacts for up to 3 days
- Loading branch information
Showing
5 changed files
with
187 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
Added feature to serve published artifacts from previous publications for 3 days. | ||
This fulfills the apt-by-hash/acquire-by-hash spec by allowing by-hash files to be cached for a | ||
period of 3 days. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# Generated by Django 4.2.2 on 2024-01-03 18:58 | ||
|
||
from django.db import migrations, models | ||
import django.db.models.deletion | ||
import django_lifecycle.mixins | ||
import pulpcore.app.models.base | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
("core", "0114_remove_task_args_remove_task_kwargs"), | ||
("deb", "0028_sourcepackage_sourcepackagereleasecomponent_and_more"), | ||
] | ||
|
||
operations = [ | ||
migrations.CreateModel( | ||
name="DistributedPublication", | ||
fields=[ | ||
( | ||
"pulp_id", | ||
models.UUIDField( | ||
default=pulpcore.app.models.base.pulp_uuid, | ||
editable=False, | ||
primary_key=True, | ||
serialize=False, | ||
), | ||
), | ||
("pulp_created", models.DateTimeField(auto_now_add=True)), | ||
("pulp_last_updated", models.DateTimeField(auto_now=True, null=True)), | ||
("expires_at", models.DateTimeField(null=True)), | ||
( | ||
"distribution", | ||
models.ForeignKey( | ||
on_delete=django.db.models.deletion.CASCADE, to="core.distribution" | ||
), | ||
), | ||
( | ||
"publication", | ||
models.ForeignKey( | ||
on_delete=django.db.models.deletion.CASCADE, to="core.publication" | ||
), | ||
), | ||
], | ||
options={ | ||
"abstract": False, | ||
}, | ||
bases=(django_lifecycle.mixins.LifecycleModelMixin, models.Model), | ||
), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters