I have my GCP machine that is scheduled to switch on and run from 6hrs in the morning to 12hrs. I am trying to automate the script once the machine is on, so I am scheduling a job on 6:30 hrs.
But what I observed is that UIPath Robot doesn't automatically get connected unless I open an RDP session and then manually open UI Path Assistant to connect it with orchestrator.
I also tried to create a bat script and schedule it with windows startup. But that fails to run as well. To verify my startup script I added two commands:
<verification script sending mail on startup> && <UIPath Script>
I tested this script manually in RDP session and they did run sequentially as expected. But when I added it to auto-scheduling in gcp, only the first script actually ran (<verification script sending mail on startup>) and the second one (<UIPath Script>) just didn't.
Moreover I did put the bat file in Windows Startup Folder but again that also required me to sign into the system using RDP session for it to run.
From my understanding, the UIPath Script (XAML) in order to run needs the system to be switched on 24/7 and then it connects to orchestrator and then we can schedule the process based on the time, but then my maching will be idle for lots of ineffective hours.
Secondly, going by the .bat file to be as a startup script also fails as in order to run the script, it needs the user to be logged in which doesn't happen. Though other scripts such as .py files run smoothly so I lose here as well.
Finally scheduling my bat file through windows startup feature does work but then it's also of no use as for it to start also I need to open an RDP session and log in.
Does anyone know the workaround for this?
Related
I have SSIS package, where I'd like to do following:
in case, that I run it from Visual Studio and press STOP button, want to write information into my log table, that process was killed
same, but for situation, then .dtsx runs via dtexec, which runs via Windows scheduler - in case that runs longer than configured, Win Scheduler automatically kills to job
Don't you know if that's somehow possible?
Thanks
Where can I find documentation on Application.launch() in JXA?
Application('Safari').launch();
It seems Application.launch(), unlike Application.activate(), only starts the application process without actually open or activate an application window.
I searched the Internet and find no documentation on this function.
The launch command:
Launches an application, if it is not already running, but does not send it a run command.
If an application is already running, sending it a launch command has no effect. That allows you to open an application without performing its usual startup procedures, such as opening a new window or, in the case of a script application, running its script. For example, you can use the launch command when you don’t want an application to open and close visibly.
via https://developer.apple.com/library/archive/documentation/AppleScript/Conceptual/AppleScriptLangGuide/reference/ASLR_cmds.html#//apple_ref/doc/uid/TP40000983-CH216-SW51
Note that while the above documentation is for AppleScript, it mostly applies to JXA, too.
While working on machine xyz (could be linux or windows) - I need to start an executable program on another windows machine (just trigger would do).
How could that be done.
As per the comments provided, did the following purely on trial basis:
- Ran a custom listening tcl script on target machine (this was monitoring a shared file for writes) - also trying to use the win task scheduler to make it run each time user logs in
- On another machine that was to send command to the remote machine for exe execution, wrote a tcl proc to write to the shared file mentioned above
Thus whenever the file was written to, the script running on the target machine read the instructions and executed accordingly.
This is working for now, there are a few issues i am still facing but I think will get better eventually.
my old father is using ubuntu-gnome. He has no static ip address. In order to perform remote administration, I need to know his ip. I was using dyndns free account (configuration in the adsl modem), but this will stop working in a couple of days.
I would like to run a script each time he logs in to publish his ip on my website. I have tried to put a script on the boot, but the network is not available. It seems that it is gnome 3 that starts the network, but I do not know much about gnome 3.
How should I do to have my script run automatically as soon as the network is available ?
One possible non-elegant solution for this is to put your script in his cron to run every X minutes :)
Looking to mine /etc/NetworkManager/ looks like there is a folder dispatcher.d that I think it'll do what you want. Just experiment with a bash/perl/python w/e script in there set the permission appropriately. You can find the UUID in the system-connections/ folder. More information is available in man networkmanager.
EDIT: Look what I found: https://askubuntu.com/questions/13963/call-script-after-connecting-to-a-wireless-network. Seems like this is exactly what you want.
The easiest way is to use another dynamic DNS service. I used to use my own. You could also put curl or wget command to cron or create a systemd service that will call that command periodically. As a target you would have to use your machine with a web server where you can see the IP in your logs.
It is not Gnome that connects the network, it is a system service called NetworkManager. It tries to connect at boot if possible. In some cases it waits for wireless signal, in other cases it waits for a user password. I recently verified that in Fedora, NetworkManager properly implements the systemd's network-online.target but it may have yet to be fixed in other distributions, see the upstream bug report.
https://bugzilla.gnome.org/show_bug.cgi?id=728965
If you want to run a system service just after boot, you need to use:
[Unit]
...
Wants=network-online.target
After=network-online.target
You could also just run a script that calls nm-online at the beginning to wait for the network connectivity if you can expect the connectivity to come up in reasonable time, otherwise it times out. Such a script can be run from any environment including a user session.
And, as noted already, you can put a script into /etc/NetworkManager/dispatcher.d that will be called on any network configuration change and such a script can then filter connection up events and start the notification script.
I have integrated my selenium Webdriver scripts (using TestNG) with Hudson. i invoked my job through ant . My problem is my scripts are not running successfully also the IE browser is not getting opened However Build is creating successfully.
Note -
1) I am triggering build on Hudson from different machine on the same network with administrative access.
2) I have used excel 2007 for developing the script ( data driven framework) however on Hudson server its open office.could that be the issue?
At this moment i am not using selenium grid .please provide any suggestion
The reason for this is because Hudson/Jenkins is running as a Windows service. Recently, Microsoft changed services so that they run on their own invisible desktop. This didn't used to be the case until a few years ago. For this reason, even if you check "interact with desktop" , the desktop that is being referred to is invisble .
So, what you have to do is run Jenkins (not Hudson) as a service only for the master server. For the Selenium tests, you need to run another slave Jenkins server as a foreground shell process and the selenium tests need to be launched from that Jenkins instance instead.
If you think the instructions for setting up a slave are too hard, then you should know that it isn't required that you run as an official configured slave. You can run as a separate slave (make sure port number is different).
Also, if you are running Grids and Nodes on Windows, you might like these scripts I made.