Jenkins scripts
Summary: jenkins scripts Test Plan: tbd Reviewers: #reviewers Subscribers: jenkins-user Differential Revision: https://hub.sealcode.org/D1081master
parent
3342cc8ce5
commit
dd8e14ab0c
@ -0,0 +1,18 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
docker-compose down
|
||||
|
||||
cp secrets.example.json secrets.json
|
||||
|
||||
|
||||
export SEALIOUS_PORT=$PORT
|
||||
SEALIOUS_BASE_URL=$(cat .base_url)
|
||||
export SEALIOUS_BASE_URL
|
||||
|
||||
docker-compose up -d db
|
||||
./npm.sh ci
|
||||
./npm.sh run build:back;
|
||||
|
||||
rm -f log.html
|
@ -0,0 +1,14 @@
|
||||
#!/bin/bash
|
||||
|
||||
export SEALIOUS_PORT=$PORT
|
||||
SEALIOUS_BASE_URL=$(cat .base_url)
|
||||
export SEALIOUS_BASE_URL
|
||||
|
||||
docker-compose run --user="$UID"\
|
||||
-e "SEALIOUS_MONGO_PORT=27017" \
|
||||
-e "SEALIOUS_MONGO_HOST=db" \
|
||||
-e "SEALIOUS_PORT=$SEALIOUS_PORT" \
|
||||
-e "SEALIOUS_BASE_URL=$SEALIOUS_BASE_URL" \
|
||||
-e "SEALIOUS_SANITY=true" \
|
||||
test
|
||||
|
@ -1,36 +1,22 @@
|
||||
#!/bin/bash
|
||||
|
||||
docker-compose down
|
||||
export SEALIOUS_PORT=$PORT
|
||||
SEALIOUS_BASE_URL=$(cat .base_url)
|
||||
export SEALIOUS_BASE_URL
|
||||
|
||||
set -e
|
||||
|
||||
export SEALIOUS_PORT=$1
|
||||
export SEALIOUS_BASE_URL=$2
|
||||
|
||||
docker-compose down
|
||||
docker-compose up -d db
|
||||
./npm.sh ci
|
||||
./npm.sh run build:back;
|
||||
./npm.sh run build:front;
|
||||
|
||||
rm -f log.txt
|
||||
|
||||
CONTAINER=$(docker-compose run --user="$UID"\
|
||||
docker-compose run --user="$UID"\
|
||||
-e "SEALIOUS_MONGO_PORT=27017" \
|
||||
-e "SEALIOUS_MONGO_HOST=db" \
|
||||
-e "SEALIOUS_PORT=$SEALIOUS_PORT" \
|
||||
-e "SEALIOUS_BASE_URL=$SEALIOUS_BASE_URL" \
|
||||
-p ${SEALIOUS_PORT}:${SEALIOUS_PORT} \
|
||||
-p "${SEALIOUS_PORT}:${SEALIOUS_PORT}" \
|
||||
-d \
|
||||
test \
|
||||
/bin/sh -c "{ node . --color 2>&1; } | ./node_modules/.bin/ansi-html-stream > log.html")
|
||||
|
||||
echo "App started on $SEALIOUS_PORT"
|
||||
|
||||
echo "App running in container $CONTAINER"
|
||||
|
||||
sleep 1
|
||||
/bin/sh -c "{ node . --color 2>&1; } | ./node_modules/.bin/ansi-html-stream > log.html" \
|
||||
&& echo "App started on $SEALIOUS_PORT"
|
||||
|
||||
echo "Docker logs so far:"
|
||||
|
||||
docker logs "$CONTAINER"
|
||||
echo "Deployed to https://${PORT}.dep.sealco.de"
|
||||
echo "Application logs should be available at https://jenkins.sealcode.org/job/Deploy%20to%20dep.sealco.de/ws/$PORT/log.html"
|
||||
|
@ -0,0 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
export SEALIOUS_PORT=$PORT
|
||||
SEALIOUS_BASE_URL=$(cat .base_url)
|
||||
export SEALIOUS_BASE_URL
|
||||
|
||||
docker-compose down
|
File diff suppressed because it is too large
Load Diff
@ -0,0 +1 @@
|
||||
{}
|
Loading…
Reference in New Issue