ftp-deploy | Node.js module to ftp a folder | FTP library
kandi X-RAY | ftp-deploy Summary
kandi X-RAY | ftp-deploy Summary
Node.js module to ftp a folder somewhere
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Merge a list of included files
- Read password .
- Tests if the given path should be included .
- Delete directory recursively
- Make sure the config is an array
- number of files
ftp-deploy Key Features
ftp-deploy Examples and Code Snippets
Community Discussions
Trending Discussions on ftp-deploy
QUESTION
Is that possible to deploy the Laravel web application to shared hosting using GitHub Action & GitHub FTP Deploy? If possible how should I change the.github\workflows\master.yml?
...ANSWER
Answered 2022-Feb-12 at 02:26Looks like you're very close but are missing 2 important steps: set up a temporary PHP environment, and use that environment to install your dependencies (Composer).
GitHub Actions Setup
This guide assumes you have a working Laravel installation, a GitHub account, and a shared hosting account that you can access via FTP using a username/password.
I found this video https://www.youtube.com/watch?v=UNWIXYSZfZY helpful to get a basic understanding of how to deploy a simple application. To make this answer helpful to a wider range of people, I'll give a quick outline of my setup. There really aren't any Laravel specific steps.
Workflow directory set up
Create the directories .github\workflows
at the root of your project. In the workflows
directory, create a yml file named after the branch you want to push to your shared hosting account. Ex. master.yml
, staging.yml
, development.yml
etc. If you only have a single branch then just create one file. The name is important and should match the name of the branch.
Design your workflow
This is very dependent on your project but assuming you have a basic Laravel application without the need for additional components such as Node, then this is a basic GitHub Action that works for me on a variety of projects.
A basic action file consists of 2 sections, the workflow, and the jobs. A workflow triggers the jobs.
Workflow
Lines 1-4 say this will run each time we push
to the master
branch.
QUESTION
I've been using GitHub for a good while on private repos without issue until last week, GitHub upped the minimum requirements on SSH encryption.
Thing is, I'm running an older copy of OpenSSH, on an older OS release, and TL;DR, I can't upgrade it to support the new standard (at least, not yet).
There are FTP actions available as an alternative, but apparently GitHub Actions don't use a consistent IP space and I can't lift 100% of IP restriction to make that go either (nor do I feel great about that, for obvious reasons).
Short-term (without just migrating everything), are there other options for keeping GitHub that I'm just overlooking?
...ANSWER
Answered 2022-Jan-14 at 15:20You could use a credential helper, if you can get it installed in your environment. The gh cli comes with one, but it's not a standalone binary so you may have issues getting it working in an older environment. There's also the Git Credential Manager. You can see full instructions for using these in GitHub's docs.
QUESTION
I´m tring to config a GitHub Action to deploy my application to SFTP file.
My application has 6700 files and I would like to upload only changed/commited files.
How can I remove unchanged and/or uncommited files before upload to SFTP?
This way, my one file modification deploy would be so faster than upload 6k files.
...ANSWER
Answered 2021-Dec-31 at 18:18To list down all the files that are updated/committed in the given commit, you can use this command:
QUESTION
I am trying to upload a repo to server via ftp on push to master branch. I have it set up and working. However in the repo there is a folder /public. I only want to upload the files in this folder to the server. Not other files or the folder itself. I have tried to set up a working directory for the job but this doesn't seem to do the trick.. any ideas?
...ANSWER
Answered 2021-Nov-30 at 07:50Checking out only one directory is not possible, but has been requested in the actions/checkout
repository before: https://github.com/actions/checkout/issues/483
There's an action to check out specific files, but I haven't tried it and I'm not sure if it does what you want: https://github.com/marketplace/actions/checkout-files
You might want to ask yourself why you're trying to limit the number of files transferred. Is it because you're concerned about traffic? Or because of the input expected in the subsequent action?
If it's the latter, you could also manually "fix" the structure by running some mv
and rm
commands.
QUESTION
In VSCode I'm using ftp-simple to upload a directory of static files from a Svelte site.
I would like to automate this, presumably using npm, so that when I run npm run build
it also uploads the build folder to the specified ftp.
What can I use for this? ftp-deploy
seems likely, but I'm not sure how to configure package.json
etc.
Any help would be appreciated.
...ANSWER
Answered 2021-Nov-10 at 17:25The documentation for npm scripts explains. Briefly, though:
In package.json
, find (or create) the scripts
property. Find or add a build
property to that. The value should be the command required to upload. That can be a script that you write (using ftp-deploy
or something else) or it can be a CLI tool that is installed as a dev dependency or a regular command or set of commands available to your shell.
So you might end up with something like this (but it probably won't be this exactly):
QUESTION
i'm using SamKirkland/FTP-Deploy-Action to deploy my files to my server,
but the key 'exclude' doesn't actually exclude Workspace and my resources folders, it works fine for .git and .github folders.(i guess the problem is with exclude key's value syntax but i couldn't find the right one for my folder.)
also i don't want to use .gitignore bc i want my resources folder in my repository.
ANSWER
Answered 2021-May-16 at 14:54the problem was with github website.
github's action's status turned incident!
i should've checked out github status page.
QUESTION
I am trying to simply run webpack serve -c myconfig.js
, but I keep getting these errors:
ANSWER
Answered 2021-Apr-24 at 18:10The problem was in
QUESTION
I am using Github as my source control, and using Github Actions as my CI/CD solution. I have a dedicated Windows Server somewhere, which accepts the published version of my repo.
I have a Github Action, which does Built, Test, Publish and Deploy (using FTP). I am not convinced with the "Deploy" idea. for example lets say my website has a huge codebase, and then FTPing everytime when we make a commit (Push) is NOT really a productive idea (i am publishing the published directory...not the Source Code to my server). Sometimes FTPing simply does not work, due to IIS Locking the files. what is the most reliable way to publish/deploy files to a remote server using Github Actions (or any other provider).
below is my sample Yaml file...
...ANSWER
Answered 2020-Jul-01 at 00:31Since you have a dedicated server for your application, I would recommend using a Github self-hosted runner.
You install the runner service on your server and then the Github CI/CD build process runs on your dedicated server.
The build script can build your app then stop the IIS site locally which prevents locked files.
After that it can copy (or robocopy) the new build into the app folder.
Gitlab also has self-hosted runners.
QUESTION
I have a custom Jekyll site which is working fine on local.
I would like to deploy my builded site to my hosting environment. Via FTP with github actions is working fine with this: https://github.com/SamKirkland/FTP-Deploy-Action
This is the FTP workflow:
...ANSWER
Answered 2020-Oct-17 at 14:33This is what I currently use, which I found from The World According to Mike Blog.
This uses ncftp which allows you to upload files via ftp easily.
QUESTION
As the title says, deploying to FTP server isn't working for me from a Github Action. I've tried using a couple of actions to accomplish this (FTP-Deploy and ftp-action), but FTP-Deploy just kept running with sporadic
curl: (7) Failed to connect to ftpservername.com port 21: Connection timed out
messages and ftp-action kept running without any output. Note: The server is available, I connected and transferred some files using Filezilla without any issues.
After that I tried using lftp, this is the command I used on a local Ubuntu machine
lftp -c "open -u username,password ftpservername.com; mirror -R locfolder remote/remotefolder"
and the file transfer worked, but when used in a Github Action it produced this output:
---- Connecting to ftpservername.com (123.456.789.123) port 21
mkdir `remote/remotefolder' [Connecting...]
**** Socket error (Connection timed out) - reconnecting
---- Closing control socket
---- Connecting to ftpservername.com (123.456.789.123) port 21
I tried setting both ftp:ssl-allow
and ssl:verify-certificate
to false, but this did not produce any results. Also, I do not have access to the server, so I can't check the server logs.
This is the workflow file:
...ANSWER
Answered 2020-Oct-21 at 13:21Found the issue, the hosting service was blocking the IP address (as it was an IP address outside of the country). After setting up a self-hosted runner and whitelisting the IP of the runner everything works fine.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install ftp-deploy
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