Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
GÉANT Service Orchestrator
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
GÉANT Orchestration and Automation Team
GAP
GÉANT Service Orchestrator
Merge requests
!408
Feature/update v3 migrations
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Feature/update v3 migrations
feature/update-v3-migrations
into
develop
Overview
0
Commits
2
Pipelines
1
Changes
1
Merged
Karel van Klink
requested to merge
feature/update-v3-migrations
into
develop
2 months ago
Overview
0
Commits
2
Pipelines
1
Changes
1
Expand
Update and add one migration for migrating to v3
0
0
Merge request reports
Viewing commit
66028d2e
Prev
Next
Show latest version
1 file
+
38
−
0
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Verified
66028d2e
Add a migration to clean up IP Trunk subscription descriptions
· 66028d2e
Karel van Klink
authored
2 months ago
gso/migrations/versions/2025-04-18_fffe36624681_update_ip_trunk_descriptions.py
0 → 100644
+
38
−
0
Options
"""
Update IP Trunk descriptions.
Removes an outdated to `geant_s_sid` in IP Trunk descriptions. This field has been renamed and adds unnecessary clutter
to the description field.
Revision ID: fffe36624681
Revises: c38adde1a18e
Create Date: 2025-04-18 09:41:28.463681
"""
import
sqlalchemy
as
sa
from
alembic
import
op
# revision identifiers, used by Alembic.
revision
=
'
fffe36624681
'
down_revision
=
'
c38adde1a18e
'
branch_labels
=
None
depends_on
=
None
def
upgrade
()
->
None
:
conn
=
op
.
get_bind
()
conn
.
execute
(
sa
.
text
(
"""
UPDATE subscriptions
SET description = Replace(description,
'
geant_s_sid:
'
,
''
)
WHERE product_id = (SELECT product_id
FROM products p
WHERE p.tag =
'
IPTRUNK
'
);
"""
)
)
def
downgrade
()
->
None
:
# Do nothing
pass
Loading