mirror of
https://github.com/vacp2p/rfc.vac.dev.git
synced 2026-01-07 23:23:51 -05:00
ci: add nix flake and use in CI
Using system tooling can lead to weird behavior of available Node
versions, for example this IPv6 resolution error:
```
[3/5] Fetching packages...
error Error: connect EHOSTUNREACH 2606:4700::6810:1922:443
at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1495:16)
```
This commit is contained in:
35
Jenkinsfile
vendored
35
Jenkinsfile
vendored
@@ -1,5 +1,5 @@
|
||||
#!/usr/bin/env groovy
|
||||
library 'status-jenkins-lib@v1.8.15'
|
||||
library 'status-jenkins-lib@v1.9.24'
|
||||
|
||||
pipeline {
|
||||
agent { label 'linux' }
|
||||
@@ -23,32 +23,41 @@ pipeline {
|
||||
stages {
|
||||
stage('Install') {
|
||||
steps {
|
||||
sh 'yarn install'
|
||||
script {
|
||||
nix.develop('yarn install')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage('Scrape') {
|
||||
steps {
|
||||
sh 'yarn scrape'
|
||||
script {
|
||||
nix.develop('yarn scrape', keepEnv: ['INCLUDED_DIRS','FETCH_MODE'])
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage('Build') {
|
||||
steps { script {
|
||||
sh 'yarn build'
|
||||
jenkins.genBuildMetaJSON('build/build.json')
|
||||
} }
|
||||
steps {
|
||||
script {
|
||||
nix.develop('yarn build')
|
||||
jenkins.genBuildMetaJSON('build/build.json')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
stage('Publish') {
|
||||
steps {
|
||||
sshagent(credentials: ['status-im-auto-ssh']) {
|
||||
sh """
|
||||
ghp-import \
|
||||
-b ${deployBranch()} \
|
||||
-c ${deployDomain()} \
|
||||
-p build
|
||||
"""
|
||||
script {
|
||||
nix.develop("""
|
||||
ghp-import \
|
||||
-b ${deployBranch()} \
|
||||
-c ${deployDomain()} \
|
||||
-p build
|
||||
""", sandbox: false,
|
||||
keepEnv: ['SSH_AUTH_SOCK'])
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user