Connecting to cache instance (csession) remotely - intersystems

Is there a way to connect to cache instance (csession) remotely?
Let's say the intersystems is on a container, and I want to use csession on the remote server from my local machine, is there a way (without direct ssh) to run the cache instance?
I'm looking for an alternative way of these steps:
1- scp the cache script into the box
2- ssh into the box
3- run the csesion on the box
Any comments is really appreciated

You could use telnet (encrypted) But this wouldn't allow you to load scripts local to your machine.
One way would be to have your scripts in a git repository and add the loading of them into your instance as post-receive hook.

You might consider using https://intersystems-ru.github.io/webterminal/.
That is "web-based terminal for InterSystems Caché".

Related

Swisscom CloudFoundry with SSH keys

I try to install Wordpress on the Swisscom CloudFoundry application cloud. To install it I need SSH with private and public key pairs (not cf ssh).
I follow the steps here:
https://github.com/cloudfoundry-samples/cf-ex-wordpress
Is this possible? What are the correct values for:
SSH_HOST: user#my-ssh-server.name
SSH_PATH: /home/sshfs/remote
Is this possible?
It depends on your CF provider. This method of running Wordpress requires that you use a FUSE filesystem (SSHFS) to mount the remote files system over the wp-content directory of your Wordpress install. In recent versions of CF (I can't remember exactly where this changed) you are no longer allowed to use FUSE based file systems.
Before you spend a lot of time on this, you might want to validate that your provider still allows FUSE. You can validate with a simple test.
Push any test app to your provider.
cf ssh into the application container.
Check that the sshfs binary is available.
Try using sshfs to mount a remote filesystem (man page | examples).
If you can successfully mount a remote filesystem via SSH using the steps above then you should still be able to use the method described in that example application.
If you cannot, the next best option is to use a plugin that allows storing your media on a remote system. Most of these are for S3. Search google or the WP plugin repo, they're easy enough to find.
There is a better solution on the horizon called Volume Services. You can read more about this here. I have not seen any public CF providers offering volume services though.
What are the correct values for:
SSH_HOST: user#my-ssh-server.name
This should be the user name and host name of your SSH server. This is a server that exists outside of CF. Examples: my-user#192.0.2.10 or some-user#host.example.com. You should be able to ssh <this-value> and connect without entering a password. This is so that the volume can automatically be mounted without user interaction when your app starts.
SSH_PATH: /home/sshfs/remote
This is the full path on the remote server where you'd like to store the Wordpress files. In other words, this directory will be mounted as the wp-content directory of your app.

Run command in Puppet Master

Is there a way to run a command in puppet master that will bring changes to the hosts right away?
I have used different scripts using crontab to schedule my tasks and it changes whenever I have specified, but I am trying to learn if there is a way I can just hit the command in puppet master and boom! bring changes in the hosts(clients) immediately.
Let's say I want to change password in "cofig.properties" file in my 5 hosts. What would be the best way to do it from master without scheduling?
At work we
push git versioned control repos to a puppetmaster using a jenkins job,
then we use r10k to retrieve the control repo puppet module & hiera dependencies,
then we connect remotely using SSH to each node we want to update to run the relevant "puppet apply" command
It works smoothly.
I've solved that problem in my infrastructure by using Puppet for Configuration Management and SaltStack for orchestration.
I have the Puppet Agent apply a SaltStack module to automatically configure each node as a minion of my Salt Master (which is also my Puppet Master), then I just SSH into my master server and tell SaltStack to run the Puppet Agent on nodes that match my criteria.
There are several SaltStack modules on the Puppet Forge.
You could certainly use other tools, such as RunDeck, or even Puppet's own MCollective, but I personally found them to be more complicated to work with.

Transferring a file through the CLI on the same network

I have a file on my desktop and I need to get it onto another server, but I have no means of getting it there, i.e. email/usb or any way like that.
The server is on the same network as me.
I have heard of a way that the file can be copied via the command line.
Would anyone have any information on this and if so could you please help me?
Not sure whether you have command line access to that server or not? If yes, are you accessing it via telnet or via ssh?
If ssh, you should be able to transfer the file via SCP (secure copy), since it uses the same ssh connection you use to get your cli. If you want to transfer your file from a Windows environment, you may want to look at WinSCP, else do a man scp on your Linux or Unix server and, assuming you have it, you'll get the hang of it... it's not complicated.
If ssh is not an option, then you depend on the server having some service available for you to transfer the file, most obvious one being FTP.
Does that help?

Drupal: remote development with Eclipse

What's the best solution to develop Drupal remotely on a development server, using Eclipse ?
I found this: http://www.eclipse.org/dsdp/tm/
Is this the best way to do it ? And above all, am I going to have some limitations ?
thanks
Sometimes SSH / SFTP is a better solution than Samba. SSH is likely to be activated on most servers an can be mounted into the local file system.
If you only have access via FTP you have two options.
You can set up a connection to the server using remove system explorer. When you set up a new project use the generic new project option and there you should have an option to choose which file system to use.
This will mean that you work directly on the server, be warned this can be slow sometimes, using FTP is slower than most other methods of connecting to a remote system.
The other option is to work locally and deploy to your server when you whish to test something. You can use the 'export' feature for this.
Just use samba on the machine. Point your project at it.

Best way to install web applications (e.g. Jira) on Unixes?

Can you throw some points on how it is a best way, best practice
to install web application on Unixes?
Like:
where to place app and its bases and so for,
how to configure to be secure and easy to backup,
etc
For example I know such suggestion -- to set uniq user for each app.
App in question is Jira on FreeBSD, but more general suggestions are also welcomed.
Here's what I did for my JIRA install on Fedora Linux:
Create a separate user to run JIRA
Install JIRA under the JIRA user's home directory
Made a soft link "/home/jira/jira" pointing to the JIRA installation directory (the directory as installed contains the version number, something like /home/jira/atlassian-jira-enterprise-4.0-standalone)
Created an /etc/init.d script to run JIRA as a service, and added it to chkconfig so that it runs at system startup - see these instructions
Created a MySQL database for JIRA on a separate data volume
Set up scheduled XML backups via the JIRA admin interface
Set up a remote backup script to dump the MySQL database and copy the DB dump and XML backups to a separate backup server
In order to avoid having to open extra firewall ports, set up an Apache virtual host "jira.myhost.com" and used mod_proxy to forward requests to the JIRA URL.
I set everything up on a virtual machine (an Amazon EC2 instance in my case) and cloned the machine image so that I can easily restart a new instance if the current one goes down.

Resources