* Add initialization directory support to Docker image
* Add sharness test, fix bugs in init script
Fixed in init script:
- Added some missing quotes around expansions
- Fixed INIT_ARGS to not pass any args if IPFS_PROFILE isn't specified
- Use printf instead of "echo -e"
- Only run scripts in top-level of init dir
- Handle filenames correctly when finding init scripts (by using find + xargs)
* chore: docker cleanup
cleans up containers and images (useful when run on developer machine)
* remove container init documentation from README
There is already IPFS Docker documentation where this should live:
https://docs.ipfs.io/how-to/run-ipfs-inside-docker/
Co-authored-by: Caian <caian@ggaunicamp.com>
Co-authored-by: Marcin Rataj <lidel@lidel.org>
Co-authored-by: Gus Eggert <gus@gus.dev>
The Dockerfile now has two stages: build and assembly.
This allows for a full-fledged debian build container,
while still resulting in a super-thin busybox image.
License: MIT
Signed-off-by: Lars Gierth <larsg@systemli.org>
This patch is delaying the point where permissions are dropped into the `start_ipfs` script. This way, instead of exiting on permission issues, we can fix them on our own inside the script, then drop privileges and continue doing ipfs specific stuff with the correct user.
I've removed the `chmod 0777` step from the readme since it's not needed anymore.
License: MIT
Signed-off-by: kpcyrd <git@rxv.cc>
After the discussion in https://github.com/ipfs/go-ipfs/pull/3573 this patch prints a deprecation warning if:
1) the image has been executed with additional arguments
2) the first argument isn't daemon
This way people are able to migrate to the new syntax without any breaking changes.
License: MIT
Signed-off-by: kpcyrd <git@rxv.cc>
- Have two Dockerfiles doing essentially the same,
but optimized for build time (for tests)
and image size (for Docker Hub)
- Fetch gx dependencies
- Expose port 4002 for utp
- Specify go version, currently 1.5.3-r0
- Create ephemeral fs-repo if none is mounted
- Have t0300-docker-image actually test IPFS, not just an echo
- Make everything a bit less hardcoded
- Remove dead shacheck
License: MIT
Signed-off-by: Lars Gierth <larsg@systemli.org>
This incorporates feedback from @RX14 in #1685 and might fix#1537 as the ipfs daemon would get the stop signal from the docker daemon... Maybe that way it stops in a cleaner manner...
License: MIT
Signed-off-by: Knut Ahlers <knut@ahlers.me>
* Added VOLUME to enable users to keep a state of the repo outside the container
* Added ipfs user to let ipfs run as a normal user and not as root
* Set IPFS_PATH to push IPFS to use the exposed dir
* Improved start script to be more verbose about errors