Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Atlassian Stash Linux (Fedora) Service / Java Service Wrapper

ChristianS July 6, 2013

Hello, how could I configure the Java Service Wrapper with stash on Fedora?

Currently there is a guide at https://confluence.atlassian.com/display/STASH/Running+Stash+as+a+Linux+service#RunningStashasaLinuxservice-Usinganinit.dscript

But the guide is really not that good, since it forwards to the Java Service Wrapper website which won't say anything specifiv about atlassian stash. the init script also won't work since its not working on fedora.

5 answers

1 accepted

2 votes
Answer accepted
cofarrell
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 6, 2013

Hi Christian,

In that case the guide at the following is probably what you're after as it talks about systemctl:

https://answers.atlassian.com/questions/147102/instead-of-init-d-use-systemctl

And copy+paste just in case you still can't see it:

Create a stash.service file in /usr/lib/systemd/system/ directory that looks like this (adjust ExecStart and ExecStop with your stash install directory):

1
2
3
4
5
6
7
8
9
10
11
[Unit]
Description=Atlassian Stash Service
After=syslog.target network.target
[Service]
Type=forking
ExecStart=/opt/atlassian-stash-2.2.0/bin/start-stash.sh
ExecStop=/opt/atlassian-stash-2.2.0/bin/start-stash.sh
[Install]
WantedBy=multi-user.target

Then enable the service to start at boot with:

1
systemctl enable stash.service

Or disable it with

1
systemctl disable stash.service

Or see if it is set to start at boot with:

1
if [ -f /etc/systemd/system/*.wants/stash.service ]; then echo "On"; else echo "Off";fi

You now can restart the system and it should start stash as part of the booting process.

To manually start and stop the service you can run:

1
2
systemctl start stash
systemctl stop stash

To see the state of stash run:

1
systemctl status stash
0 votes
ChristianS July 6, 2013

now it works.. really dumb. somehow i've gotten a atlassian 404 error page. not sure why.. maybe the server uses a location based delivery and the server for europe was offline, w/e.

thanks didn't knew that it is so easy to make a systemctl script. I'm not that familiar with systemctl (SysV) right now. maybe i should look into it.

I think the same approach will be with jira or / and bamboo if we really buy bamboo.

0 votes
ChristianS July 6, 2013

Thanks that you posted that here, but as i said, your page gives me a 404 error.

cofarrell
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 6, 2013

That's so weird - it's just an Answers page. I can see it in multiple browsers.

Anyway, I hope the above helps.

ChristianS July 7, 2013

now it works.. really dumb. somehow i've gotten a atlassian 404 error page. not sure why.. maybe the server uses a location based delivery and the server for europe was offline, w/e.

thanks didn't knew that it is so easy to make a systemctl script. I'm not that familiar with systemctl (SysV) right now. maybe i should look into it.

I think the same approach will be with jira or / and bamboo if we really buy bamboo.

0 votes
ChristianS July 6, 2013

this site gives me a error 404.

I'm running Fedora 19 currently.

We are switching from an Active Diretory and Windows Enviroment to Fedora (FreeIPA).

And now we want our Atlassian Tools to run on Fedora enviroments, too. Everything works so far, except the init.d scripts or the java service wrapper.

0 votes
cofarrell
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 6, 2013

Hi Christian,

Are you running Fedora 18, and if so does this help?

https://answers.atlassian.com/questions/147102/instead-of-init-d-use-systemctl

Charles

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events