Questions tagged [environment-variables]

Environment variables are a set of dynamic named values that can affect the way running processes will behave on a computer.

Environment variables are a set of dynamic-named values that can affect the way running processes will behave on a computer. They can be said in some sense to create the operating environment in which a process runs. For example, an environment variable with a standard name can store the location that a particular computer system uses to store temporary files—this may vary from one computer system to another. A process which invokes the environment variable by (standard) name can be sure that it is storing temporary information in a directory that exists and is expected to have sufficient space.

https://en.wikipedia.org/wiki/Environment_variable

13704 questions
6
votes
1 answer

Bitbucket pipelines: echo environment variable

I have a very simple pipeline for the tags. When I do the tag, I want to send simple slack webhook. My issue is that environment variable $BITBUCKET_TAG is not rendered neither in echo nor in slack message. pipelines: tags: '*': - step: …
walv
  • 2,680
  • 3
  • 31
  • 36
6
votes
1 answer

MySQL: Use environment variables in script

Is it possible to make a sql script use a variable defined externally? E.g. I have the following script: UPDATE mytable SET valid = 0 WHERE valid = 1 which I have to run through mysql command line several times, each with a different table…
Don
  • 16,928
  • 12
  • 63
  • 101
6
votes
2 answers

How to deal with secrets in app.yaml and not putting it in GIT?

Google Cloud Platform doesn't describe how to deal with environmental variables in your app.yaml. Starting up with GCP and Google App Engine, I read about setting my config variables in app.yaml which makes sense in a way, but I don't want to put my…
HJW
  • 342
  • 3
  • 13
6
votes
2 answers

VS Code doesn't use pipenv .env file

Working with VS Code 1.35.1 on ubuntu 16.04 with a Python 3.7.3 pipenv virtual environment, I am trying to set environment variables in a .env file, but for some reason the file doesn't seem to be recognized. Can someone help me understand what I…
Rik Schoonbeek
  • 3,908
  • 2
  • 25
  • 43
6
votes
2 answers

How do i use azure app service env variables inside my application?

i'm trying to setup my project in azure. For this i created an app service and under settings/configuration i added some "Application Settings", which in my understanding are environment variables. However i deployed my docker image which azure…
Zero
  • 554
  • 9
  • 22
6
votes
1 answer

How to use AWS Amplify env vars in gatsby-config.js?

I am building an app with GatsbyJS. I am using environment variables in my gatsby-config.js. GatsbyJS app builds fine locally, by using .env.* files. However, when building from AWS Amplify it complains about an invalid value retrieved from…
6
votes
1 answer

how to set environment variable from .env file in python script?

In the Ubuntu bash shell, I can set the environment variable from the .env file by using command lines "source" (example: source $OCSSWROOT/OCSSW_bash.env). But source is not a function in python. So, how to set an environment variable from the…
Kevin Lee
  • 89
  • 1
  • 1
  • 4
6
votes
1 answer

JetBrains Rider: Can't change environment variable in a project profile

I am attempting to modify a .NET project's settings profile in JetBrains Rider on Linux by changing its environment variables. However, when I click on the folder icon, I can't click to add, delete, or modify any environment variables. I noticed…
aBlaze
  • 2,436
  • 2
  • 31
  • 63
6
votes
3 answers

Using Jenkins Environment Variable in Pipeline SH script

I don't find a way using the BUILD_NUMBER provided by jenkins in a sh script. I read some answers to similar questions but nothing seem to help. node { echo "Build number 1 $BUILD_NUMBER" // output ok stage('stage1') { echo…
alex
  • 1,999
  • 3
  • 16
  • 18
6
votes
3 answers

how to set different environment variables of Deployment replicas in kubernetes

I have 4 k8s pods by setting the replicas of Deployment to 4 now. apiVersion: v1 kind: Deployment metadata: ... spec: ... replicas: 4 ... The POD will get items in a database and consume it, the items in database has a column class_name. now…
6
votes
3 answers

Is it possible to use environment variables from “.env” in packages section of the “Pipfile”

I have to use limited credentials to be able to install my packages from the private repository but I wish not to commit them with my Pipile. Here is a simple legitimate use case: [[source]] name = "pypi" url = "https://pypi.org/simple" verify_ssl =…
kuza
  • 2,761
  • 3
  • 22
  • 56
6
votes
1 answer

Assigning a command output to ARG variable in a Dockerfile

I want to be able to assign an command's output to an ARG variable while inside a Dockerfile. For example: ARG myvar=$(echo 'hello') However, this gives me syntax error ERROR: Dockerfile parse error line 68: ARG requires exactly one argument Is…
CodeIntern
  • 1,370
  • 2
  • 11
  • 15
6
votes
0 answers

How to get SQS url in my go lambda's environment variable while running locally with SAM?

I'm trying to develop a serverless application using cloudformation. I need a go lambda function to send messages in a SQS. To send these messages, I need a queue URL. I am supposed to store this URL in my lambda function's environment variables.…
4kakarendset
  • 61
  • 1
  • 2
6
votes
1 answer

Current Path variable in .env file

Is there a way to refer to the current directory in a .env file? Trying to point the location of a config file from userprofile, to the current path. For example, CONFIG_FILE=${USERPROFILE}\.configs\config.cfg I would like to set it…
spitfiredd
  • 2,897
  • 5
  • 32
  • 75
6
votes
1 answer

Preventing expansion of environment variables in Jenkins job parameters

Problem I am working on a Jenkins job which accepts some parameters from the user. I am encountering an undesired behaviour: Jenkins appears to be expanding environment variables references within the parameter environment variables before my script…