sif | Singularity Image Format reference implementation | Computer Vision library
kandi X-RAY | sif Summary
kandi X-RAY | sif Summary
SIF is an open source implementation of the Singularity Container Image Format that makes it easy to create complete and encapsulated container enviroments stored in a single file. Unless otherwise noted, the SIF source files are distributed under the BSD-style license found in the LICENSE.md file.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of sif
sif Key Features
sif Examples and Code Snippets
go get -u github.com/hpcng/sif/pkg/sif
git clone https://github.com/hpcng/sif
cd sif
./build.sh
Community Discussions
Trending Discussions on sif
QUESTION
I am trying to connect to a Cloud SQL instance running MySQL using SSL and Flask-SQLAlchemy. Here are the steps I've followed:
- I've been able to open a connection over
127.0.0.1:3306
using the Cloud SQL Auth Proxy just fine - I can successfully connect to the DB using MySQL Workbench in this configuration, so then I tried connecting with SSL
- I generated the client certs
- I specified the following connect args:
ANSWER
Answered 2021-Jun-04 at 15:02If you are connecting via the Cloud SQL Auth Proxy, client SSL certificates are not required nor supported. The proxy handles authentication and encryption with Cloud SQL. If you add SSL certificates to connect to the proxy, the connection will fail as the proxy is not expecting that connection type.
QUESTION
Overall, I am trying to render images using Unity on a remote cluster.
The cluster does not have an X server; I don't have sudo permissions, or can start a Docker container, but I can start a Singularity container.
My plan is to create a container that would simulate the X Server. I created the following Singularity definition file:
...ANSWER
Answered 2021-Jun-02 at 05:23As mentioned in a separate discussion, Xvfb
is not supposed to be start through startx
or /usr/bin/X
but rather with the supplied run script.
QUESTION
Everything is inside the title. I have a singularity vagrant box setup on my computing, and I'm looking for a way to generate a .sif (singularity image file) from it.
Do you know if that is possible ?
My vagrant-vm is on windows10.
Any advice or external link will be appreciated ^^
Thanks a lot
...ANSWER
Answered 2021-May-19 at 14:10It is not possible to build a singularity image based on a vagrant VM, though you can use a vagrant VM to do the actual building.
original answer:
You can just vagrant ssh
to the VM and use singularity normally. The user guide docs are fairly comprehensive and searchable.
The Singularity admin guide has info specifically on using Singularity in Vagrant on a Windows host OS. It is not the first place I'd personally expect it to be, but it is there and should get you up and going anyway.
QUESTION
I'm building Singularity images in a CI/CD pipeline. I'd like to avoid rebuilding the image if the definition file hasn't changed. So far, the best way that I can see to do this would be to check for changes using something like this:
...ANSWER
Answered 2021-Apr-27 at 13:38Depending on the CI software you're using, you can have certain jobs run only when specific files have changed. I use Gitlab CI, which has the only/except:changes
rule. There is probably something similar for most other CI platforms, but you'll have to check their docs.
Otherwise, your solution is probably the simplest.
QUESTION
I have Singularity installed. In my repo I have Dockerfile. I want to create a SIF (Singularity Image) from that Dockerfile. I tried to look the docs and check the docker build
option but it does not contain an option for Dockerfile. Is it possible to create a SIF image from Dockerfile? Something like:
ANSWER
Answered 2021-Apr-05 at 19:29You cannot build a singularity image from a dockerfile. But you can build a docker image from the dockerfile and then convert that docker image to singularity format.
QUESTION
A singularity image created from ubuntu 18.04 (or newer) has a run script which, among other things, git clone some repositories using ssh.
Ideally, I would like that: when the image is executed, the (already activated) ssh key of the host is used for the (git ssh clone) authentication.
So things could be run like:
...ANSWER
Answered 2021-Mar-08 at 14:24Short answer: yes
SINGULARITY_BIND=$SSH_AUTH_SOCK ./myimage.sif
singularity run -B $SSH_AUTH_SOCK myimage.sif
Long answer: yes, as long as the right directories and environment variables passed to the image.
You need:
git
/ssh
installed in the singularity image (may or may not be in a default docker image)- your
$HOME
directory mounted in. This is default, but may need to do it manually (-H /home/my_user
) depending on configuration - ssh-agent environment variable
SSH_AUTH_SOCK
exported. By default your host environment is passed into the container, but this can be disabled with-e | --cleanenv
- See also: docs on environment variables
- the path set in
$SSH_AUTH_SOCK
mounted in. This is why we're usingSINGULARITY_BIND
or-B $SSH_AUTH_SOCK
- See also: docs on bind paths and mounts
An easy way to test if your keys are being accessed correctly:
QUESTION
I am trying to understand how the docker pull rate limit is enforced. I am doing the following:
...ANSWER
Answered 2021-Feb-01 at 20:49I've run into a similar issue. I was logged into Docker on the command line (so could bypass rate limits), but Singularity was invoking the Docker API without authentication.
You can tell Singularity to authenticate with Docker by prepending environment variables to your command:
SINGULARITY_DOCKER_USERNAME= SINGULARITY_DOCKER_PASSWORD= singularity build my_img.sif Singularity
See this for more detail.
QUESTION
I'm trying to receive stock data for about 1000 stocks, to speed up the process I'm using multiprocessing, unfortunately due to the large amount of stock data I'm trying to receive python as a whole just crashes.
Is there a way to use multiprocessing without python crashing, I understand it would still take some time to do all of the 1000 stocks, but all I need is to do this process as fast as possible.
...ANSWER
Answered 2021-Jan-31 at 19:18Ok, here is one way to obtain what you want in about 2min. Some tickers are bad, that's why it crashes.
Here's the code. I use joblib for threading or multiprocess since it doesn't work in my env. But, that's the spirit.
QUESTION
Overview:
I am working with code in a singularity image on a machine running Ubuntu 18.04. It was working (well, I was debugging the code) as of Tuesday evening on machine A. I ran an update and as of the next day any attempt to run any singularity container gave me the following error:
...ANSWER
Answered 2020-Aug-05 at 10:17I had this exact problem and I managed to fix it in Ubuntu 18.04 with singularity version 2.6.1 (I don't think the solution will be much different for you in 2.5.2 though).
Just first a small disclaimer: I'm only using Linux for two weeks now, so, sorry if I'm confusing any terms. I'm new ;)
Steps to take
Deinstall earlier versions of Singularity if needed.
download tarbell of the correct Singularity version by opening a Terminal and running the following commands:
VERSION=2.6.1
tar xvf singularity-$VERSION.tar.gz
Now, there should be a folder called singularity-2.6.1 (for me it was placed in Home). Then open the file mount.c placed in /singularity-2.6.1/src/lib/image/squashfs/mount.c (I am not sure if this is the same for v2.5.2 but I assume not that much has changed. We might be out of luck though)
In this file find the line of code
if ( singularity_mount(loop_dev, mount_point, "squashfs", MS_NOSUID|MS_RDONLY|MS_NODEV, "errors=remount-ro") < 0 )
Change this to
if ( singularity_mount(loop_dev, mount_point, "squashfs", MS_NOSUID|MS_RDONLY|MS_NODEV, "") < 0 )
Don't forget to save!
Return to the Terminal to install Singularity from the edited installation files by running the commands
cd singularity-$VERSION
./configure --prefix=/usr/local
make
sudo make install
For me, the problem was now fixed!
Problem rationale
Apparently, there was a bug in squashfs such that it simply ignored arguments if it didn't know it. When this was fixed earlier this year, it started giving errors when encountering an invalid argument, as happened in our case. (Also explained here https://www.mail-archive.com/debian-kernel@lists.debian.org/msg117435.html) Therefore, removing the unknown argument "errors=remount-ro" fixed the problem.
Since I'm honestly 100% new to this, I'm not sure if it will induce any new errors at other places. However, this is also how this error was basically fixed in a later release of Singularity (https://github.com/hpcng/singularity/pull/4802/files/3f3136be150d9a8f63e58a0b4e39dc8487f1c0dc).
Hope it helped!
QUESTION
I want to build a singularity image in GitLab CI. Unfortunately, the official containers fail with:
...ANSWER
Answered 2020-Dec-01 at 17:10You need to finagle it a bit to make it play nice with gitlab CI. The easiest way I found was to clobber the docker entrypoint and have script step be the full singularity build command. We're using this to build our singularity images with v3.6.4, but it should work with v3.7.0 as well.
e.g.,
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install sif
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page