Skip to content

Conversation

@PululuK
Copy link
Member

@PululuK PululuK commented Oct 12, 2025

Questions Answers
Description? The Db is droped even the PS_ERASE_DB is setted 0
Type? bug fix
BC breaks? no
Deprecations? no
Fixed ticket?
Sponsor company Evolutive
How to test? Make sure that DB is droped only when PS_ERASE_DB is 0

@github-project-automation github-project-automation bot moved this to Ready for review in PR Dashboard Oct 12, 2025
@nicosomb nicosomb changed the title Fix: The Db is droped even the PS_ERASE_DB is setted 1 Fix: The Db is dropped even the PS_ERASE_DB is setted 1 Oct 13, 2025
@PululuK
Copy link
Member Author

PululuK commented Oct 13, 2025

Hello @Quetzacoalt91
J'espere que ça va :)
C'est assez critique si vous pouvez nous aider pour une release rapidement svp
Merci d'avance

@Quetzacoalt91
Copy link
Member

Hello @PululuK,

Can you please describe what was the issue you're trying to solve?
The title seems logical to me. If you set PS_ERASE_DB as 1, the database will be dropped at the first use of the container.

@PululuK PululuK changed the title Fix: The Db is dropped even the PS_ERASE_DB is setted 1 Fix: The Db is dropped even the PS_ERASE_DB is setted 0 Oct 13, 2025
@PululuK
Copy link
Member Author

PululuK commented Oct 13, 2025

Hello @PululuK,

Can you please describe what was the issue you're trying to solve? The title seems logical to me. If you set PS_ERASE_DB as 1, the database will be dropped at the first use of the container.

oh sorry I just updated

echo "\n* Drop mysql database...";
echo "\n* Dropping existing database $DB_NAME..."
mysql -h $DB_SERVER -P $DB_PORT -u $DB_USER -p$DB_PASSWD -e "drop database if exists $DB_NAME;"
fi
Copy link
Member

Choose a reason for hiding this comment

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

This code was useful even if we did not trigger the auto installation of PrestaShop. Don't you think the parameter --db_clear=$PS_ERASE_DB would be enough here?

Copy link
Member Author

@PululuK PululuK Oct 13, 2025

Choose a reason for hiding this comment

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

@Quetzacoalt91 if you don't need to use the auto installation, in this case you need to adapte your script using post-install-scripts

@PululuK PululuK requested a review from Quetzacoalt91 October 15, 2025 06:17
@SiraDIOP SiraDIOP self-assigned this Oct 16, 2025
@SiraDIOP SiraDIOP removed their assignment Oct 17, 2025
Copy link

@SiraDIOP SiraDIOP left a comment

Choose a reason for hiding this comment

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

Hello @PululuK,

Thanks for your PR,
Could you give us clearer steps on how to test the pr, please?

Thanks

Copy link
Contributor

@tleon tleon left a comment

Choose a reason for hiding this comment

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

Shouldn't you regenerate the base images so they implement your change ?

@SharakPL SharakPL changed the title Fix: The Db is dropped even the PS_ERASE_DB is setted 0 Fix: The Db is dropped even when the PS_ERASE_DB is set to 0 Oct 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Ready for review

Development

Successfully merging this pull request may close these issues.

7 participants