Build a Linux package of Postgresql from sources - linux

I have a Java application using Postgres. The installer is created via Install4J for Windows and Linux.
The installer also handles the installation of Postgres on the system. So there's a Postgres package included in the installer resources. In the past EDB offered packages for Windows as well as Linux but they stopped offering the Linux packages after version 10.
Is there a way to create a package of a newer version from the sources? Should be in the style the old versions were packaged in. So that the package would work on all Linux distributions, e.g. Debian, CentOS...

Related

DCOM library missing if install VxWorks 6.9 on Linux host instead of Windows

I'm moving an existing VxWorks 6.9 build system from Windows to RedHat Linux. In theory this should be easy but it seems that if I install VxWorks 6.9, from the same CD, on Linux then the dcom-2.3 library (and a couple of others) are not installed - installing from the same CD on Windows does install them.
Anyone know what I am? This is a cross-compiler environment for an embedded system so I can't see any reason that the installed libraries should be different between the two host systems.

JavaFX from RHEL

Previously I am developing applications with JavaFX in Oracle Java SE shipped by Red Hat but it seems it is no longer offered as in https://access.redhat.com/articles/3253281. However, it seems that the OpenJDK coming from rhel-7-server-rpms repository does not come with JavaFX.
Are there better ways instead of just installing packages from outside the repositories provided by Red Hat? I don't want to test each environment with self-compiled OpenJFX binary one by one.
Oracle provide RPMs you can download:
http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
Those RPMs are not in a YUM repository that you could just point your red hat boxes to.
You can download the RPMs and create your own rum repository, then add your custom repository to the yum repository list for each of your target machines and after that use yum to install the rpms to your boxes. You would need to restrict this so that it isn't fully open to the public I think (to meet Oracle Java distribution requirements).
If you built your own version of the Java SE which included JavaFX from OpenJFX sources (or you can find a package for your target OS which somebody else has built), then you could host that in an unrestricted manner in your own repository (or any other public repository out there), or pull the package from a public repository if somebody else has already put it there.
If you don't need a repository, and can just scp the rpms to the relevant machines then you can directly install the rpms on the machines without setting up your own custom repository.
If you package your application as a self-contained application, then the application install bundle itself will include the JRE, so you don't need to worry about installing that separately on the machine (and also don't potentially run into situations where the user has installed a runtime version which is not compatible or tested with your code). Perhaps that is a preferred path for you.
I don't know RedHat's policy for OpenJDK releases and builds to their repositories. It would be nice if they included JavaFX in their OpenJDK distributions in their repositories or provided a separate package for OpenJFX, similar to what Ubuntu do. Perhaps they might include JavaFX in their OpenJDK 9 distributions. They have info on RHEL Support for OpenJDK 9, so maybe they say something there (I can't read it as I am not a RHEL subscriber). If you have a support contract with Redhat and the info isn't available on their site, then you could ping them and ask them about OpenJFX JavaFX distributions hosted in their repository (to see if they are there or not or if they have a plan to put them there).

Gitlab on suse linux

I want to install Gitlab on the suse linux OS.
Could some one please suggest me which OS supported Gitlab installer from the available ones on Gitlab site : Ubuntu, Debian and Centos can be used to install Gitlab on Suse linux ?
OS details :
SUSE Linux Enterprise Server 11 (x86_64)
VERSION = 11
PATCHLEVEL = 4
I'm afraid that Suse is a complete different system. They use a package manager called YaST that won't be compatible with any of the proposed OS on the GitLab website.
Alternatively, you can try installation via Docker (Hopefully your system is 64bits):
https://gitlab.com/gitlab-org/gitlab-ce/tree/master/docker
Or the hard way, manually:
https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/install/installation.md
Or even pop an instance somewhere in the cloud but this would involve some costs.
For all other OSs it has packages to install all the required components, but for SUSE there is no package, so you will have to install all the required components like ruby, redis, mysql and other dependent libs on your own.
You may like to try this :
https://gist.github.com/rriemann/5163741
or
https://gist.github.com/jniltinho/5565606
Since I found this answer while looking for the installation on SUSE 12 (SP3), there is one of the currently working options (2021).
First, check the version supported on the system, (Gitlab 12.1 in case of SUSE 12 SP3, which corresponds to OpenSUSE 42.3)
After that, get the proper .rpm file using wget.
Install with
sudo EXTERNAL_URL="http://gitlab.my.domain" rpm -ivh path/to/file/filename
That's it. Some Versions of Omnibus for SUSE are supported directly, but it really depends on the host system version.

Linux standalone 'installation' of Postgresql

For easy deployment, I'd like to ship an installation of Postgres as part of the application. Is it possible to include an already compiled and runnable version of Postgres that can be launched as process? I was able to do such thing with a Windows and MacOS version, but haven't found anything about Linux on that matter yet. Perhaps someone has tried this before and can share some insights...
You haven't stated what linux OS you're using.
Assuming it's a Redhat variant why not package your application as an RPM package? You could then declare a dependency on the standard Postgres package which would be automatically installed yum. Same principle applies if you're using Debian based systems, just a different packaging format.
From the user's perspective the OS's native packaging format is always the easiest way to install your application. Just requires effort to package it properly.
You can find cross-platform binaries from these pages on PostgreSQL official website:
For easy GUI .run installers, use links provided at http://www.enterprisedb.com/products-services-training/pgdownload.
If your target machine has no X installed on it, or you want to automate installation process with shell scripts, then you can download RPM or Deb packages from http://community.openscg.com/se/postgresql/packages.jsp
I found these links on http://www.postgresql.org/download/linux/ubuntu/, under "Cross distribution packages" and "Graphical installer".
I quote from those pages:
Note: The cross distribution packages do not fully integrate with the platform-specific packaging systems.
You must have root priviliges to install these packages, however, none of your systems library files will be altered. The supporting libraries that these binaries require are included locally as part of the install. This is the "special sauce" that allows identical binaries to run on different linux distro's.

Is it possible to build packages for multiple versions of Red hat Linux on a single server?

I have a set of programs for analyzing radiation data and I want to build packages for Red Hat Linux versions 4.x - 6.x. Is it possible to build these packages on a single build server running a single version of Red Hat Linux or do I need to build the version 4.x package on a server running version 4.x and the version 5.x package on a server running version 5.x?
If I can build packages for several versions on a single server, must that server be running the newest version or the oldest version of the OS?
You need to build toolchain for different OS environments (toolchain for Redhat 4.x and 5.x) and with in toolchain you can build packages for specific OS. toolchain is like a chroot environments.
You can create multiple Virtual machine using KVM and build many version of packages using single node..
You can use UML (User Mode Linux) which is quite interesting... Check out following Link
http://uml.devloop.org.uk/howto.html
You can build your packages in a chroot jail. You can use mach to do so.
Here's a tutorial on building packages with mach you could refer to, though it may be outdated.

Resources