mirror of
https://github.com/portainer/portainer.git
synced 2025-07-19 13:29:41 +02:00
chore(codefresh): add codefresh.yml (#887)
This commit is contained in:
parent
0f3fcb2917
commit
de2818de4c
2 changed files with 37 additions and 0 deletions
|
@ -1,2 +1,3 @@
|
|||
*
|
||||
!dist
|
||||
!build
|
||||
|
|
36
codefresh.yml
Normal file
36
codefresh.yml
Normal file
|
@ -0,0 +1,36 @@
|
|||
version: '1.0'
|
||||
steps:
|
||||
|
||||
build_backend:
|
||||
image: portainer/golang-builder:ci
|
||||
working_directory: ${{main_clone}}
|
||||
commands:
|
||||
- mkdir -p /go/src/github.com/${{CF_REPO_OWNER}}
|
||||
- ln -s /codefresh/volume/${{CF_REPO_NAME}}/api /go/src/github.com/${{CF_REPO_OWNER}}/${{CF_REPO_NAME}}
|
||||
- /build.sh api/cmd/portainer
|
||||
|
||||
build_frontend:
|
||||
image: portainer/angular-builder:latest
|
||||
working_directory: ${{build_backend}}
|
||||
commands:
|
||||
- npm install -g bower grunt grunt-cli && npm install
|
||||
- bower install --allow-root
|
||||
- grunt build-webapp
|
||||
- mv api/cmd/portainer/portainer dist/
|
||||
|
||||
build_image:
|
||||
type: build
|
||||
working_directory: ${{build_frontend}}
|
||||
dockerfile: ./build/linux/Dockerfile
|
||||
image_name: portainer/portainer
|
||||
tag: ${{CF_BRANCH}}
|
||||
|
||||
push_image:
|
||||
type: push
|
||||
candidate: '${{build_image}}'
|
||||
tag: '${{CF_BRANCH}}'
|
||||
registry: dockerhub
|
||||
when:
|
||||
branch:
|
||||
only:
|
||||
- develop
|
Loading…
Add table
Add a link
Reference in a new issue