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

Running as non sudo user

How can I run a command as "ubuntu" user in EC2?

I login with "ubuntu" but the script is executed as "root"



3 answers

1 accepted

0 votes
Answer accepted

Solved, the user was correct but npm is loaded in the .bashrc file that is ignored from the pipeline's plugin.

I solved adding the npm path to the file /etc/environment

I'm using atlassian/ssh-run:0.2.6

this is my code:

image: atlassian/default-image:2
deployment: production
pipe: atlassian/ssh-run:0.2.6
SSH_USER: "ubuntu"
COMMAND: "/home/ubuntu/"

@Luca Carducci it depends on your server where you're trying to login and on your ssh key you are using for authentication. If it is root's key , you should be logged in as root. Check your ssh configuration that you have for your "ubuntu" user

0 votes

@Luca Carducci tell please which pipe are you using?

And share your pipe usage example

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted in Trello

Taco Tuesday: Your favorite Trello blog takeaway

Hello friends! From the community that brought you Welcome Wednesday, Throwback Thursday and Friday Fun, welcome to Taco Tuesday, a weekly discussion about all things Trello. The best part? One Tac...

67 views 4 3
Join discussion

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