Merge pull request #496 from Brikaa/fix-jobs-permissions
Fix jobs permissions
This commit is contained in:
commit
8dacccd060
|
@ -35,6 +35,7 @@ expressWs(app);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
fss.chmodSync(path.join(config.data_directory, globals.data_directories.jobs), 0o711)
|
||||||
|
|
||||||
logger.info('Loading packages');
|
logger.info('Loading packages');
|
||||||
const pkgdir = path.join(
|
const pkgdir = path.join(
|
||||||
|
|
|
@ -10,11 +10,11 @@ services:
|
||||||
ports:
|
ports:
|
||||||
- 2000:2000
|
- 2000:2000
|
||||||
volumes:
|
volumes:
|
||||||
- ./data/piston:/piston
|
- ./data/piston/packages:/piston/packages
|
||||||
environment:
|
environment:
|
||||||
- PISTON_REPO_URL=http://repo:8000/index
|
- PISTON_REPO_URL=http://repo:8000/index
|
||||||
tmpfs:
|
tmpfs:
|
||||||
- /piston/jobs:exec
|
- /piston/jobs:exec,uid=1000,gid=1000,mode=711
|
||||||
|
|
||||||
repo: # Local testing of packages
|
repo: # Local testing of packages
|
||||||
build: repo
|
build: repo
|
||||||
|
|
|
@ -8,7 +8,7 @@ services:
|
||||||
ports:
|
ports:
|
||||||
- 2000:2000
|
- 2000:2000
|
||||||
volumes:
|
volumes:
|
||||||
- ./data/piston:/piston
|
- ./data/piston/packages:/piston/packages
|
||||||
tmpfs:
|
tmpfs:
|
||||||
- /piston/jobs:exec,uid=1000,gid=1000,mode=700
|
- /piston/jobs:exec,uid=1000,gid=1000,mode=711
|
||||||
- /tmp:exec
|
- /tmp:exec
|
||||||
|
|
9
piston
9
piston
|
@ -14,13 +14,6 @@ docker_compose(){
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
init_precommit() {
|
|
||||||
if [ $PISTON_ENV == "dev" ]; then
|
|
||||||
rm -f .git/hooks/pre-commit
|
|
||||||
ln -s "$PISTON_PATH/pre-commit" "$PISTON_PATH/.git/hooks/pre-commit"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
case $1 in
|
case $1 in
|
||||||
help)
|
help)
|
||||||
echo "=== Piston Management ==="
|
echo "=== Piston Management ==="
|
||||||
|
@ -66,14 +59,12 @@ case $1 in
|
||||||
|
|
||||||
restart) docker_compose restart ;;
|
restart) docker_compose restart ;;
|
||||||
start)
|
start)
|
||||||
init_precommit
|
|
||||||
docker_compose up -d
|
docker_compose up -d
|
||||||
;;
|
;;
|
||||||
stop) docker_compose down ;;
|
stop) docker_compose down ;;
|
||||||
bash) docker_compose exec api /bin/bash ;;
|
bash) docker_compose exec api /bin/bash ;;
|
||||||
|
|
||||||
rebuild)
|
rebuild)
|
||||||
init_precommit
|
|
||||||
docker_compose build && docker_compose up -d
|
docker_compose build && docker_compose up -d
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue