How to host Apache SuperSet on an Amazon EC2 intance? - amazon-web-services

I am trying to host an Apache superset server on an Amazon EC2 instance. Whenever i host it from a standalone ssh, the moment i close the terminal from my laptop, the superset server shuts down..Is there a way i can host SuperSet server on Amazon EC2 instance so that it is online always ?

Run it using nohup superset <options> &. Then even after you close the terminal, it continues to run.
Stopping it should require kill the process using PID, which can be found using grep.

Related

How to keep my Minecraft server running in Google Cloud Platform?

I used a VM in Google Cloud Platform to host a Minecraft server, which I use ./run.sh to start the server. However, once I close the VM bash it shuts down my server. It's a way to keep my server running?
I tried using screen -S run.sh it didn't work though.

AWS System Manager Run Command on EC2 Failes

I'm running a fastapi server on ec2 ubuntu. Everything work fine when I ssh in to ec2 and run commands, but I want the server to be running when my local machine is off.
So, I tried AWS System manager's run command. The connection looks fine but when I cd to the server code and run ls it outputs nothing. Also, when I do poetry run python main.py in the server folder, which works totally perfect when I ssh in to the server from my local machine, it says poetry: not found.
Why is this happening. And is there another way I can run my server while being able to turn off my local machine.
There is not any kind of relation between your machine and your server in the cloud, and your ec2 its still alive and runs your services whenever you want

What is the best way to run a script remotely on Windows VM instance?

For example, in Linux VM instances we can use gcloud beta ssh command to run commands remotely by downloading ssh keys using gcp credentials
Similarly, I am looking for running scripts on Windows VM instance remotely without doing RDP to an instance.
Can someone point to a solution for this problem?
If you have a Windows workstation with PowerShell, you can connect to your Windows Server instances through a remote PowerShell session. This process is similar to connecting to a Linux instance using SSH. Please review "Connecting to Windows instances using the PowerShell terminal"
https://cloud.google.com/compute/docs/instances/connecting-advanced#powershell

Zeppelin on AWS EC2 (Ubuntu instance)

I installed Apache Spark and Zeppelin on an Ubuntu instance running on AWS. Zeppelin is starting fine and when I check the status it is OK:
sudo ./bin/zeppelin-daemon.sh status
Zeppelin is running [ OK ]
But I can not use the "ip address":8090 to see the zeppelin webpage and create notebooks. The IP address I am using is the public one AWS give me (and I changed the port to 8090 in zeppelin-site.xml).
Should I change the server address in the zeppelin-site.xml?
Zeppelin is indeed running on port 8090 on that server, but the port is not accessible externally -- that is, it can only be accessed from the server itself.
No fear! You can use port forwarding to connect to it.
Linux
ssh -i keypair.pem -L 8090:localhost:8090 user#<IP-ADDRESS>
This tells SSH to forward any requests sent to port 8090 on the local computer to the remote machine's localhost:8090. Therefore, you can access Zeppelin via localhost:8090 on your computer.
Here's an example of it in use: Big Data: Amazon EMR, Apache Spark and Apache Zeppelin – Part 2 of 2
PuTTy
If you are using PuTTY to connect to the host, there is a similar command in the Tunnels configuration screen. Redirect 8090 to localhost:8090 on the remote machine.

How to run sonatype nexus on aws ec2?

I need to put sonatype nexus3 up on AWS. Following an old tutorial for nexus 2, I was led to try this on EC2. What I'm currently trying is an instance with a security group that allows inbound requests from anywhere on ports 80,8080,22,4000,443, and 8081. I'm using a Amazon Linux AMI 2016.09.0 (HVM), SSD Volume Type instance. I install docker using the instructions from here http://docs.aws.amazon.com/AmazonECS/latest/developerguide/docker-basics.html#install_docker. I then simply use the official docker image from here https://hub.docker.com/r/sonatype/nexus3/ with the following command.
docker run -d -p 8081:8081 --name nexus sonatype/nexus3
Using docker ps I can confirm that this seems to be running. When I try to connect to the provided public DNS url ending with amazonaws.com on port 8081, I simply get connection refused. Same thing on port 80 or any of the other ports and the same thing when I add /nexus to the end of the URL.
Attempting the quick test that documentation for this image suggests:
>curl -u admin:admin123 http://localhost:8081/service/metrics/ping
curl: (56) Recv failure: Connection reset by peer
Using the exact same docker command on my local machine (OS X) I am able to access nexus on localhost. Why can't I get this working?
The issue appears to have been with Sonatype's official image. This image which works the exact same way, works perfectly with the exact same process.