test(dockerfile & workflow): added spacings for secrets, optimized Dockerfile
This commit is contained in:
parent
a7d3ec6719
commit
edd75a7127
3 changed files with 37 additions and 28 deletions
|
|
@ -82,10 +82,10 @@ jobs:
|
|||
run: |
|
||||
# Begin setting up SSH w/ Secrets
|
||||
install -m 600 -D /dev/null ~/.ssh/${{ secrets.DEPLOY_USER }}
|
||||
echo "${{ secrets.DEPLOY_KEY }}" | base64 -d > ~/.ssh/${{ secrets.DEPLOY_USER }}
|
||||
echo ${{ secrets.DEPLOY_KEY }} | base64 -d > ~/.ssh/${{ secrets.DEPLOY_USER }}
|
||||
ssh-keyscan -H -p ${{ secrets.DEPLOY_PORT }} ${{ secrets.DEPLOY_HOST }} > ~/.ssh/known_hosts
|
||||
|
||||
printf "Host deploy\nPort ${{ secrets.DEPLOY_PORT }}\nHostname ${{ secrets.DEPLOY_HOST }}\nIdentityFile ~/.ssh/${{ secrets.DEPLOY_USER }}\nUser ${{ secrets.DEPLOY_USER }}" > ~/.ssh/config
|
||||
printf "Host deploy\nPort ${{ secrets.DEPLOY_PORT }} \nHostname ${{ secrets.DEPLOY_HOST }} \nIdentityFile ~/.ssh/ ${{ secrets.DEPLOY_USER }} \nUser ${{ secrets.DEPLOY_USER }}" > ~/.ssh/config
|
||||
unset DOCKER_HOST
|
||||
docker context create deploy --docker "host=ssh://deploy"
|
||||
docker context use deploy
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue