environment variables - Raspberry Pi Qt5 Set physical screen size

I am developping a qt5 application on my raspberry pi on raspbian using cross compilation.When I run it, I get a black screen trying display a Pop-up which is a QFrame.I suppose that it cannot be positioned because I have error messages arriving at the beginning : EGLFS: Unable to query physical screen size, defaulting to 100 dpi. EGLFS: To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters). EGLFS: Unable to query screen depth, defaulting to 32. EGLFS: To override, set QT_QPA_EGLFS_DEPTH.When ...Read more

How To evaluate Kubernetes Environment Variables

I have a web application that has a server side UI component that needs to talk to another component which exposes a REST interface. The UI needs to know the address of the endpoint that the REST component exposes.When the UI starts, I set an environment variable ( ADDRESS_SERVICE_URI ) that contains the REST endpoint host and port.I now want to deploy this application into Kubernetes, but I want to do it in a way that does not enforce any dependency in the application code on Kubernetes. I was hoping to use the environment variables that Kuber...Read more

environment variables - Sublime Text 2: custom PATH and PYTHONPATH

I'm using brew which installs python (2.7.2) in /usr/local/bin/However, the default system python (2.7.1) is executed instead at /usr/bin/, which seems to be because it doesn't obey any of the bash PATH environment variables.Also, it can't find my modules, as they are installed at /usr/local/lib/python:/usr/local/Cellar/python/2.7.2/lib/python2.7/site-packages.I've been trying the following with Python.sublime-settings, but it doesn't work:{"path": "/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin","env": ["PYTHONPATH", "/usr/local/lib/python:/usr/...Read more

osx mavericks - Where are XCode 3 environment variables defined?

On my Mac OS 10.9.3, I have a C++ XCode 3 project on which, I don't know where, an environment variable is set (say MYVAR). I can see it when I launch a build in a command line using xcodebuild from my terminal, in the output:...setenv MYVAR "My Value"...This variable is absolutely unset from all my global environment variables of my OS (.bashprofile, .profile, launchd.conf, profile, .bashrc, etc.) . When I type echo $MYVARin a terminal, it displays an empty result.So, where can be this variable defined? I searched in Source tree variables, in ...Read more

How to set environment variable in pre-start in Upstart script?

We have a custom C++ daemon application that forks once. So we've been doing this in our Upstart script on Ubuntu 12.04 and it works perfectly:expect forkexec /path/to/the/appHowever now we need to pass in an argument to our app which contains the number of CPUs on the machine on which it runs:cat /proc/cpuinfo | grep processor | wc -lOur first attempt was this:expect forkexec /path/to/the/app -t `cat /proc/cpuinfo | grep processor | wc -l`While that starts our app with the correct -t value, Upstart tracks the wrong pid value, I'm assuming beca...Read more

Capistrano: Can I set an environment variable for the whole cap session?

I've got a staging server with both standard Ruby and Ruby Enterprise installed. As standard Ruby refuses to install a critical gem, I need to set $PATH so that ruby/gem/rake/etc. always refer to the REE versions. And since I use Capistrano to deploy to our machines, I need to do it in Capistrano.How can I set an environment variable once, and have it persist throughout the Capistrano session?1) It's easy to do in bashrc files, but Capistrano doesn't read bashrc files.2) I'd use Capistrano'sdefault_environment['PATH'] = 'Whatever'but Capistra...Read more

How to define environment variable when running a compiled program with scons

I did write my SConstruct file so I build and run the program by doing scons runprogram = env.Program('build/output', Glob('build/test/*.cpp'))env.Default(program)env.Alias('run', program, program[0].abspath)I can compile my program and run it without problem, but when I try to use glut and opengl in my program, I have the following error: /home/tran/workspace/bobail/build/test/test freeglut (/home/tran/workspace/bobail/build/test/test): failed to open display ''After some search I found out that my compiled program need the environment varia...Read more

environment variables - Can't get to exec one makefile in another one

Some background: I have a project based on ESP-IDF which has a complex builtin building system which you plug into with your own makefile (their documentation on using it).This works fine (apart from occasional horrendous build times), but now I wanted to add a build target for unit tests for a component, which requires building this component against another project (the unit-test-app).So, I need another build target that calls another make with another makefile and directory. Something like this works fine:make -C $(path to unit-test-app) ...Read more

