forked from markpollack/tas-music
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
45 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
name: Deploy gitops project | ||
run-name: ${{ github.actor }} deploying | ||
on: | ||
push: | ||
branches: | ||
- "gitops" | ||
jobs: | ||
gitops-deploy: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Install CF CLI | ||
run: | | ||
wget -q -O - https://packages.cloudfoundry.org/debian/cli.cloudfoundry.org.key | sudo apt-key add - | ||
echo "deb https://packages.cloudfoundry.org/debian stable main" | sudo tee /etc/apt/sources.list.d/cloudfoundry-cli.list | ||
sudo apt update | ||
sudo apt install cf8-cli | ||
sudo apt install openjdk-17-jdk openjdk-17-jre | ||
sudo update-java-alternatives --set /usr/lib/jvm/java-1.17.0-openjdk-amd64 | ||
export JAVA_HOME=/usr/lib/jvm/java-1.17.0-openjdk-amd64 | ||
mvn -version | ||
java -version | ||
- name: Connect to CF API | ||
run: | | ||
cf api https://api.sys.tas.vmtanzu.com --skip-ssl-validation | ||
cf auth admin ${{ secrets.CF_API_TOKEN }} | ||
cf target -o tanzu-platform-demo -s spring-metal-space | ||
- name: Check out repository code | ||
uses: actions/checkout@v4 | ||
- name: Deploy | ||
run: | | ||
export JAVA_HOME=/usr/lib/jvm/java-1.17.0-openjdk-amd64 | ||
cf target | ||
#git clone https://github.com/0pens0/spring-metal | ||
#cd spring-metal | ||
mvn package | ||
cf create-space spring-metal-space | ||
cf push | ||
cf apps | ||
- run: echo "🍏 This job's status is ${{ job.status }}." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters