Oryx provides configuration options through environment variables so that you
can apply minor adjustments and still utilize the automatic build process. The following variables are supported today:
NOTE: In Azure Web Apps, these variables are set as App Settings.
Setting name |
Description |
Default |
Example |
PRE_BUILD_COMMAND |
Command to a shell script to be run before build |
"" |
echo foo |
PRE_BUILD_SCRIPT_PATH |
A repo-relative path to a shell script to be run before build |
"" |
scripts/prebuild.sh |
POST_BUILD_COMMAND |
Command to a shell script to be run after build |
"" |
echo foo |
POST_BUILD_SCRIPT_PATH |
A repo-relative path to a shell script to be run after build |
"" |
scripts/postbuild.sh |
ENABLE_DYNAMIC_INSTALL |
Enable dynamically install platform binaries if not presented inside the image |
various |
true , false |
ORYX_SDK_STORAGE_BASE_URL |
The storage base url from where oryx dynamically install sdks |
"https://oryx-cdn.microsoft.io" |
|
DYNAMIC_INSTALL_ROOT_DIR |
Root directory path under which dynamically installed SDKs are created. |
various |
"/opt", "tmp/platforms/oryx" |
DISABLE_CHECKERS |
Disable running version checkers during the build. |
false |
true , false |
ORYX_DISABLE_TELEMETRY |
Disable Oryx command line tools from collecting any data. |
false |
true , false |
ORYX_APP_TYPE |
Type of application that the the source directory has. |
"" |
'functions','static-sites', 'webapps'. |
DISABLE_RECURSIVE_LOOKUP |
Indicates if detectors should consider looking into sub-directories for files |
false |
true , false |
ENABLE_MULTIPLATFORM_BUILD |
Apply more than one toolset if repo indicates it |
false |
true , false |
PLATFORM_NAME |
Specify which platform the app is using |
"" |
"python" |
PLATFORM_VERSION |
Specify which platform version the app is using |
"" |
"3.7.1" |
REQUIRED_OS_PACKAGES |
Indicate if it requires OS packages for Node or Python packages |
false |
true , false |
CREATE_PACKAGE |
Indicate if it shoud create packages for the app |
false |
true , false |
Setting name for .NET apps |
Description |
Default |
Example |
DOTNET_VERSION |
Specify which .NET version the app is using |
"" |
"5.0.100" |
DISABLE_DOTNETCORE_BUILD |
Do not apply .NET Core build even if repo indicates it |
false |
true , false |
PROJECT |
repo-relative path to directory with .csproj file for build |
"" |
"src/WebApp1/WebApp1.csproj" |
MSBUILD_CONFIGURATION |
Configuration (Debug or Relase) that is used to build a .NET Core project |
Release |
Debug , Release |
Setting name for Nodejs apps |
Description |
Default |
Example |
NODE_VERSION |
Specify which Node version the app is using |
"" |
"14.15.0" |
DISABLE_NODEJS_BUILD |
Do not apply Node.js build even if repo indicates it |
false |
true , false |
CUSTOM_BUILD_COMMAND |
Custom build command to be run to build Node app |
"" |
"npm ci" |
RUN_BUILD_COMMAND |
Custom run build command to be run after package install commands |
"" |
"npm run build" |
ENABLE_NODE_MONOREPO_BUILD |
Apply node monorepo build if repo indicates it |
false |
true , false |
COMPRESS_DESTINATION_DIR |
Indicates if the entire output directory needs to be compressed. |
"" |
false |
PRUNE_DEV_DEPENDENCIES |
Only the prod dependencies are copied to the output for Node apps. |
"" |
false |
NPM_REGISTRY_URL |
Specify the npm registry url. |
"" |
"http://foobar.com/" |
Setting name for Python apps |
Description |
Default |
Example |
PYTHON_VERSION |
Specify which Python version the app is using |
"" |
"2.7.1" |
DISABLE_PYTHON_BUILD |
Do not apply Python build even if repo indicates it |
false |
true , false |
VIRTUALENV_NAME |
Specify Python virtual environment name |
"" |
"antenv2.7" |
DISABLE_COLLECTSTATIC |
Disable running collecstatic when building Django apps. |
false |
true , false |
Setting name for Php apps |
Description |
Default |
Example |
PHP_VERSION |
Specify which Php version the app is using |
"" |
"7.4" |
PHP_COMPOSER_VERSION |
Specify which Php composer version the app is using |
"" |
"7.2.15" |
DISABLE_PHP_BUILD |
Do not apply Php build even if repo indicates it |
false |
true , false |
Setting name for Java apps |
Description |
Default |
Example |
JAVA_VERSION |
Specify which Java version the app is using |
"" |
"14.0.2" |
MAVEN_VERSION |
Specify which Maven version the app is using |
"" |
"3.6.3" |
DISABLE_JAVA__BUILD |
Do not apply Java build even if repo indicates it |
false |
true , false |
Setting name for Ruby apps |
Description |
Default |
Example |
RUBY_VERSION |
Specify which Ruby version the app is using |
"" |
"2.7.1" |
DISABLE_RUBY__BUILD |
Do not apply Ruby build even if repo indicates it |
false |
true , false |
Setting name for Hugo apps |
Description |
Default |
Example |
HUGO_VERSION |
Specify which Hugo version the app is using |
"" |
"0.76.3" |
DISABLE_HUGO_BUILD |
Do not apply Hugo build even if repo indicates it |
false |
true , false |