jandelgado / lede-dockerbuilder

A (container based) LEDE/OpenWrt image builder.
Apache License 2.0
59 stars 20 forks source link

custom feeds.conf.default and direct .config support? #2

Closed Andy2244 closed 7 years ago

Andy2244 commented 7 years ago

Hi,

i build my lede images using a vm atm, but use some custom local packages and need some specific .config settings. So would it be possible to add the ability to provide a "feeds.conf.default" + local feed folder and the ".config" directly via config options?

So my build process looks like this:

git pull
./scripts/feeds clean
./scripts/feeds update -a
./scripts/feeds install -a
./scripts/feeds install -a -f -p myfeed packages
# check if all .\package\feeds\myfeed is there!
\cp my.diff .config
make defconfig
rm my.diff
./scripts/diffconfig.sh >> my.diff
make

my "feeds.conf.default" looks like this

src-git luci https://git.lede-project.org/project/luci.git
src-link myfeed ../myfeed
src-git packages https://git.lede-project.org/feed/packages.git

If i could convert my VirtualBox VM to a simpler docker build process, this would be nice.

jandelgado commented 7 years ago

The docker container uses the Lede/OpenWRT "Image Creator" (https://lede-project.org/docs/user-guide/imagebuilder), which does not compile the image from source, but uses pre-compiled packages to speed things up. So there is no custom .config.

A custom repository/feed would however be possible and seems to be supported (see https://wiki.openwrt.org/doc/howto/obtain.firmware.generate#configure_package_repositories). I'll create an experimental branch with the option to include a local repository.

Andy2244 commented 7 years ago

Oki so if you can only select packages, how do you select package options?

So config options like those wont be possible?

CONFIG_BUSYBOX_CUSTOM=y
# CONFIG_BUSYBOX_CONFIG_BRCTL is not set
CONFIG_BUSYBOX_CONFIG_FEATURE_IP_RARE_PROTOCOLS=y
CONFIG_BUSYBOX_CONFIG_FEATURE_IP_TUNNEL=y
CONFIG_BUSYBOX_CONFIG_FEATURE_NAMEIF_EXTENDED=y
# CONFIG_BUSYBOX_CONFIG_FEATURE_PASSWD_WEAK_CHECK is not set
CONFIG_BUSYBOX_CONFIG_HOSTNAME=y
CONFIG_BUSYBOX_CONFIG_MODPROBE_SMALL=y
CONFIG_BUSYBOX_CONFIG_NAMEIF=y
CONFIG_BUSYBOX_CONFIG_RENICE=y
# CONFIG_GCC_USE_VERSION_5 is not set
CONFIG_GCC_USE_VERSION_6=y
CONFIG_GCC_VERSION="6.3.0"
# CONFIG_GDB is not set
# CONFIG_KERNEL_DEBUG_INFO is not set
# CONFIG_KERNEL_DEBUG_KERNEL is not set
CONFIG_KERNEL_FANOTIFY=y
CONFIG_KERNEL_FHANDLE=y
CONFIG_LIBCURL_COOKIES=y
CONFIG_LIBCURL_FILE=y
CONFIG_LIBCURL_FTP=y
CONFIG_LIBCURL_HTTP=y
CONFIG_LIBCURL_MBEDTLS=y
CONFIG_LIBCURL_NO_SMB="!"
CONFIG_LIBCURL_PROXY=y
CONFIG_OPENSSL_HARDWARE_SUPPORT=y
CONFIG_OPENSSL_WITH_DEPRECATED=y
CONFIG_OPENSSL_WITH_EC=y
CONFIG_OPENSSL_WITH_EC2M=y
CONFIG_OPENSSL_WITH_NPN=y
CONFIG_OPENSSL_WITH_PSK=y
CONFIG_OPENSSL_WITH_SRP=y
jandelgado commented 7 years ago

Yes, the image-builder uses only pre-compiled packages, so no configuration using a .config is possible.

Have a look at https://github.com/jandelgado/lede-dockercompiler for a docker image which provides a compile environment, this probably could replace your VM based setup.

jandelgado commented 7 years ago

not a bug - works as designed.