Comments (17)
I use #!/usr/bin/env bash
for my bash scripts. It should be a bit more portable than using #!/bin/bash
and may solve the issue here.
from opensearch-build.
Hello!
Overview of FreeBSD ports and packages
For some years now, FreeBSD provide packages for the ports: users do not need to compile all software they want to use anymore, they can just install packages using the pkg
command.
The ports are basically a recipe to handle build dependencies, download the source code of a program, compile it, install it, and generate a package. The FreeBSD packages are built using the ports in the FreeBSD ports tree. New packages are built regularly (weekly), FreeBSD basically follow a rolling release pattern: new software is published β the port is updated β a new package is available.
For this reason, I would recommend not to try to ship FreeBSD packages on the OpenSearch website, but make it easier for FreeBSD contributors to maintain a port of OpenSearch which will make OpenSearch available as a regular package for all FreeBSD users.
Packaging of OpenSearch
For Java applications, the process described above is often a bit different: build dependencies are sometimes tedious to manage at the port level, and since java code is portable (can run on any platform with a JVM), a lot of FreeBSD ports for Java application download an artifact from the vendor and not the source code. The port maintainer has then just to manage dependencies, ensure the right files are placed at the right place, manage rc.d scripts and it is basically all: no "compilation" step is required. A drawback is of course if some modification of the source is required, then the maintainer has no real other choice than integrate the change with upstream and wait for the next release.
The FreeBSD packages shipped by FreeBSD are built using a set of "default" options which a user can override by compiling their ports (in the old-school way, before we had packages), or building their own packages. This can be useful for example to use a specific version of say python, ruby, PostgreSQL, java and so on.
This mean that an OpenSearch FreeBSD package will not ship with a JVM. The port will say "You need at least Java X", the FreeBSD port will be built with Java Y so the package will have a dependency on Java Y, and user will be able to build their packages using Java Z if that is what they want/need.
So, the tarball made available for 1.0.0 basically fit as a FreeBSD "source" tarball, even if it bundle a lot of thing we do not care about (mainly the non-portable stuff that lead you to ship multiple packages for different architectures).
Maybe a "lite" / "portable" tarball which does not bundle java and sample certificates would be a better fit, avoiding to download unneeded data?
Maybe this can be generalized with 2 sets of packages:
- a bunch of all-in-one tarball that contain everything needed to try out OpenSearch quickly (basically what is the 1.0.0 tarball);
- a "production" tarball that only contain OpenSearch itself: no java, no sample certificates, and so on.
Packaging of OpenSearch-Dashboards
Just like OpenSearch, a FreeBSD package would not bundle node.
Currently, as far as I understand, the kibana package is built using the kibana-7.14.0-darwin-x86_64.tar.gz archive as a source, applying some local patches on top of it, and rebuilding the shipped node libraries (which contain some C/C++ that has to be rebuilt).
This look quite ugly, but I am not aware of a cleaner way for projects in JS which include some C/C++ code (I do not hack in JS at all).
We can probably apply a similar strategy for opensearch-dashboards?
I am available for chatting about this π Thanks!
(I try to attend the Community Meeting)
from opensearch-build.
@peternied if I am right, the minimal archives do not include plugins such as the security which is definitively something we want to have support for on FreeBSD.
For now, the WIP port is based on the "full" Linux distribution and ignore the non-portable content. The port is being tested by a few people who are working on it, we still have a few minor things to tweak but I think that we will commit it to the FreeBSD ports tree soonβ’ π
I can follow-up here when we have committed the port and it is available to all FreeBSD users and request the issue to be closed?
from opensearch-build.
Let's close this! @smortex thank you & everyone else who contributed.
from opensearch-build.
Not sure about the roadmap (separate packages for very os/distro? rpm, pkg, deb etc.), but imho the shebang fixes should be done during packaging. RC scripts can be added anyway.
from opensearch-build.
I added some basic checks and env in the following PRs.
This would help to create a FreeBSD port.
opensearch-project/OpenSearch#1013
opensearch-project/OpenSearch#1014
opensearch-project/OpenSearch-Dashboards#678
from opensearch-build.
@dblock, @peternied the ports have just been committed to the FreeBSD ports tree:
https://cgit.freebsd.org/ports/commit/?id=7fe660d7479c2a88f1c3aac267470f2a507757a0
https://cgit.freebsd.org/ports/commit/?id=19e156d5142115dcd542d47ee329a2656798d789
User of FreeBSD can now build OpenSearch and OpenSearch-Dashboards, and in a few days packages should be available for them.
Do you want we add some kind of installation instructions for FreeBSD on the OpenSearch website?
And I think this issue can now be closed.
from opensearch-build.
Yes, we should! @smortex those docs are opensearch-project/project-website, and I think we should spell out how to install on FreeBSD.
Here we go: opensearch-project/project-website#321
Also, after 1.1 is released, what's there to do to make a FreeBSD release? We should have those instructions somewhere (maybe here)?
We have setup a FreeBSD OpenSearch Team composed of both committers and external contributors (and this group will be happy to see more contributors). So we will try to keep the port updated in a timely fashion when a new release is available. The process being open, if people think we are too slow, they can work themself on the update and propose the change. This whole process is documented in the FreeBSD Porter's Handbook, the most relevant sections being:
Thanks!
from opensearch-build.
I'm going to un-assign myself and @nknize because we're not working on this, but I think we do have most bits and pieces to make this happen. I would start by trying to building the bundle from the top on FreeBSD and opening specific issues, such as "remove JDK in opensearch-min on FreeBSD". If anyone wants to take it on, I'd be happy to help/review PRs.
from opensearch-build.
Note that the OpenSearch PRs @hackacad made (thanks!) were merged. The one on dashboards is still open, but hopefully soon.
from opensearch-build.
We are working with @hackacad in a fork of the FreeBSD ports repo to complete the opensearch and opensearch-dashboards ports (opensearch branch):
https://github.com/smortex/freebsd-ports/tree/opensearch
We probably still have a few minor issues, but while I am typing, I could pkg install opensearch opensearch-dashboard
in a jail and ingest data. So I expect we will be able to commit this soon in the official FreeBSD ports tree.
from opensearch-build.
We are working with @hackacad in a fork of the FreeBSD ports repo to complete the opensearch and opensearch-dashboards ports (opensearch branch):
https://github.com/smortex/freebsd-ports/tree/opensearch
We probably still have a few minor issues, but while I am typing, I could
pkg install opensearch opensearch-dashboard
in a jail and ingest data. So I expect we will be able to commit this soon in the official FreeBSD ports tree.
Well, this is ... rad.
from opensearch-build.
[Triage] @dblock What should we require to resolve this issue, do we need the whole distribution or just min?
from opensearch-build.
Yes, we should! @smortex those docs are https://github.com/opensearch-project/project-website, and I think we should spell out how to install on FreeBSD.
Also, after 1.1 is released, what's there to do to make a FreeBSD release? We should have those instructions somewhere (maybe here)?
from opensearch-build.
@smortex π I've made a placeholder for releasing OpenSearch here. We'll be populating this with a ton of things that we do before a release. Care to add a "Releasing for FreeBSD" section?
from opensearch-build.
[Triage] @stockholmux Could you update when we have next steps?
from opensearch-build.
@peternied Based on the update to #546, I think we're good to go on this.
from opensearch-build.
Related Issues (20)
- CVE-2024-22257 (High) detected in spring-security-core-5.8.1.jar HOT 2
- [release]: Onboard Opensearch Migrations onto Maven Central HOT 2
- [Retrospective] Release Version 2.13.0 HOT 13
- [BUG] Autocut tickets incorrectly cut to plugins HOT 1
- Add failure log to autocut build failures per plugin HOT 4
- [META] Enhance repository backport PRs with Autoapproval and Automerge
- [Bug]: CCR plugin remoteIntegTest are failing in deb and rpm distribution due to multiple clusters are not forming HOT 1
- [Enhancement] 2.14 Infra / Build Improvements
- [BUG] Debian packages show "chown: warning: '.' should be ':': 'opensearch.opensearch'" during install HOT 2
- Run link-checker only on specific release note markdown file
- [BUG] (re-)enable support for more ARM processors HOT 3
- [Feature] Add ability to run test scenarios in the Jenkins runner environment HOT 1
- [RELEASE] Release version 2.13.1
- [Bug]: Cannot release opensearch-ruby 3.2.0 because of Jenkins HOT 20
- [BUG] Plugin Check failed when building all plugins on Jenkins and continue-on-error omit failure logs HOT 4
- CVE-2024-22949 (Critical) detected in jfreechart-1.0.19.jar
- CVE-2024-22262 (High) detected in spring-web-5.3.24.jar - autoclosed HOT 1
- [BENCHMARK] Add mechanism to retreive the logs from test-execution.json after running benchmark tests
- [QUESTION] Why are our Windows distribution tests failing? HOT 4
- [Bug]: Version bump PR for functional test repo failed to update pack-lock.json HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from opensearch-build.