limited-rainbow-51650
03/01/2021, 8:52 AMpulumi-up
is not in the same VPC as the DB setup, so we want to integrate cloud_sql_proxy
in our code setup. Starting the proxy via NodeJS child_process
works, but we are searching the correct place in our code to stop the proxy after the mysql.Grant
resources have been created/updated:
const ddl = new mysql.Grant(
config.dbDDLUsername,
{
user: DDLUser.name,
database: database.name,
privileges: ["CREATE", "ALTER", "DROP"],
host: "%",
},
{
provider: mysqlProvider
}
);
const dml = new mysql.Grant(
config.dbDMLUsername,
{
user: DMLUser.name,
database: database.name,
privileges: ["UPDATE", "INSERT", "SELECT", "INDEX", "DELETE"],
host: "%",
},
{
provider: mysqlProvider
}
);
pulumi.all([ddl.id, dml.id]).apply(async () => {
console.log(`>>>>> Killing cloud_sql_proxy... <<<<<`);
sqlProxyProcess.kill();
});
Pulumi is hanging now and is not killing the child process. Any ideas?No matter how you like to participate in developer communities, Pulumi wants to meet you there. If you want to meet other Pulumi users to share use-cases and best practices, contribute code or documentation, see us at an event, or just tell a story about something cool you did with Pulumi, you are part of our community.
Powered by