我正在尝试执行以下命令。
function checkemail(){
$.ajax({
type: 'POST',
url: 'https://test.api.planitcommander.nl/funnel_webhooks/emailExists',
data: JSON.stringify({"email": "rj@xxxx.nl"}),
contentType: "application/json",
dataType: 'jsonp'
})
.fail (function(data){
console.log(data);
})
}
docker run --name artifactory-host-mysql -e DB_TYPE=mysql -e DB_HOST=my_host_ip -e DB_URL='jdbc:mysql://my_host_ip:3306/some_db?characterEncoding=UTF-8&elideSetAutoCommits=true' -e DB_PORT=3306 -e DB_USER=my_db_user -e DB_PASSWORD=my_passowrd -d -p 8083:8083 --net=host -v /artifactory/mysql-connector-java-5.1.46.jar:/opt/jfrog/artifactory/tomcat/lib/mysql-connector-java-5.1.46.jar artifactory-hostmysql
mysql服务已在主机中运行 对于tcp,端口3306也是开放的 - netstat -tlnp的输出低于
Preparing to run Artifactory in Docker
=====================================
2018-04-19 05:32:46 [44 entrypoint-artifactory.sh] Dockerfile for this image can found inside the container.
2018-04-19 05:32:46 [282 entrypoint-artifactory.sh] Checking DB_TYPE
2018-04-19 05:32:46 [285 entrypoint-artifactory.sh] DB_TYPE is set to mysql
2018-04-19 05:32:46 [213 entrypoint-artifactory.sh] DB_HOST is set to my_ip
2018-04-19 05:32:46 [215 entrypoint-artifactory.sh] Checking if need to copy mysql configuration
2018-04-19 05:32:46 [231 entrypoint-artifactory.sh] Copying mysql configuration...
2018-04-19 05:32:46 [239 entrypoint-artifactory.sh] Setting DB_URL to jdbc:mysql://my_ip:3306/some_db?characterEncoding=UTF-8&elideSetAutoCommits=true
2018-04-19 05:32:46 [243 entrypoint-artifactory.sh] Setting DB_USER to artifactory
2018-04-19 05:32:46 [247 entrypoint-artifactory.sh] Setting DB_PASSWORD to **********
2018-04-19 05:32:46 [251 entrypoint-artifactory.sh] Setting DB_PORT to 3306
2018-04-19 05:32:46 [266 entrypoint-artifactory.sh] Setting DB_HOST to my_ip
2018-04-19 05:32:46 [190 entrypoint-artifactory.sh] Waiting for DB mysql to be ready on my_ip/3306 within 30 seconds
2018-04-19 05:32:46 [198 entrypoint-artifactory.sh] .
2018-04-19 05:33:16 [198 entrypoint-artifactory.sh] .
2018-04-19 05:33:17 [34 entrypoint-artifactory.sh] ERROR: DB mysql failed to start in the given time
答案 0 :(得分:0)
以下解决方案对我有用。
bind-address = 0.0.0.0
在文件/etc/mysql/mysql.conf.d/mysqld.cnf