0

I am doing one android application (client-Server type).

Up to now ,I installed tomcat in my system itself . So now server is my computer and client is my phone

Now I want to deploy my server components(.war file) in to tomcat stack of Google Cloud so that my application is accessible everywhere.

Used Google Cloud option, click-to-deploy tomcat stack to install tomcat on cloud.

Next thing is placing our war file in to the webapps..

I tried almost every possible way to do it..but every trail results in vain .. :/

Installed gcloud sdk ...finally placed this war file in our project(can be visible through SourceCode -> Browse )in cloud through some git ways ( not in webapps) and unable to copy it to webapps.

Tried various alterations of copy-file command but in vain because of file permission denied.

I am unable to change the permission of webapps.

Lastly i tried the filezilla , able to connect to the ip address and locate the webapps folder..but unable to place my file in that folder because of same permissions problem....tried to change the permission in that filezilla itself but it also results in vain.. :/

able to change permissions remaining folders but not this(webapps).

So finally decided take support from google through mail or phone but i am in bronze plan.So i can't take their support, We have permissions only to read the documentation and stuff.

So

Is there any one who worked on Google Cloud ,faced similar type of problem and solved it.????

or

Is there any one who knows how to change permission of webapps folder of Tomcat Stack, Google Cloud

1

Finally i solved the problem.

I can actually send my war file directly from the local directory to the webapps directory of tomcat stack using filezilla or using gcloud copy file but the problem which i faced is 'permission denied'.

I solved this problem by

connect to the ssh terminal type sudo bash to enter root terminal now typing chmod 777 /var/lib/tomcat7/webapps/ROOT close and re-open filezilla to get this updated permissions. previously i was unable to change the permissions because i didn't enter in to root access.

now it's done.

1
  • chmod 777: nonononono! Never ever run chmod 777. It is practically never required! Not even for "testing purposes". If the file is readable, then it's readable. If it's writable by the user or group that need to write to it, then it's writable. There is absolutely zero need to give everyone write permissions, and forgetting to chmod it back to something sane is exactly how multinationals get hacked. Just don't do it. Ever. I wrote an introduction of Unix permissions. Please read it! – Martin Tournoij Mar 13 '16 at 6:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.