Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
Umm 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. -
C0D4669026yWinscp 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)
-
@SauceBoss So if I keep website files in git then I need to test them in some staging environment and after that deploy them to ftp somehow?
-
@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.
-
C0D4669026y@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?
-
C0D4669026y@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.
Related Rants
Question for web devs. I have to manage a simple php website and I am tired of filezilla+notepad++ combo. I need something more modern. Tried visual studio code+simple ftp integration but it doesn't seem to download some of the folders. Can you advice any other alternative?
question
ide with ftp sync
php