James Raitsev
James Raitsev

Reputation: 96461

How to find out current working directory in Bamboo?

This seemed like a good idea at the time

public static final String MY_CONFIG_FILE = System.getenv("APP_HOME") 
                                              + "/cfg/app.properties";

When pushed code to Bamboo some tests failed with

java.io.FileNotFoundException: ./cfg/app.properties (No such file or directory)

I did set EnvironmentVariable in Bamboo as APP_HOME=.

Still, however, Bamboo can't seem to find the file. What am i doing wrong please?

Upvotes: 10

Views: 12781

Answers (1)

James Raitsev
James Raitsev

Reputation: 96461

In case someone is interested, in order to reference current working directory, APP_HOME should be set to:

APP_HOME=${bamboo.build.working.directory}

Upvotes: 16

Related Questions