I sometimes get this error:
2016-10-20T15:38:24+0200 WARN main o.s.s.c.SimpleParser:131 - Command 'app register --name email --type source --uri <uriToMyDockerImage>' was found but is not currently available (type 'help' then ENTER to learn about this command)
At other times it works as expected.
Note that I start the shell with --dataflow.uri=<url> --spring.shell.commandFile=<path>.
Why would the app register command not be available? What can I do to make it available?
This would happen if the last time the server tried to connect to the REST API of the dataflow server, the server was down.
This happens at
shell start
everytime you do dataflow config server <url>
Related
I want to run an old .NET application in a docker windows server container (https://hub.docker.com/r/microsoft/windowsservercore/).
Everything would be easy if this application didn't require an UI. Its UI does a lot of stuff and this stuff cannot be done through command line or other API.
Basically, the perfect thing would be to reach this running container through RDP.
From my understanding, it is nothing more than a service (TermService) running on a certain TCP port (3389 being the default one).
But it seems that TermService is not running in microsoft/windowsservercore containers.
I found an article showing how to activate it : https://withinrafael.com/2018/03/09/using-remote-desktop-services-in-containers/
Basically, I kept the same Dockerfile, just changing some credentials.
#escape=`
FROM microsoft/windowsservercore:1709_KB4074588
RUN net user /add jerome
RUN net user jerome aDifficultPassword
RUN net localgroup "Remote Desktop Users" jerome /add
RUN net localgroup "Administrators" jerome /add
RUN cmd /k reg add "HKLM\System\CurrentControlSet\Control\Terminal Server" /v TemporaryALiC /t REG_DWORD /d 1
I launch the container with this command :
docker run -it -p3389:3389 myimage powershell
When I connect to the container and type some powershell commands to list running services, I can see that TermService is well running. This is the command I use to list services.
Get-Service
When I list opened TCP ports, I can see that 3389 is listened. This is the command I use to show opened ports.
netstat -an
When I try to connect to the container through my remote desktop client, things seems OK at start.
It asks me for host.
Then for a username and password.
If I type wrong credentials, it says me "Wrong credentials", so there is well a communication with the server.
If I type good credentials, nothing happens. No error message at all, but no display screen too...
I don't really know if logs are generated somewhere or not.
I would be OK if instead of RDS, something like TigerVNC was working. I have never tried this tool before but it seems that it could do the job.
How would you do to control a GUI application running in a windows container?
You can find logs for RDP client in event viewer : "Application and Services Logs"\Microsoft\Windows\TerminalServices-ClientActiveXCore. Here's what is says for me :
The client has established a multi-transport connection to the server.
RDPClient_SSL: An error was encountered when transitioning from TsSslStateDisconnected to TsSslStateDisconnected in response to TsSslEventInvalidState (error code 0x8000FFFF).
RDP ClientActiveX has been disconnected (Reason= 2)
reason 2 is session closed by client.
My paranoia tells me that microsoft went back and patched the image to prevent people from using RDP with docker, but who knows, maybe we're just missing something obvious.
I want to run neo4j from the google cloud shell and I have already ssh'd into my project.
Currently I am using the following to run neo4j:
docker run \
--publish=7474:7474 \
--volume=$HOME/neo4j/data:/data \
--volume=$HOME/neo4j/logs:/logs \
neo4j:3.0
The command works and prints the following output:
Starting Neo4j.
2017-12-13 03:22:34.661+0000 INFO ======== Neo4j 3.0.12 ========
2017-12-13 03:22:34.681+0000 INFO No SSL certificate found,
generating a self-signed certificate..
2017-12-13 03:22:35.163+0000 INFO Starting...
2017-12-13 03:22:35.631+0000 INFO Bolt enabled on 0.0.0.0:7687.
2017-12-13 03:22:37.966+0000 INFO Started.
2017-12-13 03:22:39.041+0000 INFO Remote interface available at
http://0.0.0.0:7474/
However, when I follow the link to http://0.0.0.0:7474/, it redirects to something like https://7474-dot-3282369-dot-devshell.appspot.com/?authuser=0 and I get an error:
Error: Could not connect to Cloud Shell on port 7474.
What can I do differently or what additional info would you need? Thank you.
I think you are facing one of the two following issues:
1. If you ssh'd in a different machine and the server is running there
The issue is that you accessed an instance from the Google Cloud Shell, then you started the server through docker. At this point I think that you connected (not intentionally) to the Cloud Shell on the port 7474 clicking on "Web preview" of the same Window!
But the server was running on a different machine!
Therefore the Cloud Shell informed you that is not listening on port 7474. To solve this issue you need to retrieve the public/external IP of your instance, create a firewall rule allowing the TCP:7474 traffic and connect to it from any browser with http://ip-your-machine:7474.
2. If you are running the server in the Google Cloud Shell
First of all you should not run a server on the Google Cloud Shell, it is not a normal virtual machine and you should never rely on it.
By the way I followed step by step what you did:
I accessed the Google Cloud Shell, I have run your code, I obtained the very same output, but when I have done the "Web preview" I correctly visualised the neo4j login page.
Thus, I believe that if you were running the server here you unintentionally stopped it before checking the "Web preview".
P.S.
The weird domain name you have been redirected to: https://7474-dot-3282369-dot-devshell.appspot.com is a domain name that points exactly to your Google Cloud Shell #3282369 on port 7474.
You are redirected automatically clicking on a link from the Cloud Shell, (since you cannot reach 0.0.0.0 from your computer).
I'm currently performing a task which requires the use of Apache Tomcat.
When starting up Apache automatically through a windows service, the task fails.
However when I right click command prompt, and select 'Run as Administrator' and start Apache using a bat file, the tasks completes successfully.
This leads me to believe the tomcat service needs to be configured to run as admin.
Could you guide me on how to do this?
Try running the service under a local systems account.
After I build my application on Jenkins,
the output message says my build is success, however I get this error message in the end, and my website can't work...
D:\Jenkins\jobs\1.job\workspace>SC \\123.45.12.133 START w3svc
[SC] StartService FAILED 1056:
An instance of the service is already running.
Any suggestion?
It says the w3svc(World Wide Web publishing service) can not start by Jenkins.
So you should start it manually by following steps:
Open your services in administrative tool
Right click w3svc(World Wide Web publishing service) and re-start it.
Or use command line and input sc start w3svc
I have followed this link to run Selenium Server as a windows service: http://www.claytonstechnobabble.com/2011/08/run-any-application-as-windows-service.html
The service gets installed successfully but when I try to run it it gives error:
"The SeleniumRC service on Local Computer started and then stopped. Some services stop automatically if they are not in use by other services or programs."
can you guys help me on that asap? what am I missing?
This is the selenium server file that I am trying to run: "selenium-server-standalone-2.5.0.jar"
Ali, you might try capturing the output from the service. Since the Java app is designed to be run in console mode, there is likely to be some useful explanation if you can capture std out and std err. Running the service with a wrapper like Java Service Launcher will provide that functionality to log the error information: http://jslwin.sourceforge.net/
Create a bat file containing
//cd Location of file
java -jar selenium-server-standalone-2.5.0.jar
then use this bat file to execute in service.