sshed | Edit files on a remote SSH server using a local client | Incremental Backup library

 by   lengau Python Version: Current License: BSD-2-Clause

kandi X-RAY | sshed Summary

kandi X-RAY | sshed Summary

sshed is a Python library typically used in Backup Recovery, Incremental Backup applications. sshed has no bugs, it has no vulnerabilities, it has build file available, it has a Permissive License and it has low support. You can download it from GitHub.

SSHEd is a small connector program that allows you to use a local text editor or IDE to edit files on a remote server without having to manually copy the file to the local machine. More importantly, sshedit gets run from the remote machine. This means it can be used as a drop-in replacement for ed, emacs, nano, vi, etc. on remote machines over SSH.
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              sshed has a low active ecosystem.
              It has 4 star(s) with 0 fork(s). There are 3 watchers for this library.
              OutlinedDot
              It had no major release in the last 6 months.
              There are 15 open issues and 9 have been closed. On average issues are closed in 6 days. There are no pull requests.
              It has a neutral sentiment in the developer community.
              The latest version of sshed is current.

            kandi-Quality Quality

              sshed has 0 bugs and 0 code smells.

            kandi-Security Security

              sshed has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
              sshed code analysis shows 0 unresolved vulnerabilities.
              There are 0 security hotspots that need review.

            kandi-License License

              sshed is licensed under the BSD-2-Clause License. This license is Permissive.
              Permissive licenses have the least restrictions, and you can use them in most projects.

            kandi-Reuse Reuse

              sshed releases are not available. You will need to build from source code and install.
              Build file is available. You can build the component from source.
              Installation instructions are available. Examples and code snippets are not available.

            Top functions reviewed by kandi - BETA

            kandi has reviewed sshed and discovered the below as its top functions. This is intended to give you an instant insight into sshed implemented functionality, and help decide if they suit your requirements.
            • Handle connection
            • Get the contents of the file
            • Get headers from the packet
            • Read bytes from the socket
            • Diff between two strings
            • Send headers to the server
            • Generate a byte string based on the name and contents
            • Duplicate a file
            • Waits until the file is modified
            • Write the edited file
            • Patch the file
            • Choose the editor
            • Run the executable
            • Generate headers
            • Parse command line arguments
            • Generate a shell
            • Send data to the server
            • Find the SSH socket
            • Check if the configuration is valid
            Get all kandi verified functions for this library.

            sshed Key Features

            No Key Features are available at this moment for sshed.

            sshed Examples and Code Snippets

            No Code Snippets are available at this moment for sshed.

            Community Discussions

            QUESTION

            socket io connect to private ip / private subnet in vpc
            Asked 2022-Mar-15 at 19:54

            My goal is to socket io connect from my public server to my private server via const socket = io("10.0.2.50:3001") both of which are connected to my vpc. the private server has the socket/server code for my app, the public server displays the front end. I would like users to be able to link to/connect to other private servers on the private subnet.

            i have a basic aws vpc setup -

            • vpc with public and private subnet
            • one server connected to public subnet that connects to the public internet via a public route table and internet gateway. this is running @ public ip x.x.x.x:3000 private ip 10.0.1.50:3000
            • one private server that i can connect to through a private route table from my public server at 10.0.2.50:3001

            What is working -

            • i can visit the public facing server and see the front end assets load in but it never connects.
            • i can curl the private server - curl 10.0.2.50:3001 when i'm sshed in the public server.
            • i can connect to a public clone of the private server on a public ip. this confirms the code is correct for connecting. const socket = io("x.x.x.x:3001")
            • if i set the nginx reverse proxy_pass = http:10.0.2.50:3001; it works, i have a testing page setup for debugging the server side code
            • i've tested cors as mentioned in the socket io cors docs - curl "http://10.0.2.50:3001/socket.io/?EIO=4&transport=polling" and it gives expected results. for testing i have an open cors policy attached to the private server.
            • I've made my security settings very open for testing. most of them have all inbound and outbound open.

            My feeling is that connecting to a private server in a vpc is a socket io limitation, but i'm not sure why that would be the case and was curious if there's a workaround.

            Thanks in advance

            ...

            ANSWER

            Answered 2022-Mar-15 at 19:54

            "My feeling is that connecting to a private server in a vpc is a socket io limitation"

            No, it is just how networks work. Your front-end code runs in the web browser on your laptop, not in the VPC. Your laptop is not inside the VPC. Your laptop can only connect to public resources in your VPC, it can not connect to private resources in your VPC. That is the very definition of public and private VPC resources.

            For Socket.IO connections to work between web browsers on the public Internet and your back-end servers, those servers must be in a public subnet and have a public IP address, or the traffic must be proxied through either a public server or a public load balancer.

            Source https://stackoverflow.com/questions/71486417

            QUESTION

            Springboot server in Elastic Beanstalk creates files that I can't see
            Asked 2021-Dec-13 at 15:46

            I have a Springboot server that is deployed to an Elastic Beanstalk environment in AWS. The basic functionality is this:

            ...

            ANSWER

            Answered 2021-Dec-13 at 15:46

            If you need to store an uploaded file somewhere from a Spring BOOT app, look at using an Amazon S3 bucket as opposed to writing the file to a folder on the server. For example, assume you are working with a Photo app and the photos can be uploaded via the Spring BOOT app. Instead of placing this in a directory on the server, use the Amazon S3 Java API to store the file in an Amazon S3 bucket.

            Here is an example of using a Spring BOOT app and handling uploaded files by placing them in a bucket.

            Creating a dynamic web application that analyzes photos using the AWS SDK for Java

            This example app also shows you how to use the SES API to send data (a report in this example) to a user via email.

            Source https://stackoverflow.com/questions/70297555

            QUESTION

            The given path's format is not supported (listing files)
            Asked 2021-Mar-15 at 18:41

            I'm trying to move all files from a NAS to a cloud provider, which does not allow the char ?<>|/\\*:" in its filenames, unfortunately some of the files do have these char in their filenames.

            So I would like to fix these filenames before doing the migration, and thus I had the idea to list the forbiden filenames, but the forbiden char crash the Get-childItem command and I'm a bit stuck

            Here's the command I use

            ...

            ANSWER

            Answered 2021-Mar-15 at 18:41

            QUESTION

            Jenkins Cannot create token using login and password
            Asked 2021-Jan-18 at 08:58

            I was trying to set up git pipeline, but for some reason, I am unable to do so now. It is throwing error showing the above error. I tried different things, but could not see anything out of the order.

            I am at my wits end and do not know how to proceed. Kindly tell me how should I proceed to fix this ?.

            Note:- Currently Jenkins is installed in an ec2 instance and another ec2 instance is used as build server, in both servers git is installed and working correctly. I have sshed into build server and tried accessing repo from it and was able to clone the repo sucessfully in build server.

            Kindly advise me on what might be the possible issue here?

            ...

            ANSWER

            Answered 2021-Jan-18 at 08:58

            If you are using basic username/password combination, GitHub no longer supports basic authentication using a username and password for the API and Git operations.

            https://developer.github.com/changes/2020-02-14-deprecating-password-auth

            https://github.blog/2020-07-30-token-authentication-requirements-for-api-and-git-operations/

            Instead, you'll have to use personal access tokens (PAT). Web browser based sign ins to GitHub will still use your username and password, all others will require a token.

            Source https://stackoverflow.com/questions/65769528

            QUESTION

            aws ec2 run infinite time job remotely
            Asked 2021-Jan-09 at 01:18

            I have an AWS EC2 instance on which I would like to run a job of infinite time. However, I don't want to have to SSH into my instance to run the command.
            I basically need to run a python script, which performs work indefinitely, so I want to run python3 script.py from my EC2 instance in such a way that I can do it remotely, and as long as my instance is running the script.py script is running.
            To be more clear, if I run a command like sudo service httpd start I don't have to remain SSHed into my instance to know that the traffic is being served. Similarly, I would like to run a command such that even if I terminate my SSH connection to the instance, script.py is still running.
            A solution I thought of is to have a local machine explicitly connect to the instance and run the command in an infinite loop, but I would like to avoid this.
            A further question is if there is a way to scale to multiple instances performing this same job.
            I have also tried editing rc.local in the etc directory, but I confirmed that the job was not running.

            ...

            ANSWER

            Answered 2021-Jan-09 at 00:58

            If I am understanding your question correctly, you are asking for a way to start a script on an EC2 instance, and have it keep running after you terminate your SSH connection.

            You can use tmux for this. Type tmux new to start a new tmux session, then run whatever script you are trying to run. Then press Ctrl+B, and then press D. This will disconnect you from your tmux session, but the tmux session will still be running your script. Now you can safely close your SSH connection, with your script still running. If you want to access the terminal running the script again, you can type tmux a into your console, and it will bring back the session running the script.

            Alternatively, you can use screen, though I would use tmux for this task.

            Source https://stackoverflow.com/questions/65638187

            QUESTION

            How to have AWS ECS automatically map ports of my container to the host machine(EC2)
            Asked 2020-Nov-06 at 12:13
            Context:

            I am using Circle CI's aws-ecs/deploy-service-update orb to deploy my docker container by pulling the latest image in AWS ECR and deploy it in AWS ECS with AWS EC2 instance. This container is a Machine Learning model that accepts API requests at TCP port 3000(I am using fastAPI for this) and returns the predictions. After I deployed it I couldn't send requests to the public IP of the container instance of the task that deploys the container at port 3000 (This IP is not my EC2 instance's public IP; it only has private IP and public IP is disable).

            Debugging
            1. I checked my security group and made sure that the port 3000 is open to receive requests from all IPs(0.0.0.0), as part of the inbound rule.
            2. I stopped the task(which automatically will stop the container running in the EC2 instance) with the thought that something may have gone wrong from Circle CI. Then, according to the service configuration(1 desired task) and task definition of AWS ECS, a new task has started(hence the container) automatically. But, I couldn't send requests to this either.
            3. I SSHed into my EC2 instance to know if the port 3000 is open. This is when is when I learned that ports weren't mapped at all:
              As you can see, PORTS column is empty for the container and the container has to accept requests at port 3000 from the command.

            And here are the open ports of the EC2 instance: As you can see, port 3000 is not listed here.

            Here is the task with port mappings which deployed the container (to AWS ECS) that you see docker ps screenshot above:
            In the task definition, you can see the port mappings I have defined for the container.

            Here is the task running on my EC2 instance with the task-definition shown above and the network mode I am using is 'awsvpc':

            Here's the "Networking" tab of ENI associated with the task, and also the inbound rule of the security group associated with the EC2 instance that the task is running inside, which accepts requests on port 3000 from all IPs.

            EDIT 1:

            After I did

            ...

            ANSWER

            Answered 2020-Nov-01 at 19:35

            For the awsvpc network mode port mappings work a bit different. The hostPort is no valid option here, the created ENI will expose the containerport to the VPC.

            There are several prerequisites for this mode, e.g ECS agent version, instance type (ENI count limit), instance profile, ... check the official AWS documentation: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/task-networking.html

            Habe you checked for ENI attached and which ports are open on those ENIs?

            Source https://stackoverflow.com/questions/64632279

            QUESTION

            Localhost not working in production in Docker
            Asked 2020-Jul-26 at 20:13

            I successfully ran MERN app in my local machine using docker. Then, just for fun, I wanted it to deply to AWS, EC2 instance. After deploying, the fetch call in react-app gives this error:

            ...

            ANSWER

            Answered 2020-Jul-26 at 20:13

            You will need to replace "localhost" with the url of the deployed back-end.

            React is a client-side javascript library, and runs in the users web browser, so it will use the "localhost" of the user that visits your page, not the server's localhost.

            Source https://stackoverflow.com/questions/63103356

            QUESTION

            Unable to view flask app on reserved static address on Google Cloud Platform
            Asked 2020-Jul-24 at 10:32

            Instead of the usual way of deployment via Gcloud command line, I simply sshed the GCP Ubuntu instance and deployed my flask app via WinSCP by transferring the files onto the Ubuntu instance I have created. I was able to get it to run like so:

            I have also reserved a static address so that I could allow users to view the Flask app.

            However, when I tried to access the external ip address, GCP refused to connect and I can't view my flask app.

            What could I have possibly done wrong?

            ...

            ANSWER

            Answered 2020-Jul-24 at 10:32

            There is no VPC Firewall rule to allow ingress traffic to your instance on tcp/8080.

            First step: Add a network tag on your GCE instance, allow-8080-ingress.

            Second step: Under the web menu, go to VPC Network - Firewall - Create Firewall Rule and create a new rule with following properties:

            • Name: Whatever8080
            • Network: [select the network to whom your instance belongs to]
            • Direction of traffic: Ingress
            • Action on match: Allow
            • Targets: Specified target tags
            • Target Tags: allow-8080-ingress (the network tag that you added on your instance)
            • Source filter: IP ranges
            • Source IP ranges: 0.0.0.0/0 <<== This will allow incoming traffic from any IP. You may be more specific, choosing a smaller range or even a specific IP address.
            • Specified protocols and ports: Check tcp and add 8080

            You did not attached the your flask code, but if you launch it like this, it will just work:

            Source https://stackoverflow.com/questions/63069696

            QUESTION

            Azure Functions with Python and Premium Plan: Despite version 3.8. selected 3.6. gets deployed
            Asked 2020-Jul-03 at 17:31

            I deployed an Azure Functions App with Python 3.8. Later on I tried to use dataclasses and it failed with the exception that the version available does not support dataclasses. I then SSHed to the host of the Function App and by using python --version figured out that version 3.6 was actually installed. As dataclasses are available from 3.7 on it makes sense why this module can't be used.

            But what can I do to actually have version 3.8 running on the Function App host?

            ...

            ANSWER

            Answered 2020-Jul-03 at 10:34

            This is a known issue (see e.g. https://docs.microsoft.com/en-us/answers/questions/39124/azure-functions-always-using-python-36.html) and hopefully fixed soon.

            As workaround you can run the following command e.g. in the Cloud shell:

            az functionapp config set --name --resource-group --subscription --linux-fx-version "DOCKER|mcr.microsoft.com/azure-functions/python:3.0.13353-python3.8-appservice"

            After that you need to wait for a while so that the function app becomes usable again. Additionally I have made the experience that the installed packages are gone. Therefore you need also to republish your functions (having the necessary packages defined in requirements.txt).

            Source https://stackoverflow.com/questions/62713607

            QUESTION

            Issues connecting to mosquitto broker with node mqtt client via SSL/TLS
            Asked 2020-Feb-29 at 21:12

            Helllo, I created a mosquitto broker via the eclipse docker image and recently followed this guide to add SSL/TLS support: http://www.steves-internet-guide.com/mosquitto-tls/.

            When I am sshed in the VPS which is running the broker, I can use the command:

            ...

            ANSWER

            Answered 2020-Feb-29 at 21:12

            2 separate problems here.

            1. Looks like you don't have a valid DNS entry for your VPS. mosquitto_pub is failing because it can't resolve the name to an IP address. It works with the --insecure and the IP address because you are telling mosquitto_pub to ignore the fact that the CN or SANs in the brokers certificate doesn't include the IP address only the name.

            2. You are trying to connect with raw MQTT not MQTT over TLS, you need to use a URL not just a hostname or the first argument of the connect() function. e.g.

            Source https://stackoverflow.com/questions/60468951

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install sshed

            For right now, you'll need to do the following to use sshed:.
            Install it on both the client and host machine.
            On the client machine, run sshed_client and copy the command given on stdout to the shell where you want to run ssh
            On the client machine, SSH to the host using the edssh command.
            On the host machine, you should now be able to use sshed as your editor, but only in the shell you connected via edssh.
            Eventually, the installation process will look similar to the following:.
            Extract the Python modules and binaries on the client.
            On the remote host, modify the AcceptEnv line of /etc/ssh/sshd_config to include the text variable "SSHED_SOCK". This isn't required, but it helps.
            In ~/.ssh/config, add a SendEnv line that sends "SSHED_SOCK". See the note below.
            Add sshed_client to run like ssh-agent does.
            If the host has sshed installed, simply ssh to the host and use sshed
            If sshed is not installed on the host, use edssh to SSH in.

            Support

            For any new features, suggestions and bugs create an issue on GitHub. If you have any questions check and ask questions on community page Stack Overflow .
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/lengau/sshed.git

          • CLI

            gh repo clone lengau/sshed

          • sshUrl

            git@github.com:lengau/sshed.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link

            Explore Related Topics

            Consider Popular Incremental Backup Libraries

            rsnapshot

            by rsnapshot

            bitpocket

            by sickill

            RsyncOSX

            by rsyncOSX

            sshfs

            by osxfuse

            rsync

            by WayneD

            Try Top Libraries by lengau

            gh-snap

            by lengauShell

            tell

            by lengauPython

            dailyprogrammer

            by lengauPython

            netphys

            by lengauPython

            ssid-of-st-john

            by lengauPython