Getting apt-get on an alpine container












0














I have to install a few dependencies on my docker container, I want to use python:3.6-alpine version to have it as light as possible, but apk package manager which comes with alpine is giving me trouble so I would like to get the apt-get package manager. I tried:



apk add apt-get


and it didnt work.



how can I get it on the container?










share|improve this question






















  • apk is the default package manager on alpine. You don't need apt
    – lependu
    Nov 20 '18 at 9:22






  • 1




    What do you want to install that is giving you trouble with apk?
    – Julio Daniel Reyes
    Nov 20 '18 at 17:41
















0














I have to install a few dependencies on my docker container, I want to use python:3.6-alpine version to have it as light as possible, but apk package manager which comes with alpine is giving me trouble so I would like to get the apt-get package manager. I tried:



apk add apt-get


and it didnt work.



how can I get it on the container?










share|improve this question






















  • apk is the default package manager on alpine. You don't need apt
    – lependu
    Nov 20 '18 at 9:22






  • 1




    What do you want to install that is giving you trouble with apk?
    – Julio Daniel Reyes
    Nov 20 '18 at 17:41














0












0








0







I have to install a few dependencies on my docker container, I want to use python:3.6-alpine version to have it as light as possible, but apk package manager which comes with alpine is giving me trouble so I would like to get the apt-get package manager. I tried:



apk add apt-get


and it didnt work.



how can I get it on the container?










share|improve this question













I have to install a few dependencies on my docker container, I want to use python:3.6-alpine version to have it as light as possible, but apk package manager which comes with alpine is giving me trouble so I would like to get the apt-get package manager. I tried:



apk add apt-get


and it didnt work.



how can I get it on the container?







docker apt-get apt alpine






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 20 '18 at 9:19









NotSoShabby

209212




209212












  • apk is the default package manager on alpine. You don't need apt
    – lependu
    Nov 20 '18 at 9:22






  • 1




    What do you want to install that is giving you trouble with apk?
    – Julio Daniel Reyes
    Nov 20 '18 at 17:41


















  • apk is the default package manager on alpine. You don't need apt
    – lependu
    Nov 20 '18 at 9:22






  • 1




    What do you want to install that is giving you trouble with apk?
    – Julio Daniel Reyes
    Nov 20 '18 at 17:41
















apk is the default package manager on alpine. You don't need apt
– lependu
Nov 20 '18 at 9:22




apk is the default package manager on alpine. You don't need apt
– lependu
Nov 20 '18 at 9:22




1




1




What do you want to install that is giving you trouble with apk?
– Julio Daniel Reyes
Nov 20 '18 at 17:41




What do you want to install that is giving you trouble with apk?
– Julio Daniel Reyes
Nov 20 '18 at 17:41












1 Answer
1






active

oldest

votes


















2














Using multiple package systems is usually a very bad idea, for many reasons. Packages are likely to collide and break and you'll end up with much greater mess than you've started with.

See this excellent answer for more detail: Is there a pitfall of using multiple package managers?



A more feasible approach would be troubleshooting and resolving the issues you are having with apk. apk is designed for simplicity and speed, and should take very little getting used to. It is really an excellent package manager, IMO.



For a good tutorial, I warmly recommend the apk introduction page at the Alpine Wiki site:
https://wiki.alpinelinux.org/wiki/Alpine_Linux_package_management



If you're determined not to use apk, and for the sake of experiment want try bringing up apt instead, as a first step, you'll have first to build apt from source: https://github.com/Debian/apt. Then, if it is produces a functional build (not likely since it's probably not compatible with musl libc), you'll have to wire it to some repositories, but Alpine repositories are only fit for apk, not apt. As you can see, this is not really feasible, and not the route you want to go to.






share|improve this answer





















  • That's fair, but that got me thinking - why is that any different than using pip as well as other package manage (pip is the python package manager) which everybody do?
    – NotSoShabby
    Nov 21 '18 at 8:10






  • 1




    Python has its own package system, which is managed by pip, as opposed to apk and apt which manage the Linux system binaries and programs. pip effect is limited to scope of Python programs. Think of it this way - if things break in pip, Python may break, but if things go wrong in apk or apt, your entire Linux system may break.
    – valiano
    Nov 21 '18 at 8:36








  • 1




    @NotSoShabby or put in other words, pip is orthogonal to apk / apt - they are independent of each other.
    – valiano
    Nov 21 '18 at 10:28











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53389749%2fgetting-apt-get-on-an-alpine-container%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









