Deploy meteor to bluemix with --settings? - json

I have a JSON file with initial admin user information in it. My startup.js uses that user data to create the first admin user on startup.
When I deploy to meteor, I use meteor deploy --settings settings.json
How can I perform this similarly when deploying to bluemix so I can access my application with my user credentials?

From the Bluemix documentation:
You can specify meteor settings by setting the METEOR_SETTINGS
environment variable:
cf set-env [APP_NAME] METEOR_SETTINGS '{"herp":"derp"}'

Related

Remove App Settings During Azure App Service Deployment

Deploying via Azure Release Pipeline - and in our Deploy Azure App Service step, we set App Service's Application Settings via the
.
Our contingency if the deployment fails, is redeploy an old release (months old) to the same app-service.
However, we need to delete some of the App Service's Application Settings that were set. Just removing these in the old release pipeline does not remove them from the App Service Configuration App Settings section.
Now we don't have the luxury of deleting these app-settings manually on the App Service Configuration.
So what is the recommended way to achieve this through the pipeline?
Remove App Settings During Azure App Service Deployment
You could use the Azure CLI task in the pipeline to delete appsettings, like:
az webapp config appsettings delete --name MyWebApp --resource-group MyResourceGroup --setting-names {setting-names}
Check the az webapp config appsettings delete for some more details.
On the other hard, you also could use API Web Apps - Update Application Settings to delete application settings.
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/appsettings?api-version=2016-08-01
You can check the answer here.
Hope this helps.

WSO2 API manager API not displaying properly

I'm deploying WSO2 API manager 2.6.0 with an external MySQL database and I'm trying to have my API's persist when I change my deployment.
Currently I have 2 deployments using the same external database, one local and the other hosted on an AWS EKS cluster. When I create an API on my local deployment, I can only view it on my AWS deployment if I'm logged in to the store, and visa-versa for my localhost deployment.
The expected and desired behaviour is that all APIs created on both deployments should be displayed on the store no matter if I'm logged in or not, is there any configurations I can change to make the happen?
Here is the doc I used to configure the external database: https://docs.wso2.com/display/AM260/Installing+and+Configuring+the+Databases

Integrating KeyVault access into VSTS Release task

I am trying to figure out what is involved to write a console application that will run as part of a VSTS Release task and that program will read a connection string (secret) from a preconfigured keyvault and then connect to an Azure SQL db using that connection string and apply some changes.
Currently I have my Web Apps connecting to KeyVault and the Azure SQL Server
using Azure AD Application Token authentication so I know what is involved on that front.
When you check "Allow scripts to access OAuth token" on agent settings page,
can this token be used (using ADAL) to connect to KeyVault and SQL Server.
(Assuming the VisualStudioSPNxxx has the appropriate access to the above resources).
If not what should I be looking for?
The vsts token (Allow scripts to access OAuth token) can’t be used to connect to KeyVault.
You need to register app with Azure Active Directory and enable to communicate with Azure Active Directory and Key Vault, then get the connectionstring dynamically.
More information, you can refer to: Protecting Secrets using VSTS and Azure Key Vault
This is made relatively very easy now with Variable Groups - https://learn.microsoft.com/en-us/vsts/pipelines/library/variable-groups?view=vsts
You can link a secret by connecting your Azure KV to a variable and then use this variable as you would normally use it in any script/task.

How to obtain service credentials for a service instance created on IBM Bluemix without binding the instance to an application on Bluemix?

I have created a ClearDB MySQL instance on IBM Bluemix. Can I see the credentials (hostname, username, password etc) without binding the instance to an application running on Bluemix ?
Thank you, Sandhya
It depends if the service provider implemented the Service Keys feature. If they have, you can generate new credentials by clicking on "Service Credentials" on the service dashboard page.
The ClearDB currently requires you to bind it to a Cloud Foundry application for service credentials.

No environment variables in OpenShift

I have created a new OpenShift account for a new application I'm developing.
I have added a MongoDB cartridge for the database, and a Tomcat cartridge for the Java web application.
I now need to connect to the database from my Java web app, but I miss two authentication details:
$OPENSHIFT_MONGODB_DB_HOST
$OPENSHIFT_MONGODB_DB_PORT
As far as I know, I have to type rhc env list -a the_name_of_my_app in the console, but my application seems to have no environment variables set.
What can I do?
Apparently, the default enironment variables are visible only via ssh.
In order to see them, you have to type rhc ssh <appid-as-seen-on-openshift-console> followeb by env.
you can see environment variables by doing ssh to openshift. Also you can use openshift port forwarding feature to setup a connection locally to your database.
Openshift blog link for port forwarding