Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

atlasaction: initial bitbucket pipe #267

Merged
merged 3 commits into from
Dec 11, 2024
Merged

atlasaction: initial bitbucket pipe #267

merged 3 commits into from
Dec 11, 2024

Conversation

giautm
Copy link
Member

@giautm giautm commented Dec 5, 2024

  • chore: cleanup action options
  • atlasaction: initial bitbucket pipe

Copy link

github-actions bot commented Dec 5, 2024

Atlas Lint Report

Analyzed migrations2

StatusStepResultDiagnostics
Detect New Migration FilesFound 0 new migration files (from 0 total)
Replay Migration FilesLoaded 0 changes on dev database
Connect your project to Atlas Cloud to get more safety checks

Migrations automatically reviewed by Atlas

Copy link

github-actions bot commented Dec 5, 2024

atlas migrate lint on atlasaction/testdata/migrations_destructive

Status Step Result
1 new migration file detected 20230925192914.sql
ERD and visual diff generated View Visualization
Analyze 20230925192914.sql
1 reports were found in analysis
Destructive changes detected
Dropping table "t1" (DS102)
Read the full linting report on Atlas Cloud

Copy link

github-actions bot commented Dec 5, 2024

Atlas Lint Report

Analyzed migrations

StatusStepResultDiagnostics
Detect New Migration FilesFound 0 new migration files (from 0 total)
Replay Migration FilesLoaded 0 changes on dev database
Connect your project to Atlas Cloud to get more safety checks

Migrations automatically reviewed by Atlas

@giautm giautm marked this pull request as draft December 5, 2024 14:39
Copy link

github-actions bot commented Dec 5, 2024

Atlas detected changes to the desired schema

Migration Plan (View on Atlas Cloud)

-- Create "t1" table
CREATE TABLE `t1` (
  `c1` integer NOT NULL
);
-- Create "t2" table
CREATE TABLE `t2` (
  `c1` integer NOT NULL
);
-- Create "t3" table
CREATE TABLE `t3` (
  `c1` integer NOT NULL,
  `c2` integer NOT NULL
);

Atlas lint results

Status Step Result
Detect schema changes3 new statements detected
No issues found

📝 Steps to edit this migration plan

1. Run the following command to pull the generated plan to your local workstation:

atlas schema plan pull --url "atlas://atlas-action/plans/pr-266-R1cGcSfo" > pr-266-R1cGcSfo.plan.hcl

2. Open pr-266-R1cGcSfo in your editor and modify it as needed. Note that the result of the plan should align
the database with the desired state. Otherwise, Atlas will report a schema drift.

3. Push the updated plan to the registry using the following command:

atlas schema plan push --pending --env test --file pr-266-R1cGcSfo.plan.hcl

4. Re-trigger the schema/plan action to update this comment:

gh run rerun 12184377066

@giautm giautm changed the title g/bitbucket atlasaction: initial bitbucket pipe Dec 5, 2024
@giautm giautm force-pushed the g/bitbucket branch 2 times, most recently from 505a836 to 2473f0c Compare December 6, 2024 07:13
Copy link

github-actions bot commented Dec 6, 2024

Atlas detected changes to the desired schema

Migration Plan (View on Atlas Cloud)

-- Create "t1" table
CREATE TABLE `t1` (
  `c1` integer NOT NULL
);
-- Create "t2" table
CREATE TABLE `t2` (
  `c1` integer NOT NULL
);
-- Create "t3" table
CREATE TABLE `t3` (
  `c1` integer NOT NULL,
  `c2` integer NOT NULL
);

Atlas lint results

Status Step Result
Detect schema changes3 new statements detected
No issues found

📝 Steps to edit this migration plan

1. Run the following command to pull the generated plan to your local workstation:

atlas schema plan pull --url "atlas://atlas-action/plans/pr-267-R1cGcSfo" > pr-267-R1cGcSfo.plan.hcl

2. Open pr-267-R1cGcSfo in your editor and modify it as needed. Note that the result of the plan should align
the database with the desired state. Otherwise, Atlas will report a schema drift.

3. Push the updated plan to the registry using the following command:

atlas schema plan push --pending --env test --file pr-267-R1cGcSfo.plan.hcl

4. Re-trigger the schema/plan action to update this comment:

gh run rerun 12278605615

@giautm giautm force-pushed the g/bitbucket branch 10 times, most recently from c01f7a5 to c0e568b Compare December 11, 2024 13:48
@giautm giautm marked this pull request as ready for review December 11, 2024 14:24
Copy link
Member

@noamcattan noamcattan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@giautm giautm merged commit 01370fa into master Dec 11, 2024
20 checks passed
@giautm giautm deleted the g/bitbucket branch December 11, 2024 14:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants