Skip to content

Commit 7f72b60

Browse files
Add to PI server
1 parent 0da3265 commit 7f72b60

File tree

6 files changed

+37
-46
lines changed

6 files changed

+37
-46
lines changed

.github/workflows/azure-static-web-apps-happy-ocean-0f21e580f.yml

Lines changed: 0 additions & 46 deletions
This file was deleted.

.github/workflows/main.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Deploy
2+
3+
# Controls when the action will run.
4+
on:
5+
# Triggers the workflow on push or pull request events but only for the master branch
6+
push:
7+
branches: [ main ]
8+
9+
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
10+
jobs:
11+
# This workflow contains a single job called "build"
12+
build:
13+
# The type of runner that the job will run on
14+
runs-on: ubuntu-latest
15+
16+
# Steps represent a sequence of tasks that will be executed as part of the job
17+
steps:
18+
- name: Deploy using ssh
19+
uses: appleboy/ssh-action@master
20+
with:
21+
host: ${{ secrets.HOST }}
22+
username: ${{ secrets.USERNAME }}
23+
key: ${{ secrets.SSH_PRIVATE_KEY }}
24+
port: 22
25+
script: |
26+
cd /home/proyecto/AuthenticationServerFrontend/
27+
git pull origin main
28+
git status
29+
docker stop authui-app
30+
docker rm authui-app
31+
docker build -t authui . || { echo "Docker build failed"; exit 1; }
32+
docker run -d -it -p 5025:80 --restart unless-stopped --name authui-app authui || { echo "Docker run failed"; exit 1; }

Dockerfile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
FROM httpd:2.4
2+
3+
COPY ./app/ /usr/local/apache2/htdocs/
4+
5+
VOLUME ./app /usr/local/apache2/htdocs
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)