Skip to content
Snippets Groups Projects
.gitlab-ci.yml 2.78 KiB
Newer Older
image: registry.gitlab.freifunk-stuttgart.de/firmware/ffs-buildenv:master
nrbffs's avatar
nrbffs committed

variables:
  GIT_SUBMODULE_STRATEGY: normal
  DOCKER_DRIVER: overlay2
nrbffs's avatar
nrbffs committed

stages:
  - build
Nico's avatar
Nico committed
  - package
nrbffs's avatar
nrbffs committed

# Build Types
# ----
#
# * commit: build all branches on commit for x86-64 target.#
# * nightly: built once a night from `master` branch for all targets. 
# * beta: built from tag starting with "beta/", i.e. "beta/1.7-beta01" for all targets.
# * stable: built from tag starting with "stable/", i.e. "stable/1.5" for all targets.

.target:
nrbffs's avatar
nrbffs committed
  stage: build
  script:
    - make -C gluon update GLUON_SITEDIR="$CI_PROJECT_DIR"
    - make -C gluon GLUON_SITEDIR="$CI_PROJECT_DIR" GLUON_TARGET="$GLUON_TARGET" GLUON_BRANCH=$(./get-gluon-branch.sh) V=1 -j`nproc`
nrbffs's avatar
nrbffs committed
  artifacts: 
    paths:
      - gluon/output/
    expire_in: 1 day
nrbffs's avatar
nrbffs committed
  cache:
    paths:
      - gluon/openwrt/dl
      - gluon/openwrt/staging_dir
      - gluon/openwrt/feeds
nrbffs's avatar
nrbffs committed
    key: "gluon-cache/$GLUON_TARGET"
 
target:ar71xx-generic:
  extends: .target
  only: 
    - tags
    - schedules
    - web
  variables:
    GLUON_TARGET: ar71xx-generic
 
target:ar71xx-nand:
  extends: .target
  only: 
    - tags
    - schedules
    - web
  variables:
    GLUON_TARGET: ar71xx-nand
 
target:ar71xx-tiny:
  extends: .target
  only: 
    - tags
    - schedules
    - web
  variables:
    GLUON_TARGET: ar71xx-tiny
 
target:brcm2708-bcm2708:
  extends: .target
  only: 
    - tags
    - schedules
    - web
  variables:
    GLUON_TARGET: brcm2708-bcm2708
 
target:brcm2708-bcm2709:
  extends: .target
  only: 
    - tags
    - schedules
    - web
  variables:
    GLUON_TARGET: brcm2708-bcm2709
 
target:mpc85xx-generic:
  extends: .target
  only: 
    - tags
    - schedules
    - web
  variables:
    GLUON_TARGET: mpc85xx-generic
 
target:ipq40xx:
  extends: .target
  only: 
    - tags
    - schedules
    - web
  variables:
    GLUON_TARGET: ipq40xx
 
target:ramips-mt7621:
  extends: .target
  only: 
    - tags
    - schedules
    - web
  variables:
    GLUON_TARGET: ramips-mt7621
 
target:ramips-mt76x8:
  extends: .target
  only: 
    - tags
    - schedules
    - web
  variables:
    GLUON_TARGET: ramips-mt76x8
 
target:x86-generic:
  extends: .target
  only: 
    - tags
    - schedules
    - web
  variables:
    GLUON_TARGET: x86-generic
 
target:x86-geode:
  extends: .target
  only: 
    - tags
    - schedules
    - web
  variables:
    GLUON_TARGET: x86-geode
 
target:x86-64:
  extends: .target
  variables:
    GLUON_TARGET: x86-64
Nico's avatar
Nico committed

package:
  stage: package
  script:
    - GLUON_BRANCH=$(./get-gluon-branch.sh)
    - test -z "$GLUON_BRANCH" || make -C gluon update GLUON_SITEDIR="$CI_PROJECT_DIR"
    - test -z "$GLUON_BRANCH" || make -C gluon manifest GLUON_BRANCH=$(./get-gluon-branch.sh) GLUON_SITEDIR="$CI_PROJECT_DIR" V=1
Nico's avatar
Nico committed
  artifacts:
    paths:
      - gluon/output
    expire_in: 7 days