Added Jenkinsfile.
Some checks failed
thehideout/TheHideout-UI/pipeline/head There was a failure building this commit
Some checks failed
thehideout/TheHideout-UI/pipeline/head There was a failure building this commit
This commit is contained in:
parent
3dfaa50415
commit
5a951d8c90
25
Jenkinsfile
vendored
Normal file
25
Jenkinsfile
vendored
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
def deploy() {
|
||||||
|
node('ubuntu') {
|
||||||
|
try {
|
||||||
|
stage('Deploy (Ubuntu)') {
|
||||||
|
checkout scm
|
||||||
|
|
||||||
|
nodejs(nodeJSInstallationName: 'Node23') {
|
||||||
|
sh 'yarn install --frozen-lockfile --production=false'
|
||||||
|
|
||||||
|
sh 'NODE_ENV=production yarn build'
|
||||||
|
|
||||||
|
// Deploy to Cloudflare Pages using wrangler
|
||||||
|
withCredentials([string(credentialsId: 'th-cloudflare-api-token', variable: 'CLOUDFLARE_API_TOKEN')]) {
|
||||||
|
sh 'yarn wrangler pages deploy dist'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} finally {
|
||||||
|
cleanWs()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
deploy()
|
||||||
|
|
||||||
Loading…
x
Reference in New Issue
Block a user