Where is the JobScape preference file located? - autosys

Is there a configuration file for JobScape where I can specify which jobs to load on startup, the refresh interval etc?

Apparently JobScape that comes with AutoSys 4.5 has no user preference file. You can not specify default values for job specific parameters that you see from the View menu (like what jobs to load on startup, the view levels etc). But there is a preference file for X-Windows resources that you can manually edit to specify default values for X-Windows parameters that you see from the Options menu (like auto reload, refresh interval etc.) In Solaris this file is /usr/openwin/lib/app-defaults/Xpert

Related

Unable to delete uploaded XML file on Drupal 8.5

I have created a media type that accepts XML files and saves them to a custom publicly accessible location on the server.
Ideally I would like the file to be overwritten when the exact same file is uploaded. This does not happen, instead it creates a new file and adds a number on the end. I have "Create new Revision" turned off.
To get around this issue I thought I could just delete the file via the CMS. The uploaded file has status of "Permanent" and is used 0 places. I know the cron job cleans up files for you, but when I run the cron the file in question is still there. I figure it's because the file is set to permanent, but I don't see a way to flip this to temporary.
Any help is much appeciated.
There is a setting nested away in the file system settings, which lets you configure it to remove (or not removed) orphaned files. If drush isn't removing them despite having no usages recorded, I'd check this option isn't ticked.
The temporary and permanent status are used for storing temporary files during the upload/save process, so I wouldn't tinker with those too much.
If you fancy making the form yourself using the form API, then you can save the file programmatically using the FILE_EXISTS_REPLACE parameter.
https://api.drupal.org/api/drupal/core%21modules%21file%21file.module/function/file_save_data/8.5.x

Creating templates in Cloudstack

I am trying to get a cloudstack environment up and going. I have managed to get a server up, and it is pointed to my XenServer to manage. I have been able to create a couple of instances as well. In those instances, I have added some software, and gone through the initial install, and would like to make that my baseline. However, the screenshot below shows what I can see in the Templates section. When I click on Register template, I have no options for being able to make a template from a Volume or a snapshot of the instances I have created.
Am I doing something wrong here?
You want to Create Template
Create Template starts from an existing volume. In contrast, Register Template requires you to upload a volume into CloudStack.
If you want create template of a vm then you will have to stop the vm and then you will have find the root volume of that vm ,you can in two way .First click on instances ,then click that particular instance ,then click on view volumes ,then select the volume whose name is starting with ROOt ,select fourth icon which is for template creation.Then fill the form and submit. Second one is go dashboard ,select storage then find the root volume which is having you vm name in vm display name cloumn ,select that root volume ,the click on fourth icon which is to create template.Fill the form and submit it.

Save asp.net user editable configuration settings

I am looking to store a few random global settings in an ASP.net MVC4 application that would affect the entire application.
These setting need to be editable by the admins of the site (i made a small form)
They are things like current site wide discounts, promotion expiration dates, keys to partner services, etc.
They dont fit in a database because they are single (scalar) values that don't fit into any list (or table). They should just be in some singleton object at the application level. Yet the need to be persisted - once an admin changes the value they dont want it to be reset just because the server (or application) was reset.
I thought of storing them in the web.config file through the setting object. But I publish upgrades on a regular basis and that would overwrite the we.config on the server.
You could use the following;
Database (prefered)
XML File
Plain text file
Any of these would give you a way of storing the information and a simple interface to read and write would allow your application access. You can then store these in either the Application or Session objects and use them accordingly.

Is it possible to set a default location for R packages instead of giving the user a choice?

Good afternoon!
I'm a system administrator at a university, and I am responsible for setting up the images for a computer lab. R is part of the default image, and for the longest time we only had a single log-in for all lab users, allowing us to set the default directory once and then image it across multiple systems. This has changed, and we're now having all users log on with a personalized log-in. That brings me to a problem I'm having with R, and why I'm turning to you.
You see, as most of you may be aware, when R is run for the first time, a dialog box opens up that prompts for a location to save packages and the like. Hit 'OK' and it's the user file, but hit anything else and it's wherever you put it. The problem is, we've locked down the systems rather tightly, and access to anything more than the user's individual directory is not something we like to do.
The question I have is this - is there a way to force R, on first run, via hands-free script or just a setting somewhere, to default to the user's directory on the system for package storage? This would prevent me from having to give All Users access to read and write to the R directory, and would have fewer possibilities of screwing up since they wouldn't actually have a choice to change it. If I have to continue giving permissions in that folder, I can, but I'd rather not.
Thanks!
Edit your .Renviron file to set the default path:
# .Renviron file
R_LIBS = '~/.R/library'
I can't test this right now, but I believe you could add something like Sys.setenv(R_LIBS_USER=path.expand('~\R\library')) to the Rprofile.site file found in the R etc directory.
'...to default to the user's directory on the system for package storage...'
another way, especially if you wanted different setting for staff/students would be to to use group policy to set an environment variable for selected machines/users at login.
e.g. the equivalent of...
SETX "R_LIBS" "\\fileserver2/department_shared/public/r/packages"
you can easily check if this has worked by starting R and trying
Sys.getenv("R_LIBS")
also, this command can then show you what packages are installed:
rownames(installed.packages())

How do I allow the user to select the path for a file?

In an application I'm working on, the users are prompted for the path of a file. This path will always point to a network drive, which the server has access to.
Currently, we use an asp:FileUpload control to accomplish this, drawing the path from the FileUpload's PostedFile.FileName property.
The problem is that the files the user is selecting from are locked down pretty severely. While the server has full access to them, the user only has permission to view the directory contents... They can't even open the files. This has worked fine up until now... But Windows 7 won't display these files in the file picker generated by FileUpload, so we need an alternative.
Notes:
Looking for a way to get UI similar to the file open dialog already in place.
The ability to view the client's local files (including the shared network drives) is a bonus, although listing the files through the server is acceptable.
I think the problem is the permissions on these files. If the users can't even open them, how can their terminal possibly upload them to a website?
I'm surprised this has ever worked.
If the user is simply supplying a path and not actually uploading the file you could have the server display the contents of the folder (in a list or whatever) and the user selects from that.
So how about creating a file browser in a window, such that a user clicks "Pick File" which opens a new window showing the root contents of the network drive. The user can then navigate round the directories to the file they want, finally clicking the file to "upload".
Use System.IO Directory.GetFiles to get the files in a directory.
I think you need to separate out the two things. Here's an example prompt to convey the idea:
Select a (file from your computer) OR (file from the server)
Client Files
You can use the standard file-upload control, that is fine.
Server Files
No user should be selecting files from your sever with the upload-file dialog. (Keep in mind that these dialog boxes allow right-click menus delete, copy, properties, etc and locked down or not, the user should not think they have this ability).
I don't think there are any controls that will "do-it-all" for you in this manner. I think your best bet is to make your own interface here.

Resources