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

feat(function): add mysql example in PHP #89

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

cyclimse
Copy link
Contributor

Summary

A small example of connecting a PHP function to a MySQL DB.

Checklist

  • I have reviewed this myself.
  • [ x] I have attached a README to my example. You can use this template as reference.
  • I have updated the project README to link my example.

Details

1. Make sure to create a user as well.
2. Create a new function namespace and a PHP function running using PHP 8.2
3. Copy the contents of `handler.php` into the function code editor.
4. Add the following environment variables to the function:
Copy link
Contributor

Choose a reason for hiding this comment

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

issue(credentials): use a secret for MYSQL_PASSWORD


## Deploying

1. Create a MySQL database from the Scaleway console.
Copy link
Contributor

Choose a reason for hiding this comment

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

suggestion(usability): add link to rdb page in console

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