2














Using multiple package systems is usually a very bad idea, for many reasons. Packages are likely to collide and break and you'll end up with much greater mess than you've started with.

See this excellent answer for more detail: Is there a pitfall of using multiple package managers?



A more feasible approach would be troubleshooting and resolving the issues you are having with apk. apk is designed for simplicity and speed, and should take very little getting used to. It is really an excellent package manager, IMO.



For a good tutorial, I warmly recommend the apk introduction page at the Alpine Wiki site:
https://wiki.alpinelinux.org/wiki/Alpine_Linux_package_management



If you're determined not to use apk, and for the sake of experiment want try bringing up apt instead, as a first step, you'll have first to build apt from source: https://github.com/Debian/apt. Then, if it is produces a functional build (not likely since it's probably not compatible with musl libc), you'll have to wire it to some repositories, but Alpine repositories are only fit for apk, not apt. As you can see, this is not really feasible, and not the route you want to go to.






share|improve this answer





















  • That's fair, but that got me thinking - why is that any different than using pip as well as other package manage (pip is the python package manager) which everybody do?
    – NotSoShabby
    Nov 21 '18 at 8:10






  • 1




    Python has its own package system, which is managed by pip, as opposed to apk and apt which manage the Linux system binaries and programs. pip effect is limited to scope of Python programs. Think of it this way - if things break in pip, Python may break, but if things go wrong in apk or apt, your entire Linux system may break.
    – valiano
    Nov 21 '18 at 8:36








  • 1




    @NotSoShabby or put in other words, pip is orthogonal to apk / apt - they are independent of each other.
    – valiano
    Nov 21 '18 at 10:28
















2














Using multiple package systems is usually a very bad idea, for many reasons. Packages are likely to collide and break and you'll end up with much greater mess than you've started with.

See this excellent answer for more detail: Is there a pitfall of using multiple package managers?



A more feasible approach would be troubleshooting and resolving the issues you are having with apk. apk is designed for simplicity and speed, and should take very little getting used to. It is really an excellent package manager, IMO.



For a good tutorial, I warmly recommend the apk introduction page at the Alpine Wiki site:
https://wiki.alpinelinux.org/wiki/Alpine_Linux_package_management



If you're determined not to use apk, and for the sake of experiment want try bringing up apt instead, as a first step, you'll have first to build apt from source: https://github.com/Debian/apt. Then, if it is produces a functional build (not likely since it's probably not compatible with musl libc), you'll have to wire it to some repositories, but Alpine repositories are only fit for apk, not apt. As you can see, this is not really feasible, and not the route you want to go to.






share|improve this answer





















  • That's fair, but that got me thinking - why is that any different than using pip as well as other package manage (pip is the python package manager) which everybody do?
    – NotSoShabby
    Nov 21 '18 at 8:10






  • 1




    Python has its own package system, which is managed by pip, as opposed to apk and apt which manage the Linux system binaries and programs. pip effect is limited to scope of Python programs. Think of it this way - if things break in pip, Python may break, but if things go wrong in apk or apt, your entire Linux system may break.
    – valiano
    Nov 21 '18 at 8:36








  • 1




    @NotSoShabby or put in other words, pip is orthogonal to apk / apt - they are independent of each other.
    – valiano
    Nov 21 '18 at 10:28














2












2








2






Using multiple package systems is usually a very bad idea, for many reasons. Packages are likely to collide and break and you'll end up with much greater mess than you've started with.

See this excellent answer for more detail: Is there a pitfall of using multiple package managers?



A more feasible approach would be troubleshooting and resolving the issues you are having with apk. apk is designed for simplicity and speed, and should take very little getting used to. It is really an excellent package manager, IMO.



For a good tutorial, I warmly recommend the apk introduction page at the Alpine Wiki site:
https://wiki.alpinelinux.org/wiki/Alpine_Linux_package_management



