grunt-rsync | Grunt task for accessing the file copying | Continuous Deployment library
kandi X-RAY | grunt-rsync Summary
kandi X-RAY | grunt-rsync Summary
A Grunt task for accessing the file copying and syncing capabilities of the rsync command line utility.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of grunt-rsync
grunt-rsync Key Features
grunt-rsync Examples and Code Snippets
Community Discussions
Trending Discussions on grunt-rsync
QUESTION
I have written a small Vue app and have been looking for a nice way to automate its deployment, i.e. call lint -> test -> build -> upload to some web space (stage and /or production) (sftp). Basically a simple CI/CD pipeline.
I looked a task runners such as grunt (seems to be a bit outdated and the docs didn't help me much) and gulp (see also this answer) and also thought of defining a npm script. CI tools such as Jenkins seem to be a bit oversized with some work to setup.
The npm script would probably be the simples solution, especially as I could simply chain lint / test / build:
...ANSWER
Answered 2019-Aug-04 at 17:07The easiest way to deploy static site is to use pages.github.com - just push your build in github repo.
Another simple (Mega simple) service is netlify - just install it with npm install netlify-cli -g
. Details in docs
But if you need better CI you don't need to search "vue deploy', you need any CI service from github, bitbucket, gitlab, etc. For example - easy introduction by circleci
Back to your question - do you use linux/mac or windows?
It's very simple on linux, just use command like scp from/local/dir to@remote/dir
. On windows you maybe should try some nodejs alternatives like snippet from this answer
QUESTION
I am a web developer, and for some upcoming projects I would like to use a file-based CMS. This means that many of the files I create at the start must be editable by the PHP user later, but also remain editable for my user (and also the other way around). My PC runs Debian 9, which I love but am not super knowledgeable about, and I have also just set up a local network server with Debian 9 for backups and possibly file sharing. (I'm using Webmin to configure this, which reflects my level of command line skills).
On my online shared hosting server, the PHP user and the FTP user seem to be the same, and 644/755 permissions work fine, this is also recommended by the CMS I'm using. I would like to mimic this on my computer so I don't have to fiddle with permissions all the time. But how do I do this? Currently, my regular user (anna
) does not have access to www-data
's files and vice versa. Putting them in the same group still means changing file permissions. Making anna
the PHP user is a Bad Idea (as far as I understand it) because anna
has sudo
permissions.
So far I have researched three possible solutions that I don't really know very much about, and I would like to know which is the best route to take.
- Develop locally on my computer and use
apache-mpm-itk
or suPHP to let PHP edit the files (I got that idea from this question on ServerFault). - Develop locally on my computer and
rsync
the files to my server withgrunt-rsync
, and somehow getrsync
to set the ownership towww-data
(another ServerFault thread helping here). - Mount the project's server directory, which is owned by
www-data
, on my computer with SSHFS and then either edit the files on the server directly or copy them over from my local directory withgrunt-copy
.
What do you think: from a security and ease of use perspective, which is the best way? Or do you know an even better one?
Thank you for taking the time to read and think about this!
Anna~
ANSWER
Answered 2018-Jul-20 at 10:03I figured it out! I finally ended up reading about running PHP as CGI instead of as an Apache module, and that this would solve my permissions problem. Plus, as far as I understand it, there are no extra security precautions to take when I'm the only one working with it on my local computer.
In case someone comes across this who might find it helpful, here's what I did (basically following these instructions):
- I installed
php7.0-fpm
Edited /etc/apache2/sites-enabled/000-default.conf and put the following just before
:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install grunt-rsync
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page