Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Plan specific config

In order to run e2e-tests I need to provide some configuration (e.g. json-file) to my build plan, yet I do not want to store the config in vcs or in any other external source.

 

1 answer

1 accepted

0 votes
Answer accepted

Hi @Mikko Sartanen

I hope you are talking about a Bamboo build running on Linux. Assuming that is the case, please consider the following JSON content as an example:

{"menu": {
"id": "file",
"value": "File",
"popup": {
"menuitem": [
{"value": "New", "onclick": "CreateNewDoc()"},
{"value": "Open", "onclick": "OpenDoc()"},
{"value": "Close", "onclick": "CloseDoc()"}
]
}
}}

You could embed this content in a script task using the following configuration:

  • Interpreter: Shell
  • Script Location: Inline
  • Add the following content for script
    read -d '' filename << EOF

    {"menu": {
    "id": "file",
    "value": "File",
    "popup": {
    "menuitem": [
    {"value": "New", "onclick": "CreateNewDoc()"},
    {"value": "Open", "onclick": "OpenDoc()"},
    {"value": "Close", "onclick": "CloseDoc()"}
    ]
    }
    }}

    EOF
    echo "$filename" > filename.json

The script task will create the file you need and it could be configured to run right before the e2d-tests.

Let me know what you think about this.

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Bamboo

Bamboo Data Center 8.1 is now available

G’day Bamboo customers, Bamboo DC 8.1 is now available with it the following features and programs: SAML 2.0, OpenID Connect, and Crowd SSO In order to help admins with a simplified user manage...

194 views 0 4
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you