When I try to run polymer serve on terminal, it always run with port 8080. But it collapse with another services I've configured with that port. How can I change the default port to run the projects, for example, in port 8081?
There is an option for that:
polymer serve --port 8081
Related
I'm currently using containerd to run my application container for testing, but having a problem with networking.
I need to send some requests to port 5000 of my application container though there's no description on ctr manual about running a container with port forwarding.
Using docker, we can do like as follows:
docker run test-image -d -p 5000:5000
Can I do the same thing using ctr command?
I know nerdctl can do this but it's hard to use this tool for some reasons within my company.
ctr cannot, but you can download nerdctl and that will do it.
No, ctr is not a comprehensive tool and it does not support all the commands that docker cli used to support.
There is no command in ctr for port forwarding.
I have created two docker containers, One is mysql and other is phabricator both are linked and both are locally. I have bound mysql port to 0.0.0.0. Now I want to expose the phabricator to internet. so that everyone can use that. --net=host option does not work with links. Can anyone tell me how can I achieve this ?
You need to start your phabricator container with -p setting which defines the port mapping- Let's say your container internally exposes port 8080, then you can define it like -p 8080:8080, which means that the port 8080 is also externally accessible (as long as your host is reachable from internet on port 8080 without interfering firewall).
I have created a new OpenShift account for a new application I'm developing.
I have added a MongoDB cartridge for the database, and a Tomcat cartridge for the Java web application.
I now need to connect to the database from my Java web app, but I miss two authentication details:
$OPENSHIFT_MONGODB_DB_HOST
$OPENSHIFT_MONGODB_DB_PORT
As far as I know, I have to type rhc env list -a the_name_of_my_app in the console, but my application seems to have no environment variables set.
What can I do?
Apparently, the default enironment variables are visible only via ssh.
In order to see them, you have to type rhc ssh <appid-as-seen-on-openshift-console> followeb by env.
you can see environment variables by doing ssh to openshift. Also you can use openshift port forwarding feature to setup a connection locally to your database.
Openshift blog link for port forwarding
I create a diy Appliation and add a mysql cartridge and bind it to the port 8080.Is it possible to access outside the network through domain? I have a little idea about the routing
system.
I am not very sure what you want here. But you can use putty in your local machine to connect to Openshift mysql.
Thank you
You can use port forwarding using the 'rhc' command line or using the OpenShift Tooling in JBoss Tools. In both case, you'll have a set of local sockets to connect to, and it will forward commands to the remote 3306 port on your OpenShift gear, so you can run MySQL/SQL commands on your database.
Is there any way to start a service and force a service that is already running to stop if it uses the port that the service I want to start is going to be using?
I'm going to be installing apache and mysql, and want the services to be running without having to manually stopping existing services that use port 80/3306 such as existing apache/mysql services.
I'm using NSIS to make my installer.
To find the process listening on port 80 perhaps you could do the equivilent of this from the command line:
c:\>netstat -aon | findstr 0.0:80
TCP 0.0.0.0:80 0.0.0.0:0 LISTENING 3488
3488 is the process id. Not sure what APIs netstat is using though.
Without disabling or reconfiguring the service that is already using the desired port is still going to cause problems on system restart. The best bet might be to abort the install if the port is already in use. To check if a port is in use, use this NSIS TCP plugin.