I am new to WSO2. According to prerequisites I have created the environment(Done JAVA_HOME & Done Maven Path too),I am getting a message like below. The message is like
D:\...\bin>wso2server.bat
CARBON_HOME is set incorrectly or CARBON could not be located. Please set CARBON_HOME.
How can I set the CARBON_HOME correctly ?
C:\Users\Ganesh>set JAVA_HOME
JAVA_HOME=C:\Program Files\Java\jdk1.7.0_67
Just download the wso2ei file from here
https://github.com/wso2/product-ei/releases/download/v6.4.0-m7/wso2ei-6.4.0-m7.zip
Unzip it
let your path of wso2ei is D:\WSO2Learning\wso2ei-6.4.0-m7
Set variable name as CARBON_HOME
and variable value as D:\WSO2Learning\wso2ei-6.4.0-m7
Open a new command prompt D:\WSO2Learning\wso2ei-6.4.0-m7\bin
then type integrator.bat and hit enter.
Related
I am using WSO2 Integration Studio 8.1.0 on Windows 10 and I have Ant installed (Apache Ant 1.10.12) and added the ANT bin directory (ANT_HOME) to the path system variable.
In my deployment.toml file which is located in Integration_Studio_Home\runtime\microesb\conf.
I added the following under the secrets header
[secrets]
admin_password = "adminUserPassword"
Then opened cmd and navigated to Integration_Studio_Home\runtime\microesb\bin.
Then executed ciphertool.bat -Dconfigure
Result :
.\wso2\lib\Saxon-HE-9.5.1-8.jar
Using CARBON_HOME: C:\WSO2\INTEGR~1\runtime\microesb\bin\..
Using JAVA_HOME: C:\Program Files\Java\jdk-11.0.12
Encrypting using Internal KeyStore.
{type: JKS, alias: wso2carbon, path: repository/resources/security/wso2carbon.jks}
[Please Enter Internal KeyStore Password of Carbon Server : ]
Internal KeyStore of Carbon Server is initialized Successfully
Secret Configurations are written to the property file successfully
But when I open deployment.toml I find that the password under the secrets section is not encrypted!
You need to define the secret value between square brackets []. In your case, it should be as follows,
[secrets]
admin_password = "[adminUserPassword]"
Furthermore, if you are using the embedded MI runtime, you can use the Integration Studio itself to encrypt the secrets. Have a look at Encrypt static (embedded) server secrets
For more info check,
Defining secrets - https://apim.docs.wso2.com/en/latest/install-and-setup/setup/mi-setup/security/encrypting_plain_text/#static-secrets
I've installed Wso2 Api Manager a few days ago follow this intructions:
1. I've downloaded https://wso2.com/api-management/install.
2. I've installed using the wizard in C:\Program Files\WSO2\API Manager directory.
3. I've initialize Api Manger console, then created some apis from https://localhost:9443/publisher .
Now, I want to see some statistics (https://192.168.138.117:9443/publisher/site/pages/all-statistics.jag?page=api-usage-user&stat=all-stat). I've read that API Analytics has to be configured, so I carried out the following steps (https://docs.wso2.com/display/AM260/Configuring+APIM+Analytics#ConfiguringAPIMAnalytics-Step1-DownloadandinstallWSO2API-M).
I download it (https://wso2.com/api-management/install/analytics).
Unzip file in C:\WSO2\wso2am-analytics-2.6.0.
I've created and Environment Variables called JAVA_HOME. In value field, I typed the installation path of the Java Development Kit, C:\Program Files\Java\jdk1.8.0_191.
I edited the tag true in the file "C:\Program Files\WSO2\API Manager\2.6.0\repository\conf\api-manager.xml".
I exec this command in cmd windows: "C:\WSO2\wso2am-analytics-2.6.0>worker.bat -run". It excecuted some process and aparentely everything was ok.
Finally, I run another windows console and exec: "C:\Program Files\WSO2\API Manager\2.6.0\bin>wso2server.bat -run".
Now, when I try to log in https://localhost:9443/publisher, /store o /carbon, I'm getting this error:
Problem accessing: /. Reason: Not Found
If I only lunch the Api Manager, it works perfectly but I can't get the statistics.
Did you follow Quick setup?
To access Analytics you need to carry out Standard Setup which includes:
Creating Analytics DB with the "am_usage_uploaded_files" table in addition
Configuring /conf/dashboard/deployment.yaml --> APIM_ANALYTICS_DB
Configuring /conf/worker/deployment.yaml --> APIM_ANALYTICS_DB
Configure /conf/worker/deployment.yaml --> WSO2AM_MGW_ANALYTICS_DB
And then starting the worker which creates the rest tables for analytics.
Hi Jenkins and AWS Guru's
I already look online for any possible solutions but not getting a solution for my problem. I just issued an "eb --version" on Jenkins execute shell under a test project but getting "eb: command not found" during the execution.
Wierd thing is if I issue the same command on the Jenkins box via CLI I'm getting a good response from it. Any suggestions for the fix please? thanks in advance
Your Jenkins setup has a different path than the user you logged in with.
There are two solutions:
Add the path to the executable in the PATH environment variable. Use where eb to find the correct path. Then in Jenkins, click on
Manage Jenkins -> Configure System, Global Properties. Check Environment Variables. Set Name to PATH. Set Value to $PATH:/path/to/eb. Then restart Jenkins.
Call the eb command with its fully qualified path.
EDIT: Added steps to update path in Jenkins.
this is now fixed, need to create a properties file that was basically a copy of /var/lib/jenkins/.bash_profile file which would have the correct paths and add that in Jenkins settings. Allowing it to get the required paths. After properties file is created you need to set it on Jenkins-Configure section, Place a check on Prepare jobs environment then set the full path of the properties file (/var/lib/jenkins/environment_variables.properties) on the Properties File Path and restart Jenkins
Here's what I'm working with right now:
Ubuntu Trusty 14.04
Rails 4.2.6
Ruby 2.2.3
Passenger
Nginx
When I try to visit the IP I get this message:
Incomplete response received from application
When I look at nginx/error.log I see:
Missing `secret_token` and `secret_key_base` for 'production' environment, set these values in `config/secrets.yml`
On the server I did:
RAILS_ENV=production bundle exec rake secret
I placed that result into each of these files for good measure:
~/.bashrc
~/.bash_profile
~/.profile
/app/shared/config/local_env.yml
For all shell scripts the format is:
export SECRET_KEY_BASE="[key]"
For the local_env.yml I used just:
SECRET_KEY_BASE="[key]"
I've also tried entering it without quotation marks.
I've restarted the server each time I made a change. No cigar.
What else might be the issue?
-- UPDATE
I've even added the secret key to the secrets.yml file directly. So now I'm thinking my issue is either something to do with passenger/nginx or with a typo somewhere.
It is more likely that the environment variables are not actually set rather than Rails is not picking them up. You're raking secrets, which I don't do. I set them up manually in the Unix etc/environment, and do not check any secrets into source control. But the following are a few steps that should help you either resolve or hone in on the problem.
On your Ubuntu server for system wide environment variables
1- $env
Look for your SECRET_TOKEN and SECRET_KEY_BASE. The error tells you that these are not set, this is just a technique to check env. (RAILS_ENV will also be shown in the list if it is set.)
2- $sudo nano /etc/environment
Add the following lines -- use your actual values between double quotes. Do not use a [key] or any programmatic replacement.
export SECRET_TOKEN="T99ABC..."
export SECRET_KEY_BASE="99ABC..."
3- $logout / $login to reload environment vars
4- $env - Check the environment again
Look for your SECRET_TOKEN and SECRET_KEY_BASE to be set.
5- Try deploying again. If it fails, check the environment vars using $env again. It will tell you if something in your deploy is smashing your SECRET_* env vars.
My rails application is running in 3 servers namely [testing.example.com, staging.example.com, example.com] Whenever sending email, I have set host option with 'liverserver_url' for default_url_options in production.rb. I need to get system environment variable to set host option dynamically. how to do that. How to get system environment variable in rails application.
export MAIL_HOST='your_url'
Add below line to /etc/environment file
MAIL_HOST='your_url' and restart the machine.
you can access ENV['MAIL_HOST'] in rails application anywhere.
You can get environment from next variables
ENV["RAILS_ENV"]
ENV["RAKE_ENV"]
Rails.env
But you have to configure your server for using production.rb staging.rb and another environment file in your config directory and then configure specific environment.