File tree Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -94,12 +94,14 @@ Install `jq`. On MacOS, you can use following [brew formulae](https://formulae.b
9494* Create the service credential to access the PostgreSQL instance
9595 ```
9696 SM_SECRET_FOR_PG_NAME=pg-access-credentials
97- ibmcloud secrets-manager secret-create \
97+ ibmcloud secrets-manager config set instance-id $SM_INSTANCE_GUID
98+ ibmcloud secrets-manager config set region $REGION
99+ ibmcloud secrets-manager config set service-url https://$SM_INSTANCE_GUID.$REGION.secrets-manager.appdomain.cloud
100+ SM_SECRET_FOR_PG_ID=$(ibmcloud secrets-manager secret-create \
98101 --secret-type="service_credentials" \
99102 --secret-name="$SM_SECRET_FOR_PG_NAME" \
100- --secret-source-service="{\"instance\": {\"crn\": \"$DB_INSTANCE_ID\"},\"parameters\": {},\"role\": {\"crn\": \"crn:v1:bluemix:public:iam::::serviceRole:Writer\"}}"
101-
102- SM_SECRET_FOR_PG_ID=$(ibmcloud sm secret-by-name --name $SM_SECRET_FOR_PG_NAME --secret-type service_credentials --secret-group-name default --instance-id $SM_INSTANCE_GUID --region $REGION --output JSON|jq -r '.id')
103+ --secret-source-service="{\"instance\": {\"crn\": \"$DB_INSTANCE_ID\"},\"parameters\": {},\"role\": {\"crn\": \"crn:v1:bluemix:public:iam::::serviceRole:Writer\"}}" \
104+ --output JSON|jq -r '.id')
103105 ```
104106
105107* Create the Code Engine app:
Original file line number Diff line number Diff line change @@ -113,7 +113,7 @@ export function deleteUsers(client) {
113113 const startTime = Date . now ( ) ;
114114 console . log ( `${ fn } >` ) ;
115115 return new Promise ( function ( resolve , reject ) {
116- const queryText = "DROP TABLE users" ;
116+ const queryText = "DELETE * FROM users" ;
117117 client . query ( queryText , undefined , function ( error , result ) {
118118 if ( error ) {
119119 console . log ( `${ fn } < failed - error: ${ error } ; duration ${ Date . now ( ) - startTime } ms` ) ;
You can’t perform that action at this time.
0 commit comments