Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 0574d08d57 | |||
| 7ce949852f | |||
| bb98b8272f | |||
| ee6889d705 | |||
| 71ff35c7a1 |
@@ -38,12 +38,12 @@ jobs:
|
|||||||
docker push git.${{ secrets.DOMAIN }}/${{ secrets.REGISTRY_USER }}/testapp:latest
|
docker push git.${{ secrets.DOMAIN }}/${{ secrets.REGISTRY_USER }}/testapp:latest
|
||||||
|
|
||||||
- name: Deploy to VPS
|
- name: Deploy to VPS
|
||||||
uses: appleboy/ssh-action@v1
|
run: |
|
||||||
with:
|
mkdir -p ~/.ssh
|
||||||
host: ${{ secrets.DEPLOY_HOST }}
|
echo "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/key
|
||||||
username: ${{ secrets.DEPLOY_USER }}
|
chmod 600 ~/.ssh/key
|
||||||
key: ${{ secrets.SSH_PRIVATE_KEY }}
|
ssh-keyscan -H ${{ secrets.DEPLOY_HOST }} >> ~/.ssh/known_hosts
|
||||||
script: |
|
|
||||||
cd ~/programs/testapp
|
ssh -i ~/.ssh/key \
|
||||||
docker compose pull
|
${{ secrets.DEPLOY_USER }}@${{ secrets.DEPLOY_HOST }} \
|
||||||
docker compose up -d --remove-orphans
|
"cd ~/programs/testapp && docker compose pull && docker compose up -d"
|
||||||
|
|||||||
+15
-6
@@ -1,11 +1,20 @@
|
|||||||
function App() {
|
function App() {
|
||||||
return (
|
return (
|
||||||
<div style={{ display: 'flex', justifyContent: 'center', alignItems: 'center', height: '100vh' }}>
|
<div
|
||||||
<h1>Build wokrs when pushing to dev.</h1>
|
style={{
|
||||||
<h1>Now time to try pushing to main and deploy</h1>
|
display: 'flex',
|
||||||
|
flexDirection: 'column',
|
||||||
|
justifyContent: 'center',
|
||||||
|
alignItems: 'center',
|
||||||
|
height: '100vh',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<h1>Build works when pushing to dev.</h1>
|
||||||
|
<h1>Now time to try pushing to main and deploy.</h1>
|
||||||
|
<h2>Okay, everything works just fine.</h2>
|
||||||
|
<h3> one more</h3>
|
||||||
</div>
|
</div>
|
||||||
)
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
export default App
|
export default App;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user