environment variables - What is the difference between "system32\java.exe" and "Program Files\Java\jdk1.6.0_33\bin\java.exe"?

I have just installed Java JDK 6u33 in Windows XP. Even though I didn't set the PATH environment variable, I am able to run java -version in command prompt.When I run this command for %i in (java.exe) do @echo. %~$PATH:i, I get this output:C:\WINDOWS\system32\java.exeWhen I check my PC, I found that there are 2 java.exe:1. C:\Program Files\Java\jdk1.6.0_33\bin\java.exe2. C:\WINDOWS\system32\java.exeMay I know what is the difference between system32\java.exe and Program Files\Java\jdk1.6.0_33\bin\java.exe? Why only system32\java.exe is shown w...Read more

supervisord - Supervisor and Environment Variables

I really don't know how to get supervisor to work with environment variables.Below is a configuration snippet.[program:htNotificationService]priority=2#autostart=true#autorestart=truedirectory=/home/ubuntu/workspace/htFrontEnd/heythat/htsitecommand = /usr/bin/python htNotificationService.py -servicestdout_logfile=/var/log/heythat/htNotificationService.logredirect_stderr=trueenvironment=PATH=/home/ubuntu/workspace/htFrontEnd/heythatstopsignal=QUITI have tried the following:environment=PATH=/home/ubuntu/workspace/htFrontEnd/heythatenvironment=PYT...Read more

environment variables - How to deploy a Serverless function using Gitlab CI?

I'm trying to deploy my Serverless function using a .gitlab-ci.yml file, and to inject environment variables into my function I'm using this format in my serverless.yml file:${file(./serverless.env.yml):${opt:stage, 'dev'}.VARIABLE_1_KEY}My serverless.env.yml file looks something like this:staging: VARIABLE_1_KEY: xxxxxxx VARIABLE_2_KEY: xxxxxxx SUBNET_IDS: - xxxxxx - xxxxxxproduction: VARIABLE_1_KEY: xxxxxxx VARAIBLE_2_KEY: xxxxxxx SUBNET_IDS: - xxxxxx - xxxxxxMy issue is that I'm not committing my serverless.env.yml file, wh...Read more

environment variables - Compose env vars in from configmap

I'd like to set logging level in my Wildfly Swarm app build on top of registry.access.redhat.com/redhat-openjdk-18/openjdk18-openshift image. The way to configure the app is through env var JAVA_OPTIONS, therefore I'd like to useenv:- name: LOG_LEVEL valueFrom: configMapKeyRef: name: my.configmap key: log.level- name: JAVA_OPTIONS value: -Dswarm.logging=$LOG_LEVELRegrettably (but not really to my surprise) this doesn't work, the LOG_LEVEL is not resolved.Is there a way to compose env vars from config map or do I have to modify th...Read more

How can I add private information to OpenShift environment variables?

Authentication information such as database connection strings or passwords should almost never be stored in version control systems.It looks like the only method of specifying environment variables for an app hosted on OpenShift is to commit them to the Git repository. There is a discussion about this on the OpenShift forums, but no useful suggested workarounds for the problem. Is there another approach I can use to add authentication information to my app without having to commit it to the repository?...Read more

openshift - developing several projects locally: How to configure environment variables

let's say I am developing 2 applications for 2 different clients which are, using 2 different database-configurations.When using Openshift and CakePHP it is considered good practise to not store the real connection-info in the configs, but instead to use environment-variables.That way the GIT-Repo is also always clean of server-specific stuff.That is all fine as long as I have ONE project but as soon as there is another one, I need to override my local env-vars according to the current project.Is there any way to avoid this? Is it possible to s...Read more

Environment variable not expanding in openshift

It seems that if I use a command like:rhc env set VARIABLE="$OPENSHIFT_DATA_DIR/file"the referenced directory variable is never expanded and as a result I can not use it for my app. Is there any way to fix this?EDITAs noted by @timo.rieber in his answer, this is not going to work because the variable is resolved locally, where it has no value. In fact:$ rhc env set VARIABLE="$OPENSHIFT_DATA_DIR/file"Setting environment variable(s) ... done$ rhc env show VARIABLEVARIABLE=/fileHowever, if I use single quotes to avoid immediate expansion:$ rhc env...Read more