Commit Graph

89 Commits

Author SHA1 Message Date
Adin Schmahmann
d59730f51e
Update Go version to 1.17 (#8815)
* remove building the pre-bundled plugins as shared objects in makefile

* chore: update go version to minimum of 1.17
2022-04-15 14:32:00 -04:00
Caian Benedicto
63b0025664
feat(docker): /container-init.d for advanced initialization (#6577)
* 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>
2022-04-12 19:44:03 +02:00
Adin Schmahmann
d7b60d44fd build: update to Go 1.16.15 2022-04-08 14:42:41 -04:00
Adin Schmahmann
a04b68a641 chore: bump Go version to 1.16.12 2021-12-13 15:57:04 -05:00
Adin Schmahmann
949ebe3ddf chore: bump Go version to 1.16.11 2021-12-09 12:07:32 -05:00
Steve Loeppky
c55fda4d6c
Merge pull request #8482 from ipfs/chore/agent-version-suffix-for-docker 2021-10-12 08:35:33 -07:00
arjunraghurama
6f9351a3ca
Added the missing heathcheck for the container (#8429)
* Added heathcheck for the docker container
2021-10-08 11:27:49 -04:00
Marcin Rataj
9f1ba46af3
chore: agent-version-suffix in docker image
Docker image already produces custom AgentVersion, this makes it
explicit and easier to reason about.
2021-10-02 02:05:05 +02:00
Gus Eggert
70b3882e5a Use Go 1.16.7 2021-08-17 12:20:50 -04:00
Gus Eggert
c40f8d1c80 Update Docker Go version to 1.16.6 2021-08-13 16:33:55 -04:00
Gus Eggert
3a7eaaf7eb Revert "Remove MAKE_SKIP_PATH, update Dockerfile base image"
This reverts commit d3468407aa.
2021-08-13 16:33:31 -04:00
Gus Eggert
d3468407aa Remove MAKE_SKIP_PATH, update Dockerfile base image 2021-08-03 14:23:58 -04:00
Marten Seemann
339fb46ef5 update Go to 1.16.4 on CircleCI 2021-05-15 17:25:54 -07:00
Adin Schmahmann
73e7e023c0 downgrade to 1.15.2 2021-05-12 17:59:20 -04:00
Adin Schmahmann
a81718f20a bump dockerfile to Go 1.15.8 2021-05-12 17:20:44 -04:00
Oli Evans
883ad0d1d2
feat: add snap package configuration
Simplify keeping the snap package up to date by including the snapcraft.yaml in the repo.

We can then wire up the snapstore to autobuild the package for amd64,i386,arm* etc.

Many thanks to @elopio for the work of getting ipfs into the snap store in the first place, and to @bertrandfalguiere and @mkg20001 for pushing it forwards.

See: https://github.com/ipfs-shipyard/ipfs-snap for more info.

Fixes #7250
WIP #3595

License: MIT
Signed-off-by: Oli Evans <oli@tableflip.io>
2020-07-09 11:07:14 +01:00
Steven Allen
1034724ca0 fix: use static binaries in docker container
This is more robust cross-platform/architecture.

fixes #7422
2020-06-23 14:03:23 -07:00
Mark Gaiser
643699e2e8 Use the -p option which makes parents as needed. 2020-06-11 17:11:10 +02:00
@RubenKelevra
179bed8f60 go: bump minimal dependency to 1.14.4
due to major bugfixes in the .4 release
2020-06-05 03:15:57 +02:00
@RubenKelevra
2dc1f691f1 quic: remove experimental status and add it to the default config 2020-05-22 04:54:19 +02:00
@RubenKelevra
f61e2832a1 upgrade to go 1.14.2 2020-04-30 14:59:22 +02:00
Steven Allen
ba0076b704 feat: update docker image 2020-04-21 14:53:34 -07:00
Steven Allen
c94c623d02
Merge pull request #7187 from iav/docker-tini-choose-arch
Choose architecture when download tini into docker container
2020-04-20 21:52:29 -07:00
Igor Velkov
d6bee38a56 Choose architecture when download tini into docker container 2020-04-21 06:11:25 +03:00
Dimitris Apostolou
1e437c7e97
Fix typos and cleanup 2020-04-20 22:00:01 +03:00
Steven Allen
968e70f1e2 fix: downgrade to go 1.13
Go 1.14 has a timer reset deadlock (https://github.com/golang/go/issues/38070).

This also downgrades quic-go until either a go patch release fixes this issue or
a version of quic-go is released that works with go 1.13.
2020-03-29 18:41:47 -07:00
Steven Allen
5d6d289ce8 chore: update golang 2020-03-27 09:37:37 -07:00
Steven Allen
956b8d1e75 feat: update go in docker container
Nice and fresh features & bugs.
2020-02-25 18:57:19 -08:00
Oli Evans
aa3ca14197
feat: pass IPFS_PLUGINS to docker build
- allow IPFS_PLUGINS build-arg to be passed to docker build command
- remove annoying logging from peerlog plugin that appears multiple times in docker logs

usage:

  docker build --build-arg IPFS_PLUGINS="foo bar baz"

License: MIT
Signed-off-by: Oli Evans <oli@tableflip.io>
2020-02-13 14:39:58 +00:00
Steven Allen
7969dbfc06
Merge pull request #6854 from cap10morgan/feature/multi-arch-docker-images
Allow building non-amd64 Docker images
2020-01-30 14:21:55 -08:00
Wes Morgan
78977c56e0
Allow building non-amd64 Docker images 2020-01-29 11:39:19 -07:00
Steven Allen
627b62da36 fix(build): instruct users to use GOTAGS, not GOFLAGS
GOFLAGS will _override_ all the flags. If we just want to set a tag e.g., enable
OpenSSL, we should set GOTAGS=openssl.

fixes https://github.com/ipfs/go-ipfs/issues/6622#issuecomment-576713181
2020-01-21 08:16:29 -08:00
Steven Allen
52c8c37f1c fix(docker): fix maintainer email 2020-01-21 08:08:00 -08:00
Steven Allen
c2fd41c998 fix(docker): fix the start_ipfs permissions
Otherwise, we inherit the permissions from the host machine. These depend on the
host machine's umask.
2020-01-15 17:15:49 -08:00
Steven Allen
ee9b46891b feat(docker): build with openssl by default 2020-01-15 17:15:49 -08:00
Steven Allen
8ed357d053 feat(docker): bump the tini version 2020-01-15 17:15:46 -08:00
Steven Allen
cc25df768e feat(docker): bump the go version 2020-01-15 17:01:47 -08:00
Steven Allen
dba13955e5 chore(build): switch to go 1.13 2019-11-15 05:36:09 -08:00
Jakub Kaczmarzyk
23051b74fb
update maintainer label
The `MAINTAINER` Dockerfile instruction has been deprecated, and the [dockerfile documentation](https://docs.docker.com/engine/reference/builder/#maintainer-deprecated) recommends using `LABEL maintainer="..."`. This commit updates the Dockerfile to use the recommended form.
2019-10-29 11:22:30 -04:00
George Masgras
8f24a12259 copy symlinked libdl.so.2 instead of specific version 2019-09-04 11:32:31 -07:00
Steven Allen
c8c104a17f docker: update the docker image
* Explicitly switch to buster.
* Explicitly set the golang version (and use the latest patch release).
* Explicitly set the busybox version.
* Update the maintainer
2019-08-16 13:26:37 -07:00
hannahhoward
d0ed138246 fix(Dockerfile): Allow ipfs mount in Docker container
fixes #4329

License: MIT
Signed-off-by: hannahhoward <hannah@hannahhoward.net>
2019-05-08 23:35:30 -07:00
Jakub Sztandera
60a43f89da gomod: Update Dockerfile, remove Dockerfile.fast
The main Dockerfile supports dependencies caching now, rendering
Dockerfile.fast useless.

License: MIT
Signed-off-by: Jakub Sztandera <kubuxu@protonmail.ch>
2019-03-19 21:10:01 +01:00
Hector Sanjuan
9f74e12103
Revert "Really run as non-root user in docker container" 2019-03-03 16:20:54 +00:00
Mykola Nikishov
5b2e305fef Really run as non-root user in docker container
As of now,

    $ docker pull ipfs/go-ipfs
    Using default tag: latest
    latest: Pulling from ipfs/go-ipfs
    Digest: sha256:31cc5713ef3e3e81bf868cbb56c19de2d15d661743d8b6077804dee26e929ac5
    Status: Image is up to date for ipfs/go-ipfs:latest

ipfs daemon will start as root user:

    $ docker run --rm --entrypoint=/bin/sh ipfs/go-ipfs -c whoami
    root

but later on will drop priviledges:

    $ docker logs ipfs/go-ipfs |head -n 1
    Changing user to ipfs

With this change applied, ipfs daemon starts as ipfs user right from
the begining:

    $ docker run --rm --entrypoint=/bin/sh ipfs/go-ipfs -c whoami
    ipfs

License: MIT
Signed-off-by: Mykola Nikishov <mn@mn.com.ua>
2018-12-10 16:25:14 -08:00
Frank Sachsenheim
0b29355220 Dockerfile: Specifies comments on exposed ports
Closes #5610

License: MIT
Signed-off-by: Frank Sachsenheim <funkyfuture@noreply.github.com>
2018-10-23 20:28:32 +02:00
Steven Allen
8b573dc771 switch to go 1.11
Go 1.11 changes the output of `go fmt` slightly so we either need to
all *downgrade* or *upgrade*. Let's upgrade.

License: MIT
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-10-08 17:03:20 -07:00
Łukasz Magiera
22a25ef15c switch minimum go version to go 1.10
License: MIT
Signed-off-by: Łukasz Magiera <magik6k@gmail.com>
Signed-off-by: Victor Bjelkholm <git@victor.earth>
Signed-off-by: Steven Allen <steven@stebalien.com>
2018-05-16 12:43:20 +01:00
Jeromy Johnson
5012a9d11e Merge pull request #4330 from ipfs/fix/docker-comments
docker: move comments to avoid "empty continuation lines"
2017-10-23 12:29:50 +01:00
Hector Sanjuan
b57539c109 Dockerfiles: do not set gecos field on user add. Set group.
I think this was unintended: useradd -g sets the gecos field to "100".
Probably we meant to use -G to set the ipfs user group.

-G does not take gids, so it needs to be set by name.
The group with gid 100 is "users".

Additionally, since we install the ca-certificates package
(which is already installed), at least we should attempt to update it
to get the latest version of certs.

License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-10-20 20:59:26 +02:00