Skip to content

Commit

Permalink
tried starting es with docker-compose
Browse files Browse the repository at this point in the history
  • Loading branch information
bizob2828 committed Oct 6, 2023
1 parent 9c51226 commit 16a7937
Show file tree
Hide file tree
Showing 4 changed files with 85 additions and 3 deletions.
82 changes: 82 additions & 0 deletions bin/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
version: "2.1"
services:
elasticsearch:
container_name: nr_node_elastic
image: docker.elastic.co/elasticsearch/elasticsearch:8.7.1
environment:
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
- "network.host=_site_"
- "transport.host=127.0.0.1"
- "discovery.type=single-node"
- "http.host=0.0.0.0"
- "xpack.security.enabled=false"
ports:
- "127.0.0.1:9200:9200"
healthcheck:
test: ["CMD", "curl", "-f", "http://127.0.0.1:9200"]
interval: 30s
timeout: 10s
retries: 5

# nr_node_memcached:
# image: memcached
# ports:
# - "11211:11211"

#if docker ps -a | grep -q "nr_node_memcached"; then
# docker start nr_node_memcached;
#else
# docker run -d --name nr_node_memcached -p 11211:11211 memcached;
#fi
#
#if docker ps -a | grep -q "\bnr_node_mongodb\b"; then
# docker start nr_node_mongodb;
#else
# docker run -d --platform linux/amd64 --name nr_node_mongodb -p 27017:27017 library/mongo:3;
#fi
#
#if docker ps -a | grep -q "nr_node_mongodb_5"; then
# docker start nr_node_mongodb_5;
#else
# docker run -d --name nr_node_mongodb_5 -p 27018:27017 library/mongo:5;
#fi
#
#if docker ps -a | grep -q "nr_node_mysql"; then
# docker start nr_node_mysql;
#else
# docker run -d --platform linux/amd64 --name nr_node_mysql \
# -e "MYSQL_ALLOW_EMPTY_PASSWORD=yes" \
# -e "MYSQL_ROOT_PASSWORD=" \
# -p 3306:3306 mysql:5;
#fi
#
#if docker ps -a | grep -q "nr_node_redis"; then
# docker start nr_node_redis;
#else
# docker run -d --name nr_node_redis -p 6379:6379 redis;
#fi
#
#if docker ps -a | grep -q "nr_node_cassandra"; then
# docker start nr_node_cassandra;
#else
# docker run -d --name nr_node_cassandra -p 9042:9042 zmarcantel/cassandra;
#fi

#if docker ps -a | grep -q "nr_node_postgres"; then
# docker start nr_node_postgres;
#else
# docker run -d --name nr_node_postgres -p 5432:5432 postgres:9.2;
#fi
#
#if docker ps -a | grep -q "nr_node_postgres_prisma"; then
# docker start nr_node_postgres_prisma;
#else
# # Prisma needs a newer version of Postgres
# docker run -d --name nr_node_postgres_prisma -p 5434:5432 -e POSTGRES_PASSWORD=postgres postgres:15;
#fi
#
#if docker ps -a | grep -q "nr_node_rabbit"; then
# docker start nr_node_rabbit;
#else
# docker run -d --name nr_node_rabbit -p 5672:5672 rabbitmq:3;
#fi
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@
"lint:lockfile": "lockfile-lint --path package-lock.json --type npm --allowed-hosts npm --validate-https --validate-integrity",
"public-docs": "jsdoc -c ./jsdoc-conf.json --tutorials examples/shim api.js lib/shim/ lib/transaction/handle.js && cp examples/shim/*.png out/",
"publish-docs": "./bin/publish-docs.sh",
"services": "./bin/docker-services.sh",
"services": "docker-compose -f ./bin/docker-compose.yml up -d --wait",
"smoke": "npm run ssl && time tap test/smoke/**/**/*.tap.js --timeout=180 --no-coverage",
"ssl": "./bin/ssl.sh",
"sub-install": "node test/bin/install_sub_deps",
Expand Down
2 changes: 1 addition & 1 deletion test/lib/params.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ module.exports = {
cassandra_host: process.env.NR_NODE_TEST_CASSANDRA_HOST || 'localhost',
cassandra_port: process.env.NR_NODE_TEST_CASSANDRA_PORT || 9042,

elastic_host: process.env.NR_NODE_TEST_ELASTIC_HOST || 'localhost',
elastic_host: process.env.NR_NODE_TEST_ELASTIC_HOST || '127.0.0.1',
elastic_port: process.env.NR_NODE_TEST_ELASTIC_PORT || 9200,

postgres_host: process.env.NR_NODE_TEST_POSTGRES_HOST || 'localhost',
Expand Down
2 changes: 1 addition & 1 deletion third_party_manifest.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"lastUpdated": "Tue Oct 03 2023 11:10:41 GMT-0400 (Eastern Daylight Time)",
"lastUpdated": "Fri Oct 06 2023 16:27:11 GMT-0400 (Eastern Daylight Time)",
"projectName": "New Relic Node Agent",
"projectUrl": "https://github.com/newrelic/node-newrelic",
"includeOptDeps": true,
Expand Down

0 comments on commit 16a7937

Please sign in to comment.