If you're determined not to use apk, and for the sake of experiment want try bringing up apt instead, as a first step, you'll have first to build apt from source: https://github.com/Debian/apt. Then, if it is produces a functional build (not likely since it's probably not compatible with musl libc), you'll have to wire it to some repositories, but Alpine repositories are only fit for apk, not apt. As you can see, this is not really feasible, and not the route you want to go to.






share|improve this answer












Using multiple package systems is usually a very bad idea, for many reasons. Packages are likely to collide and break and you'll end up with much greater mess than you've started with.

See this excellent answer for more detail: Is there a pitfall of using multiple package managers?



A more feasible approach would be troubleshooting and resolving the issues you are having with apk. apk is designed for simplicity and speed, and should take very little getting used to. It is really an excellent package manager, IMO.



For a good tutorial, I warmly recommend the apk introduction page at the Alpine Wiki site:
https://wiki.alpinelinux.org/wiki/Alpine_Linux_package_management



If you're determined not to use apk, and for the sake of experiment want try bringing up apt instead, as a first step, you'll have first to build apt from source: https://github.com/Debian/apt. Then, if it is produces a functional build (not likely since it's probably not compatible with musl libc), you'll have to wire it to some repositories, but Alpine repositories are only fit for apk, not apt. As you can see, this is not really feasible, and not the route you want to go to.







share|improve this answer












share|improve this answer



share|improve this answer










answered Nov 20 '18 at 19:29









valiano

3,17221333




3,17221333












  • That's fair, but that got me thinking - why is that any different than using pip as well as other package manage (pip is the python package manager) which everybody do?
    – NotSoShabby
    Nov 21 '18 at 8:10






  • 1




    Python has its own package system, which is managed by pip, as opposed to apk and apt which manage the Linux system binaries and programs. pip effect is limited to scope of Python programs. Think of it this way - if things break in pip, Python may break, but if things go wrong in apk or apt, your entire Linux system may break.
    – valiano
    Nov 21 '18 at 8:36








  • 1




    @NotSoShabby or put in other words, pip is orthogonal to apk / apt - they are independent of each other.
    – valiano
    Nov 21 '18 at 10:28


















  • That's fair, but that got me thinking - why is that any different than using pip as well as other package manage (pip is the python package manager) which everybody do?
    – NotSoShabby
    Nov 21 '18 at 8:10






  • 1




    Python has its own package system, which is managed by pip, as opposed to apk and apt which manage the Linux system binaries and programs. pip effect is limited to scope of Python programs. Think of it this way - if things break in pip, Python may break, but if things go wrong in apk or apt, your entire Linux system may break.
    – valiano
    Nov 21 '18 at 8:36








  • 1




    @NotSoShabby or put in other words, pip is orthogonal to apk / apt - they are independent of each other.
    – valiano
    Nov 21 '18 at 10:28
















That's fair, but that got me thinking - why is that any different than using pip as well as other package manage (pip is the python package manager) which everybody do?
– NotSoShabby
Nov 21 '18 at 8:10




That's fair, but that got me thinking - why is that any different than using pip as well as other package manage (pip is the python package manager) which everybody do?
– NotSoShabby
Nov 21 '18 at 8:10




1




1




Python has its own package system, which is managed by pip, as opposed to apk and apt which manage the Linux system binaries and programs. pip effect is limited to scope of Python programs. Think of it this way - if things break in pip, Python may break, but if things go wrong in apk or apt, your entire Linux system may break.
– valiano
Nov 21 '18 at 8:36






Python has its own package system, which is managed by pip, as opposed to apk and apt which manage the Linux system binaries and programs. pip effect is limited to scope of Python programs. Think of it this way - if things break in pip, Python may break, but if things go wrong in apk or apt, your entire Linux system may break.
– valiano
Nov 21 '18 at 8:36






1




1




@NotSoShabby or put in other words, pip is orthogonal to apk / apt - they are independent of each other.
– valiano
Nov 21 '18 at 10:28




@NotSoShabby or put in other words, pip is orthogonal to apk / apt - they are independent of each other.
– valiano
Nov 21 '18 at 10:28


















draft saved

draft discarded




















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53389749%2fgetting-apt-get-on-an-alpine-container%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

If I really need a card on my start hand, how many mulligans make sense? [duplicate]

Alcedinidae

Can an atomic nucleus contain both particles and antiparticles? [duplicate]