Score:-3

Is it possible to make an auto updating website

ge flag

I am making a website and I want it to automatically upload and update the code in the server when I make changes on my computer. I am using the latest ubuntu server I also have the vscode if there are any exertions in there.

Levente avatar
cn flag
https://stackoverflow.com/questions/12794568/how-to-configure-git-post-commit-hook ?
Jason avatar
ge flag
I'm not using git
NotTheDr01ds avatar
vn flag
Just a heads-up that there are now 4-votes to close (including mine) this for *"Needs details or clarity"*. You don't mention much about your tools or workflow. If you are just looking for recommendations on tools or workflow, then that would probably be far too broad a question (which should be closed as *"Needs more focus"*). What you seem to be asking about is really CI/CD (Continuous Integration/Continuous Delivery) strategies. That's just too "open-ended" a question for our Q&A style here. I'd recommend looking up some introductions to Continuous Integration and go from there.
Levente avatar
cn flag
Other than that, I guess it would be possible to use shell scripting. I guess `ssh` and `rsync` would be relevant here. Here are some ideas about how to overcome the challenge of providing the server password automatically: https://stackoverflow.com/q/3299951 and https://unix.stackexchange.com/q/111526 Then you can just run the script in the terminal.
Score:1
fr flag

As Levente has pointed out, using Git would be smart for a number of reasons (ie. versioning, staging before production, etc.), but if you can't use it for whatever reason, check this out:

https://code.visualstudio.com/docs/remote/ssh

Basically you open a VS Code window on your machine but use the file system on the remote server and edit the files in real time.

I need to do my due diligence and tell you that this is not a good idea for production use. If the files are static, consider using the Live Server extension which can be found here.

Good luck!

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.