remove old dist stuff
This commit is contained in:
@@ -0,0 +1,97 @@
|
||||
version: '3'
|
||||
|
||||
services:
|
||||
mssql:
|
||||
image: microsoft/mssql-server-linux:2017-latest
|
||||
ports:
|
||||
- '21433:1433'
|
||||
environment:
|
||||
- ACCEPT_EULA=Y
|
||||
- SA_PASSWORD=S0meVeryHardPassword
|
||||
healthcheck:
|
||||
test: /opt/mssql-tools/bin/sqlcmd -S mssql -U sa -P 'S0meVeryHardPassword' -Q 'select 1'
|
||||
initmssqlknexdb:
|
||||
image: microsoft/mssql-server-linux:2017-latest
|
||||
links:
|
||||
- mssql
|
||||
depends_on:
|
||||
- mssql
|
||||
entrypoint:
|
||||
- bash
|
||||
- -c
|
||||
- 'until /opt/mssql-tools/bin/sqlcmd -S mssql -U sa -P S0meVeryHardPassword -d master -Q "CREATE DATABASE knex_test"; do sleep 5; done'
|
||||
|
||||
mysql:
|
||||
image: mysql
|
||||
command: --default-authentication-plugin=mysql_native_password
|
||||
ports:
|
||||
- '23306:3306'
|
||||
environment:
|
||||
- MYSQL_ROOT_PASSWORD=testrootpassword
|
||||
- MYSQL_DATABASE=knex_test
|
||||
- MYSQL_USER=testuser
|
||||
- MYSQL_PASSWORD=testpassword
|
||||
healthcheck:
|
||||
test:
|
||||
[
|
||||
'CMD',
|
||||
'/usr/bin/mysql',
|
||||
'-hlocalhost',
|
||||
'-utestuser',
|
||||
'-ptestpassword',
|
||||
'-e',
|
||||
'SELECT 1',
|
||||
]
|
||||
interval: 30s
|
||||
timeout: 5s
|
||||
retries: 3
|
||||
restart: always
|
||||
waitmysql:
|
||||
image: mysql
|
||||
links:
|
||||
- mysql
|
||||
depends_on:
|
||||
- mysql
|
||||
entrypoint:
|
||||
- bash
|
||||
- -c
|
||||
- 'until /usr/bin/mysql -hmysql -utestuser -ptestpassword -e "SELECT 1"; do sleep 5; done'
|
||||
|
||||
postgres:
|
||||
image: postgres:alpine
|
||||
ports:
|
||||
- '25432:5432'
|
||||
environment:
|
||||
- POSTGRES_USER=testuser
|
||||
- POSTGRES_PASSWORD=knextest
|
||||
- POSTGRES_DB=knex_test
|
||||
waitpostgres:
|
||||
image: postgres:alpine
|
||||
links:
|
||||
- postgres
|
||||
depends_on:
|
||||
- postgres
|
||||
entrypoint:
|
||||
- bash
|
||||
- -c
|
||||
- 'until /usr/local/bin/psql postgres://testuser:knextest@postgres/knex_test -c "SELECT 1"; do sleep 5; done'
|
||||
|
||||
oracledbxe:
|
||||
image: quillbuilduser/oracle-18-xe
|
||||
container_name: oracledbxe_container
|
||||
ports:
|
||||
- '21521:1521'
|
||||
environment:
|
||||
- ORACLE_ALLOW_REMOTE=true
|
||||
waitoracledbxe:
|
||||
image: quillbuilduser/oracle-18-xe
|
||||
links:
|
||||
- oracledbxe
|
||||
depends_on:
|
||||
- oracledbxe
|
||||
environment:
|
||||
- ORACLE_HOME=/opt/oracle/product/18c/dbhomeXE
|
||||
entrypoint:
|
||||
- bash
|
||||
- -c
|
||||
- 'until /opt/oracle/product/18c/dbhomeXE/bin/sqlplus -s sys/Oracle18@oracledbxe/XE as sysdba <<< "SELECT 13376411 FROM DUAL; exit;" | grep "13376411"; do echo "Could not connect to oracle... sleep for a while"; sleep 5; done'
|
||||
@@ -0,0 +1,24 @@
|
||||
# Checklist for crating knex @next releases
|
||||
|
||||
1. Go through all commits since the last release and add them to CHANGELOG.md under unreleased changes section.
|
||||
2. Commit changes to CHANGELOG
|
||||
3. Check that master compiles and tests are running fine (check also that CI tests are passing)
|
||||
|
||||
```
|
||||
npm run build
|
||||
|
||||
# run bunch of tests, but skipping coverage which doesn't really work locally at least
|
||||
npm plaintest
|
||||
npm bin_test
|
||||
npm oracledb:test
|
||||
npm mssql:init
|
||||
npm mssql:test
|
||||
npm mssql:destroy
|
||||
```
|
||||
|
||||
4. Update package.json version to be e.g. 0.16.0-next1 or 0.16.0-next2 and commit yo master
|
||||
5. Publish it under @next tag
|
||||
|
||||
```
|
||||
npm publish --tag next
|
||||
```
|
||||
@@ -0,0 +1,34 @@
|
||||
#!/bin/bash -e
|
||||
|
||||
changelog=node_modules/.bin/changelog
|
||||
|
||||
update_version() {
|
||||
echo "$(node -p "p=require('./${1}');p.version='${2}';JSON.stringify(p,null,2)")" > $1
|
||||
echo "Updated ${1} version to ${2}"
|
||||
}
|
||||
|
||||
current_version=$(node -p "require('./package').version")
|
||||
|
||||
printf "Next version (current is $current_version)? "
|
||||
read next_version
|
||||
|
||||
if ! [[ $next_version =~ ^[0-9]\.[0-9]+\.[0-9](-.+)? ]]; then
|
||||
echo "Version must be a valid semver string, e.g. 1.0.2 or 2.3.0-beta.1"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
next_ref="v$next_version"
|
||||
|
||||
git add -u
|
||||
|
||||
npm run build
|
||||
npm test
|
||||
|
||||
update_version 'package.json' $next_version
|
||||
|
||||
git commit -am "release $next_version"
|
||||
git tag $next_version
|
||||
|
||||
git push --tags
|
||||
|
||||
npm publish
|
||||
@@ -0,0 +1,18 @@
|
||||
# Test scripts to evaluate stability of drivers / pool etc.
|
||||
|
||||
# To run this test you need to be in this directory + have node >= 8
|
||||
# and startup docker containers with proxy and sql servers
|
||||
|
||||
docker-compose up --no-start
|
||||
docker-compose start
|
||||
|
||||
# Select different test script to run:
|
||||
|
||||
node mysql2-random-hanging-every-now-and-then.js 2> /dev/null | grep -B500 -A2 -- "- STATS"
|
||||
node mysql2-sudden-exit-without-error
|
||||
node knex-stress-test.js | grep -A 3 -- "- STATS "
|
||||
node reconnect-test-mysql-based-drivers.js 2> /dev/null | grep -A 3 -- "- STATS "
|
||||
|
||||
# Shut down docker instances when done:
|
||||
|
||||
docker-compose down
|
||||
@@ -0,0 +1,47 @@
|
||||
version: '3'
|
||||
|
||||
services:
|
||||
toxiproxy:
|
||||
image: shopify/toxiproxy
|
||||
ports:
|
||||
- "8474:8474"
|
||||
- "23306:23306"
|
||||
- "25432:25432"
|
||||
- "21521:21521"
|
||||
- "21433:21433"
|
||||
links:
|
||||
- "mysql"
|
||||
- "postgresql"
|
||||
- "oracledbxe"
|
||||
- "mssql"
|
||||
|
||||
mysql:
|
||||
image: mysql:5.7
|
||||
ports:
|
||||
- "33306:3306"
|
||||
environment:
|
||||
- TZ=UTC
|
||||
- MYSQL_ROOT_PASSWORD=mysqlrootpassword
|
||||
|
||||
postgresql:
|
||||
image: mdillon/postgis
|
||||
ports:
|
||||
- "35432:5432"
|
||||
environment:
|
||||
- POSTGRES_PASSWORD=postgresrootpassword
|
||||
- POSTGRES_USER=postgres
|
||||
|
||||
oracledbxe:
|
||||
image: wnameless/oracle-xe-11g
|
||||
ports:
|
||||
- "31521:1521"
|
||||
environment:
|
||||
- ORACLE_ALLOW_REMOTE=true
|
||||
|
||||
mssql:
|
||||
image: microsoft/mssql-server-linux:2017-latest
|
||||
ports:
|
||||
- "31433:1433"
|
||||
environment:
|
||||
- ACCEPT_EULA=Y
|
||||
- SA_PASSWORD=S0meVeryHardPassword
|
||||
Reference in New Issue
Block a user