Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rc-update missing in alpine:>=3.3 #213

Closed
u6f6o opened this issue Sep 9, 2016 · 5 comments
Closed

rc-update missing in alpine:>=3.3 #213

u6f6o opened this issue Sep 9, 2016 · 5 comments

Comments

@u6f6o
Copy link

u6f6o commented Sep 9, 2016

Hi,

I created the following Dockerfile:

FROM alpine:3.3

RUN apk update \
    && apk upgrade \
    && apk add bash curl openvpn iptables \
    && rm -rf /var/cache/apk/* \
    && rc-update add openvpn default \
    && echo "tun" >> /etc/modules

but starting from alpine:3.3 it fails because rc-update cannot be found:

docker build -f Dockerfile .
Sending build context to Docker daemon 2.048 kB
Step 1 : FROM alpine:3.3
 ---> 47cf20d8c26c
Step 2 : RUN apk update         && apk upgrade  && apk add bash curl openvpn iptables   && rm -rf /var/cache/apk/*      && rc-update add openvpn default        && echo "tun" >> /etc/modules
 ---> Running in e77dd3e29e05
fetch http://dl-cdn.alpinelinux.org/alpine/v3.3/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.3/community/x86_64/APKINDEX.tar.gz
v3.3.3-124-gb4ea58d [http://dl-cdn.alpinelinux.org/alpine/v3.3/main]
v3.3.3-74-g713311c [http://dl-cdn.alpinelinux.org/alpine/v3.3/community]
OK: 5858 distinct packages available
(1/2) Upgrading libcrypto1.0 (1.0.2h-r1 -> 1.0.2h-r2)
(2/2) Upgrading libssl1.0 (1.0.2h-r1 -> 1.0.2h-r2)
OK: 5 MiB in 11 packages
(1/13) Installing ncurses-terminfo-base (6.0-r6)
(2/13) Installing ncurses-terminfo (6.0-r6)
(3/13) Installing ncurses-libs (6.0-r6)
(4/13) Installing readline (6.3.008-r4)
(5/13) Installing bash (4.3.42-r3)
Executing bash-4.3.42-r3.post-install
(6/13) Installing openssl (1.0.2h-r2)
(7/13) Installing ca-certificates (20160104-r2)
(8/13) Installing libssh2 (1.6.0-r1)
(9/13) Installing curl (7.49.1-r1)
(10/13) Installing iptables (1.4.21-r4)
(11/13) Installing iproute2 (4.2.0-r0)
Executing iproute2-4.2.0-r0.post-install
(12/13) Installing lzo (2.09-r0)
(13/13) Installing openvpn (2.3.8-r2)
Executing openvpn-2.3.8-r2.pre-install
Executing busybox-1.24.2-r0.trigger
Executing ca-certificates-20160104-r2.trigger
OK: 18 MiB in 24 packages
/bin/sh: rc-update: not found
@snc
Copy link

snc commented Sep 10, 2016

The rc-update command is part of the openrc package so you should install this, too. Also note that you may want to use the --no-cache parameter of apk.

If you don't know https://github.com/just-containers/s6-overlay, it might be worth to have a look at it as a replacement for openrc.

@u6f6o
Copy link
Author

u6f6o commented Sep 10, 2016

Cool, thx for the quick response, I'll have a look at it today.

@u6f6o u6f6o closed this as completed Sep 10, 2016
@rbashish
Copy link

rbashish commented Jul 9, 2019

The rc-update command is part of the openrc package so you should install this, too. Also note that you may want to use the --no-cache parameter of apk.

If you don't know https://github.com/just-containers/s6-overlay, it might be worth to have a look at it as a replacement for openrc.

Thanks for saving time. It worked like a charm after installing $ apk add openrc

@AyoubHolmes
Copy link

Thanks, I had the same issue!

@tiagofrancafernandes
Copy link

tiagofrancafernandes commented Sep 20, 2022

apk add openrc

Updated:

FROM alpine:3.3

RUN apk update \
    && apk upgrade \
    && apk add bash curl openvpn openrc iptables \
    && rm -rf /var/cache/apk/* \
    && rc-update add openvpn default \
    && echo "tun" >> /etc/modules

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants