Do all the things like ++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatarSign Up
metamourge4275133dIf you have SSH access, you could sync it over a Git- or Mercurial-Repo.
JKyll6906133dUmm sftp would suffice for file transfers if it's a simple website.
Last time I deployed I had an ExpressJS webapp and had docker + githooks for continuous integration which was awesome but I was a bit of a hurdle to set up.
I don't have root access.
It's a simple php website without any framework.
McSebi538133dWinSCP script for syncing your local folder with the server, PhpStorm and Xdebug
Winscp and vsCode works well.
Open in winscp set your editor as vsCode and on save it will save back to server.
Do you have . folders Or hidden folders? You might need to enable visibility in your FTP client to see them.
Otherwise set up Git if you can.
After half day of trial and error I managed to sort it out with vs code and some extensions. I used remote fs (for fetching all remote files from ftp/sftp), then also used sshlogin(for logging into terminal in prod)
SauceBoss1501133dPhpstorm is my favourite IDE. Also avoid FTP and get into Git if possible.
TheCapeGreek2737133dSet up ssh to the server and make a script to do the deployment from git.
@TheCapeGreek what about if im working on some gameserver files during runtime via sftp? If I deploy to git and then deploy from git to sftp it will delete all files and replace them with new thus my server will crash? I dont want to shutdown gameserver everytime Im deploying minor changes. In that case working directly through sftp is better for me.
@zemaitis it’s the same thing, and no, Git won’t replace all files only changes made to files based on the latest merge. Gits history tracking comes in handy here.
Replacing full files - as you do with sftp can cause major issues if you are working directly with live code and say upload the main config file with errors, instead of a test / dev environment that’s a replica that can catch these problems before a release.
@C0D4 ok then I will start with website via ftp first. So now I will install phpstorm and will download all remote files and then put them on github. Will open a new project and checkout my github files. Whats the best way to setup deployment script from github to my ftp server via ssh?
@zemaitis can you install Git on the server?
If you can just login through ssh and do a Git clone once you have it in Git correctly.
Future changes are a Git pull away, and if you want to automate you can enable webhooks or look into auto deployments.
If you can’t, it gets tricky but you could do a webhook to detect changes, and download the repo to a temp location, and then copy it over the top of your web directory.
redpanda1011159133dIf you have money or you are a student, go with PHPStorm Or Webstorm
Your Job Suck?
Take a quick quiz from Triplebyte to skip the job search hassles and jump to final interviews at hot tech firms
Get a Better Job