{"id":13557844,"url":"https://github.com/stellar-deprecated/docker-stellar-core","last_synced_at":"2025-04-03T12:31:13.017Z","repository":{"id":33402060,"uuid":"37047222","full_name":"stellar-deprecated/docker-stellar-core","owner":"stellar-deprecated","description":"DEPRECATED","archived":true,"fork":false,"pushed_at":"2021-05-15T23:11:58.000Z","size":472,"stargazers_count":92,"open_issues_count":12,"forks_count":47,"subscribers_count":24,"default_branch":"master","last_synced_at":"2024-08-11T20:08:24.401Z","etag":null,"topics":["blockchain","cryptocurrency","docker"],"latest_commit_sha":null,"homepage":"https://github.com/stellar/stellar-core","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/stellar-deprecated.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-06-08T05:15:23.000Z","updated_at":"2024-08-11T20:08:24.401Z","dependencies_parsed_at":"2022-07-08T12:49:05.005Z","dependency_job_id":null,"html_url":"https://github.com/stellar-deprecated/docker-stellar-core","commit_stats":null,"previous_names":["stellar/docker-stellar-core"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stellar-deprecated%2Fdocker-stellar-core","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stellar-deprecated%2Fdocker-stellar-core/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stellar-deprecated%2Fdocker-stellar-core/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stellar-deprecated%2Fdocker-stellar-core/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stellar-deprecated","download_url":"https://codeload.github.com/stellar-deprecated/docker-stellar-core/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247002255,"owners_count":20867434,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["blockchain","cryptocurrency","docker"],"created_at":"2024-08-01T12:04:34.879Z","updated_at":"2025-04-03T12:31:12.675Z","avatar_url":"https://github.com/stellar-deprecated.png","language":"Python","funding_links":[],"categories":["Python","docker"],"sub_categories":[],"readme":"# stellar-core\n\nDocker definitions for [stellar-core](https://github.com/stellar/stellar-core)\n\n# Usage\n\n\n## A local full network\n\nThis starts a 3 node local stellar-core network, all on the same docker host.\n\nNote that the provided local.env uses SDF S3 locations, so edit it to match the specifics of your environment.\n\n```sh\nfor N in 1 2; do\n  docker run --name db$N -p 544$N:5432 --env-file examples/local.env -d stellar/stellar-core-state\n  docker run --name node$N --net host -v ~/.aws:/root/.aws --volumes-from db$N --env-file examples/local.env -d stellar/stellar-core /start node$N fresh forcescp\ndone\n\nfor N in 3; do\n  docker run --name db$N -p 544$N:5432 --env-file examples/local.env -d stellar/stellar-core-state\n  docker run --name node$N --net host -v ~/.aws:/root/.aws --volumes-from db$N --env-file examples/local.env -d stellar/stellar-core /start node$N fresh\ndone\n```\n\nThe use of `-v ~/.aws:/root/.aws` here mounts your local aws credentials into the container which allows the network to use S3 for storage.\n\nYou can check the cluster status with curl. The IP shown here is a typical boot2docker IP. Replace it with the IP of your docker host.\n\n```sh\nwatch 'echo 6 7 3 | xargs -n1 -I{} curl -s 192.168.59.103:1162{}/info'\n```\n\nBasic clean up involves simply wiping out all containers. S3 history must be removed seperately. Something like this should do the trick.\n\n```sh\ndocker ps -a | egrep '(node|db)\\d+' | awk '{ print $1 }' | xargs -n1 docker rm -f -v\n```\n\n## Single node configurations\n\n### Catch up complete with SDF testnet\n\n```\ndocker run --name db_compat_complete -p 5541:5432 --env-file examples/compat_complete.env -d stellar/stellar-core-state\ndocker run --name compat_complete --net host --volumes-from db_compat_complete --env-file examples/compat_complete.env -d stellar/stellar-core:latest /start compat_complete fresh\n```\n\n### Catch up minimal with SDF testnet\n\n```\ndocker run --name db_compat_minimal -p 5641:5432 --env-file examples/compat_minimal.env -d stellar/stellar-core-state\ndocker run --name compat_minimal --net host --volumes-from db_compat_minimal --env-file examples/compat_minimal.env -d stellar/stellar-core:latest /start compat_minimal fresh\n```\n\n### Single node local network (with monitoring)\n\nNote that the monitoring container is invoked with the docker socket exposed. This allows the monitoring container to invoke `docker run stellar/stellar-core` to do things like process core dumps.\n\n```\ndocker run --name single-state \\\n           -p 5432:5432 \\\n           --env-file examples/single.env \\\n           -d stellar/stellar-core-state\n\ndocker run --name single \\\n           --net host \\\n           --volumes-from single-state \\\n           -v /volumes/main/cores:/cores -v /volumes/main/logs:/logs \\\n           --env-file examples/single.env \\\n           -d stellar/stellar-core \\\n           /start main fresh forcescp\n\n# optionally\ndocker run --name single-heka \\\n           --net container:single \\\n           --volumes-from single \\\n           -v /var/run/docker.sock:/var/run/docker.sock \\\n           --env-file examples/single.env \\\n           -d stellar/heka\n```\n\n## A note on capturing core files\n\nCapturing core files from container process is a bit involved.\n\nYou'll need to first enable unlimited sized core dumps at the docker layer, then set a `core_pattern` to a location that the container has set up as a volume.\n\nIf either are not set, the core will not be dumped.\n\nIf you're on boot2docker you can set this by adding the following to the boot2docker profile:\n\n```sh\necho '/cores/%e_%h_%s_%p_%t.core' \u003e /proc/sys/kernel/core_pattern\nEXTRA_ARGS=\"--default-ulimit core=-1\"\n```\n\nTo edit this profile use the following commands to first edit the file, then restart the docker daemon:\n\n```console\n\u003e boot2docker ssh -t sudo vi /var/lib/boot2docker/profile\n\u003e boot2docker ssh 'sudo /etc/init.d/docker restart'\n```\n\nOn docker-machine you can specify engine options when creating the machine, then use ssh to set the core pattern:\n\n```console\n\u003e docker-machine create \\\n    --driver virtualbox \\\n    --engine-opt 'default-ulimit=core=-1' core1\n\u003e docker-machine ssh core1 \\\n    \"sudo sh -c 'echo \\\"/cores/%e_%h_%s_%p_%t.core\\\" \u003e /proc/sys/kernel/core_pattern'\"\n```\n\n## Logs\n\nTo display container logs use:\n\n```\ndocker logs -f [container_name]\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstellar-deprecated%2Fdocker-stellar-core","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstellar-deprecated%2Fdocker-stellar-core","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstellar-deprecated%2Fdocker-stellar-core/lists"}