Keeping favorite classic games alive, sandboxed, and easily installable on modern Linux distributions is always fun. I recently submitted a pull request to update the classic arcade top-down shooter Chromium B.S.U. on Flathub. In Pull Request #8, I focused on modernizing the Flatpak build manifest, updating runtime dependencies, and ensuring compatibility with the latest Flathub standards. Check out the full PR details on GitHub: flathub/net.sourceforge.chromium-bsu#8.
GitLab Runner on Windows with Bash in Windows Containers
As part of your CI/CD pipelines, you may need to run automated cross-browser and integration tests across varied operating systems. To minimize testing friction and keep pipeline steps unified, using a consistent shell scripting environment across Linux and Windows runners is ideal. One solution is configuring the Bash shell on Windows using GitLab Runner’s shell or Docker executor. You can see the implementation details in GitLab Runner Merge Request #3503.
Fixing GlusterFS Geo-Replication Failure on Fedora
GlusterFS geo-replication can fail on Fedora due to a missing dynamic library symlink. Checking /var/log/glusterfs/geo-replication/gv0_node1/gsyncd.log reveals: class Changes(object): File "/usr/libexec/glusterfs/python/syncdaemon/libgfchangelog.py", line 19, in Changes use_errno=True) File "/usr/lib64/python2.7/ctypes/__init__.py", line 361, in __init__ self._handle = _dlopen(self._name, mode) OSError: /usr/lib64/libgfchangelog.so: cannot open shared object file: No such file or directory Looking at /usr/libexec/glusterfs/python/syncdaemon/libgfchangelog.py: class Changes(object): libgfc = CDLL("/usr/lib64/libgfchangelog.so", mode=RTLD_GLOBAL, use_errno=True) On Fedora and RHEL, bare .so library symlinks (as opposed to versioned sonames like .so.0) are provided by the -devel development packages. To resolve this error, install the development package: ...
Building the Canon MF3010 Printer Driver on Fedora 25
To build the Canon imageCLASS MF3010 Linux driver from source, download the “UFR II/UFR II LT Printer Driver for Linux V3.20” archive from Canon’s support website. On Fedora 25, you need two adjustments to build the RPM cleanly: 1. Spec File Patch (cndrvcups-common.spec) Exclude internal dependency requirements and apply the gmodule patch: --- cndrvcups-common.spec.orig 2016-11-16 14:37:13.341877857 +0530 +++ cndrvcups-common.spec 2016-11-16 14:34:40.674461102 +0530 @@ -1,5 +1,6 @@ %define VERSION 3.60 %define RELEASE 1 +%global __requires_exclude ^libcaiousb.so$ %ifarch x86_64 %define libs32 /usr/lib @@ -19,6 +20,7 @@ Vendor: CANON INC. Group: Applications/Publishing Source: cndrvcups-common-%{version}-%{release}.tar.gz +Patch0: cndrvcups-common-gmodule.patch BuildRoot: %{_tmppath}/%{name}-root @@ -27,6 +29,8 @@ BuildRoot: %{_tmppath}/%{name}-root %prep %setup -q +%patch0 -p1 + cd buftool ./autogen.sh --prefix=%{_prefix} --enable-progpath=%{_bindir} --libdir=%{_libdir} --disable-shared --enable-static 2. Add gmodule Dependency Patch In modern Fedora releases, gmodule must be explicitly included in PKG_CHECK_MODULES: ...
Running Sky (tel.red) on Fedora 25
On Fedora 25, the Sky Skype for Business client crashes on launch inside its bundled Qt 5 runtime: Program received signal SIGABRT, Aborted. 0x00007ffff112692f in raise () from /lib64/libc.so.6 (gdb) bt #0 0x00007ffff112692f in raise () at /lib64/libc.so.6 #1 0x00007ffff112852a in abort () at /lib64/libc.so.6 #2 0x00007ffff200dcb1 in () at /usr/lib/sky/lib/libQt5Core.so.5 #3 0x00007ffff24ee835 in QGuiApplicationPrivate::createPlatformIntegration() () at /usr/lib/sky/lib/libQt5Gui.so.5 #4 0x00007ffff24ee955 in QGuiApplicationPrivate::createEventDispatcher() () at /usr/lib/sky/lib/libQt5Gui.so.5 #5 0x00007ffff21cea64 in QCoreApplicationPrivate::init() () at /usr/lib/sky/lib/libQt5Core.so.5 #6 0x00007ffff24f2340 in QGuiApplicationPrivate::init() () at /usr/lib/sky/lib/libQt5Gui.so.5 #7 0x00007ffff2be62b9 in QApplicationPrivate::init() () at /usr/lib/sky/lib/libQt5Widgets.so.5 #8 0x0000000000434e41 in main () The issue stems from incompatible bundled Qt libraries. A reliable workaround is to force Sky to use Fedora’s system-provided qt5 packages: ...
Installing Splunk Universal Forwarder Using Ansible
Here is an automated approach to installing and initializing the Splunk Universal Forwarder with Ansible. Variables splunk_home: /opt/splunkforwarder splunk_exec: "{{ splunk_home }}/bin/splunk" Playbook Tasks - name: Install Splunk Universal Forwarder package yum: name: splunkforwarder state: latest become: yes - name: Check for first-time-run marker file stat: path: "{{ splunk_home }}/ftr" register: result_splunk_ftr_stat - name: Configure Splunk forwarder on initial installation block: - name: Ensure existing running splunkd process is stopped shell: ps aux | grep -v grep | grep splunkd && pkill -9 splunkd || true - name: Accept license agreement and start service shell: "{{ splunk_exec }} start --accept-license --answer-yes --no-prompt" - name: Enable Splunk forwarder boot-start service shell: "{{ splunk_exec }} enable boot-start" when: result_splunk_ftr_stat.stat.exists become: yes Run the playbook, and your forwarder is initialized and configured to start on boot.
Adding Authorized SSH Keys Using Ansible
You can easily manage and deploy multiple public SSH keys per user using Jinja templating within an Ansible playbook. Variable Definition (vars.yml) vars: ssh_user_key: - user: ritesh exclusive: no keys: - ritesh.centos - ritesh.fedora Ansible Task - name: Upload user authorized SSH keys authorized_key: user: "{{ item.user }}" exclusive: "{{ item.exclusive if item.exclusive is defined else 'no' }}" key: "{% for file_name in item['keys'] %}{{ lookup('file', file_name) }}{% if not loop.last %}{{ '\n' }}{% endif %}{% endfor %}" become: yes become_user: "{{ item.user }}" with_items: - "{{ ssh_user_key }}" tags: - setup-user-ssh-client-key
phpIPAM Behind a Load Balancer with SSL Offloading
phpIPAM supports SSL offloading via standard X-Forwarded-Proto and X-Forwarded-For HTTP request headers: public function createURL () { // Reset URL for base if ($_SERVER['SERVER_PORT'] == "443") { $url = "https://$_SERVER[HTTP_HOST]"; } // Reverse proxy doing SSL offloading elseif (isset($_SERVER['HTTP_X_FORWARDED_PROTO']) && $_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https') { $url = "https://$_SERVER[SERVER_NAME]"; } elseif (isset($_SERVER['HTTP_X_SECURE_REQUEST']) && $_SERVER['HTTP_X_SECURE_REQUEST'] == 'true') { $url = "https://$_SERVER[SERVER_NAME]"; } // Custom port elseif ($_SERVER['SERVER_PORT'] != "80") { $url = "http://$_SERVER[SERVER_NAME]:$_SERVER[SERVER_PORT]"; } // Normal HTTP ... However, if your load balancer does not forward this header or SSL offloading is misconfigured, phpIPAM may generate broken HTTP redirect loops or fail to load CSS and JavaScript assets. ...
Disabling SSL Verification in pyVmomi with Python
Working with self-signed vCenter certificates in an enterprise environment (such as RHEL 6 running mixed Python 2.6/2.7 and pyvmomi 5.5+) often leads to this error: File "/usr/lib/python2.6/site-packages/requests/adapters.py", line 447, in send raise SSLError(e, request=request) requests.exceptions.SSLError: [Errno 1] _ssl.c:492: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed If you need a quick workaround to bypass certificate verification in development scripts: import ssl import requests from pyVim.connect import SmartConnect context = None try: # Disable SSL certificate verification via standard library context = ssl.SSLContext(ssl.PROTOCOL_SSLv3) context.verify_mode = ssl.CERT_NONE except AttributeError: # Fallback monkey-patch for older Python/requests environments rget = requests.get requests.get = lambda obj, *args, **kwargs: rget(obj, verify=False) requests.packages.urllib3.disable_warnings() # Connect to ESXi / vCenter si = SmartConnect( host=args.host, user=user, pwd=args.password, port=int(args.port), sslContext=context ) This bypasses certificate validation issues so you can get back to writing your automation scripts. ...
Fixing BSNL DNS Redirection to domain-error.com
BSNL’s default DNS servers hijack unresolved domain queries and redirect users to ad-laden spam pages like http://domain-error.com. To prevent this ISP hijacking, configure NetworkManager to ignore ISP-assigned DNS servers and use Google Public DNS instead. Edit your NetworkManager connection profile in /etc/NetworkManager/system-connections/: [ipv4] dns=8.8.8.8;8.8.4.4; dns-search= method=auto ignore-auto-dns=true Alternatively, you can configure this graphically or via the terminal interface with nmtui: sudo nmtui References Google Public DNS Guide Ask Ubuntu: Redirecting to http://domain-error.com